@todesktop/cli 1.20.2 → 1.21.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -48,7 +48,7 @@ Create a `todesktop.json` file in the root of your Electron project.
48
48
 
49
49
  ```json
50
50
  {
51
- "$schema": "https://unpkg.com/@todesktop/cli@1.20.2/schemas/schema.json",
51
+ "$schema": "https://unpkg.com/@todesktop/cli@1.21.0/schemas/schema.json",
52
52
  "schemaVersion": 1
53
53
  "id": "your-todesktop-id",
54
54
  "icon": "./desktop-icon.png",
@@ -413,7 +413,7 @@ To enable JSON validation and IntelliSense for your `todesktop.json` file in com
413
413
  - For example, if using a hosted version of the schema:
414
414
  ```json
415
415
  {
416
- "$schema": "https://unpkg.com/@todesktop/cli@1.20.2/schemas/schema.json",
416
+ "$schema": "https://unpkg.com/@todesktop/cli@1.21.0/schemas/schema.json",
417
417
  "id": "your-todesktop-id"
418
418
  }
419
419
  ```
@@ -908,6 +908,29 @@ Linux Changelog:
908
908
  you're doing.
909
909
  - `0.0.11`: Updated git 2.25.1 → 2.47.1 node 18.18.2 → 18.20.5
910
910
 
911
+ ### `linux.executableArgs` - (optional) string[]
912
+
913
+ Example: `--enable-features=UseOzonePlatform,--ozone-platform=x11`
914
+
915
+ Additional command-line arguments to pass to the executable in the Linux .desktop file Exec line.
916
+
917
+ This is useful if your Linux app requires specific flags to run reliably. For
918
+ example, some apps need Ozone platform flags for Wayland/X11 compatibility:
919
+
920
+ ```json
921
+ {
922
+ "linux": {
923
+ "executableArgs": [
924
+ "--enable-features=UseOzonePlatform",
925
+ "--ozone-platform=x11"
926
+ ]
927
+ }
928
+ }
929
+ ```
930
+
931
+ Note: `--no-sandbox` is included by default. If you set `executableArgs`, it
932
+ will be preserved automatically unless you also set `noSandbox` to `false`.
933
+
911
934
  ### `linux.noSandbox` - (optional) boolean
912
935
 
913
936
  Default: `true`
@@ -1679,6 +1702,26 @@ Now, when we build your app on ToDesktop servers, it will also run your custom
1679
1702
 
1680
1703
  ## Changelog
1681
1704
 
1705
+ ### 1.21.0
1706
+
1707
+ #### Minor Changes
1708
+
1709
+ - 7906119: Add `linux.executableArgs` configuration option for passing
1710
+ additional command-line arguments to the Linux executable.
1711
+
1712
+ ### 1.20.4
1713
+
1714
+ #### Patch Changes
1715
+
1716
+ - da70faa: Fix `whoami` command not working when authenticated via environment
1717
+ variables (TODESKTOP_EMAIL and TODESKTOP_ACCESS_TOKEN)
1718
+
1719
+ ### 1.20.3
1720
+
1721
+ #### Patch Changes
1722
+
1723
+ - 22b8f01: Fix `whoami` command
1724
+
1682
1725
  ### 1.20.2
1683
1726
 
1684
1727
  #### Patch Changes
package/dist/cli.js CHANGED
@@ -2892,6 +2892,16 @@ var schema_default = {
2892
2892
  examples: ["0.1.0"],
2893
2893
  default: "0.0.12"
2894
2894
  },
2895
+ executableArgs: {
2896
+ type: "array",
2897
+ items: {
2898
+ type: "string"
2899
+ },
2900
+ description: "Additional command-line arguments to pass to the executable in the Linux .desktop file Exec line.",
2901
+ examples: [
2902
+ ["--enable-features=UseOzonePlatform", "--ozone-platform=x11"]
2903
+ ]
2904
+ },
2895
2905
  noSandbox: {
2896
2906
  type: "boolean",
2897
2907
  description: "This option allows you to configure whether your app should run in a sandboxed environment.",
@@ -5157,7 +5167,15 @@ var LoginHOC = ({ children, isInteractive = true }) => {
5157
5167
  );
5158
5168
  if (newJwtToken) {
5159
5169
  userCreds = await signInWithCustomToken(newJwtToken);
5160
- if (userCreds.user) setIsLoggedIn(true);
5170
+ if (userCreds.user) {
5171
+ setEphemeralMode(true);
5172
+ setAuthConfig(
5173
+ TODESKTOP_EMAIL,
5174
+ TODESKTOP_ACCESS_TOKEN,
5175
+ newJwtToken
5176
+ );
5177
+ setIsLoggedIn(true);
5178
+ }
5161
5179
  }
5162
5180
  } else if (!isRawModeSupported || import_is_ci4.default) {
5163
5181
  setError(
@@ -8719,7 +8737,7 @@ var package_default = {
8719
8737
  access: "public"
8720
8738
  },
8721
8739
  name: "@todesktop/cli",
8722
- version: "1.20.2",
8740
+ version: "1.21.0",
8723
8741
  license: "MIT",
8724
8742
  author: "Dave Jeffery <dave@todesktop.com> (http://www.todesktop.com/)",
8725
8743
  homepage: "https://todesktop.com/cli",
@@ -8735,18 +8753,19 @@ var package_default = {
8735
8753
  },
8736
8754
  scripts: {
8737
8755
  build: "npm run docs:generate && npm run types:generate && node scripts/esbuild.js",
8738
- dev: "node scripts/esbuild.js --link --watch --stage dev",
8739
- "dev:local:prod": "node scripts/esbuild.js --link --watch --stage prod-local",
8740
- "dev:prod": "node scripts/esbuild.js --link --watch",
8741
8756
  "docs:generate": "node scripts/generate-readme.js",
8742
8757
  format: "prettier . --write && eslint --fix",
8743
8758
  lint: "prettier . --check && eslint",
8744
- "types:generate": "node scripts/generate-types.js",
8759
+ prepublishOnly: "npm run docs:generate",
8745
8760
  test: "ava",
8746
8761
  "test:e2e": "node test/output-snapshots/output.test.js",
8747
- "test--watch": "npm test -- --watch",
8762
+ "test:watch": "npm test -- --watch",
8748
8763
  typecheck: "tsc --noEmit && tsc-strict",
8749
- prepublishOnly: "npm run docs:generate"
8764
+ "types:generate": "node scripts/generate-types.js",
8765
+ "watch:dev": "node scripts/esbuild.js --link --watch --stage dev",
8766
+ "watch:dev-local": "node scripts/esbuild.js --link --watch --stage dev-local",
8767
+ "watch:prod": "node scripts/esbuild.js --link --watch",
8768
+ "watch:prod-local": "node scripts/esbuild.js --link --watch --stage prod-local"
8750
8769
  },
8751
8770
  files: [
8752
8771
  "scripts/postinstall.js",
@@ -9121,7 +9140,8 @@ import_commander.program.command("introspect [buildId]").description("Connect to
9121
9140
  configPath: options == null ? void 0 : options.config
9122
9141
  });
9123
9142
  }
9124
- ).command("whoami").description("Prints the email of the account you're signed into").action(() => {
9143
+ );
9144
+ import_commander.program.command("whoami").description("Prints the email of the account you're signed into").action(() => {
9125
9145
  runCommand(WhoamiCommand_default);
9126
9146
  });
9127
9147
  var runCommand = (component, props = null, { exitIfOutOfDate = true } = {}) => {