@bobfrankston/npmglobalize 1.0.12 → 1.0.18

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/cli.js CHANGED
@@ -36,6 +36,8 @@ Other Options:
36
36
  --dry-run Show what would happen
37
37
  --quiet Suppress npm warnings (default)
38
38
  --verbose Show detailed output
39
+ --conform Update .gitignore/.npmignore to best practices
40
+ --asis Skip ignore file checks (or set "asis": true in .globalize.json5)
39
41
  --help, -h Show this help
40
42
 
41
43
  Examples:
@@ -140,6 +142,12 @@ function parseArgs(args) {
140
142
  options.error = '-m/--message requires a commit message';
141
143
  }
142
144
  break;
145
+ case '--conform':
146
+ options.conform = true;
147
+ break;
148
+ case '--asis':
149
+ options.asis = true;
150
+ break;
143
151
  default:
144
152
  if (arg.startsWith('-')) {
145
153
  unrecognized.push(arg);
package/lib.d.ts CHANGED
@@ -31,13 +31,17 @@ export interface GlobalizeOptions {
31
31
  npmVisibility?: 'private' | 'public';
32
32
  /** Custom commit message */
33
33
  message?: string;
34
+ /** Check and update ignore files to conform to best practices */
35
+ conform?: boolean;
36
+ /** Keep ignore files as-is without checking */
37
+ asis?: boolean;
34
38
  }
35
39
  /** Read and parse package.json from a directory */
36
40
  export declare function readPackageJson(dir: string): any;
37
- /** Read .globalize.jsonc config file */
41
+ /** Read .globalize.json5 config file */
38
42
  export declare function readConfig(dir: string): Partial<GlobalizeOptions>;
39
- /** Write .globalize.jsonc config file */
40
- export declare function writeConfig(dir: string, config: Partial<GlobalizeOptions>): void;
43
+ /** Write .globalize.json5 config file */
44
+ export declare function writeConfig(dir: string, config: Partial<GlobalizeOptions>, explicitKeys?: Set<string>): void;
41
45
  /** Write package.json to a directory */
42
46
  export declare function writePackageJson(dir: string, pkg: any): void;
43
47
  /** Resolve a file: path to absolute path */
@@ -60,6 +64,7 @@ export declare function hasBackup(pkg: any): boolean;
60
64
  export declare function runCommand(cmd: string, args: string[], options?: {
61
65
  silent?: boolean;
62
66
  cwd?: string;
67
+ shell?: boolean;
63
68
  }): {
64
69
  success: boolean;
65
70
  output: string;