You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/command.rs
+24-6Lines changed: 24 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -19,10 +19,18 @@ pub enum Command {
19
19
/// 🐣 initialize a package.json based on your compiled wasm!
20
20
Init{
21
21
path:Option<String>,
22
+
22
23
#[structopt(long = "scope", short = "s")]
23
24
scope:Option<String>,
25
+
24
26
#[structopt(long = "no-typescript")]
27
+
/// By default a *.d.ts file is generated for the generated JS file, but
28
+
/// this flag will disable generating this TypeScript file.
25
29
disable_dts:bool,
30
+
31
+
#[structopt(long = "target", short = "t", default_value = "browser")]
32
+
/// Sets the target environment. [possible values: browser, nodejs]
33
+
target:String,
26
34
},
27
35
28
36
#[structopt(name = "pack")]
@@ -38,22 +46,30 @@ pub enum Command {
38
46
Login{
39
47
#[structopt(long = "registry", short = "r")]
40
48
/// Default: 'https://registry.npmjs.org/'.
41
-
/// The base URL of the npm package registry. If scope is also specified, this registry will only be used for packages with that scope. scope defaults to the scope of the project directory you're currently in, if any.
49
+
/// The base URL of the npm package registry. If scope is also
50
+
/// specified, this registry will only be used for packages with that
51
+
/// scope. scope defaults to the scope of the project directory you're
52
+
/// currently in, if any.
42
53
registry:Option<String>,
43
54
44
55
#[structopt(long = "scope", short = "s")]
45
56
/// Default: none.
46
-
/// If specified, the user and login credentials given will be associated with the specified scope.
57
+
/// If specified, the user and login credentials given will be
58
+
/// associated with the specified scope.
47
59
scope:Option<String>,
48
60
49
61
#[structopt(long = "always-auth", short = "a")]
50
-
/// If specified, save configuration indicating that all requests to the given registry should include authorization information. Useful for private registries. Can be used with --registry and / or --scope
62
+
/// If specified, save configuration indicating that all requests to the
63
+
/// given registry should include authorization information. Useful for
64
+
/// private registries. Can be used with --registry and / or --scope
51
65
always_auth:bool,
52
66
53
67
#[structopt(long = "auth-type", short = "t")]
54
68
/// Default: 'legacy'.
55
69
/// Type: 'legacy', 'sso', 'saml', 'oauth'.
56
-
/// What authentication strategy to use with adduser/login. Some npm registries (for example, npmE) might support alternative auth strategies besides classic username/password entry in legacy npm.
70
+
/// What authentication strategy to use with adduser/login. Some npm
71
+
/// registries (for example, npmE) might support alternative auth
72
+
/// strategies besides classic username/password entry in legacy npm.
0 commit comments