-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(cli): use npm run tauri -- foo
for correctly passing args to tauri
#6448
Conversation
npm run tauri -- foo
for correctly pass args to taurinpm run tauri -- foo
for correctly passing args to tauri
b34406f
to
0eb924d
Compare
ARCHITECTURE.md
Outdated
@@ -113,7 +113,7 @@ Once everything is installed, you can run: | |||
``` | |||
yarn tauri dev | |||
-or- | |||
npm run tauri dev |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
examples/api/README.md
Outdated
@@ -32,7 +32,7 @@ $ npm install | |||
# with yarn | |||
$ yarn tauri dev | |||
# with npm | |||
$ npm run tauri dev |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
examples/resources/README.md
Outdated
@@ -33,7 +33,7 @@ $ yarn package | |||
# with yarn | |||
$ yarn tauri dev | |||
# with npm | |||
$ npm run tauri dev |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
examples/sidecar/README.md
Outdated
@@ -33,7 +33,7 @@ $ yarn package | |||
# with yarn | |||
$ yarn tauri dev | |||
# with npm | |||
$ npm run tauri dev |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
0eb924d
to
40b2f49
Compare
Judging from this single example:
I don't think this is something that needs changes inside tauri right? Aren't we just talking about this: npm run tauri android android-studio-script -- --target aarch64 (note the extra I mean, this is an issue with all commands (including desktop ones) so wouldn't we just make it inconsistent with this change? Sorry if i'm missing something obvious here. |
@FabianLars Mobile is special:
For desktop, it is simple to add But mobile platform is different: the command |
What kind of change does this PR introduce?
Does this PR introduce a breaking change?
Checklist
fix: remove a typo, closes #___, #___
)Other information
If use
npm run tauri android init
for generating Android project, we will get some error like this whenrun dev
:Executed commandis:
NPM will consume argument
--target
, then passandroid android-studio-script aarch64
to tauri.When using npm, we should use
--
for passing args into tauri.Instead, we should use
npm run tauri -- android android-studio-script --target aarch64
.The minimum case is
npm run tauri -v
which will output NPM version.I have tested with
pnpm
andyarn
,Also see npm/npm#5518