@baicie/ncu 0.1.14 → 0.1.16

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/build/index.d.ts CHANGED
@@ -1,233 +1,247 @@
1
- import { SemVer } from 'semver-utils';
2
-
3
- /** A function that can be provided to the --cooldown option for custom cooldown predicate. */
4
- declare type CooldownFunction = (packageName: string) => number | null;
5
-
6
- /**
7
- * TypeScript helper for .npmrc config file. Similar to vite and eslint's
8
- * defineConfig helper
9
- */
10
- export declare function defineConfig(config: RcOptions): RcOptions;
11
-
12
- /** Supported function for the --filter and --reject options. */
13
- declare type FilterFunction = (packageName: string, versionRange: SemVer[]) => boolean;
14
-
15
- declare type FilterResultsFunction = (packageName: string, versioningMetadata: {
16
- currentVersion: VersionSpec;
17
- currentVersionSemver: SemVer[];
18
- upgradedVersion: Version;
19
- upgradedVersionSemver: SemVer;
20
- }) => boolean;
21
-
22
- /** Customize how packages are divided into groups when using `--format group`. Run "ncu --help --groupFunction" for details. */
23
- declare type GroupFunction = (packageName: string, defaultGroup: UpgradeGroup, currentVersionSpec: SemVer[], upgradedVersionSpec: SemVer[], upgradedVersion: SemVer | null) => UpgradeGroup | string;
24
-
25
- /** A very generic object. */
26
- declare type Index<T = any> = Record<string, T>;
27
-
28
- declare type NestedVersionSpecs = {
29
- [name: string]: VersionSpec | NestedVersionSpecs;
30
- };
31
-
32
- /** Options that would make no sense in a .ncurc file */
33
- declare type Nonsensical = 'configFileName' | 'configFilePath' | 'cwd' | 'packageData' | 'stdin';
34
-
35
- /** The relevant bits of a parsed package.json file. */
36
- declare interface PackageFile {
37
- dependencies?: Index<VersionSpec>;
38
- devDependencies?: Index<VersionSpec>;
39
- imports?: Index<VersionSpec>;
40
- engines?: Index<VersionSpec>;
41
- name?: string;
42
- packageManager?: string;
43
- optionalDependencies?: Index<VersionSpec>;
44
- overrides?: NestedVersionSpecs;
45
- peerDependencies?: Index<VersionSpec>;
46
- repository?: string | PackageFileRepository;
47
- scripts?: Index<string>;
48
- workspaces?: string[] | {
49
- packages: string[];
50
- };
51
- version?: string;
52
- }
53
-
54
- /** Represents the repository field in package.json. */
55
- declare interface PackageFileRepository {
56
- url: string;
57
- directory?: string;
58
- }
59
-
60
- /** Expected options that might be found in an .ncurc file. Since the config is external, this cannot be guaranteed */
61
- export declare type RcOptions = Omit<RunOptions, Nonsensical> & {
62
- $schema?: string;
63
- format?: string | string[];
64
- };
65
-
66
- /** Main entry point.
67
- *
68
- * @returns Promise<
69
- * PackageFile Default returns upgraded package file.
70
- * | Index<VersionSpec> --jsonUpgraded returns only upgraded dependencies.
71
- * | void --global upgrade returns void.
72
- * >
73
- */
74
- declare function run_2(runOptions?: RunOptions, { cli }?: {
75
- cli?: boolean;
76
- }): Promise<PackageFile | Index<VersionSpec> | void>;
77
- export default run_2;
78
- export { run_2 as run }
79
-
80
- /** Options that can be given on the CLI or passed to the ncu module to control all behavior. */
81
- export declare interface RunOptions {
82
- /** Cache versions to a local cache file. Default `--cacheFile` is ~/.ncu-cache.json and default `--cacheExpiration` is 10 minutes. */
83
- cache?: boolean;
84
- /** Clear the default cache, or the cache file specified by `--cacheFile`. */
85
- cacheClear?: boolean;
86
- /** Cache expiration in minutes. Only works with `--cache`.
87
- *
88
- * @default 10
89
- */
90
- cacheExpiration?: number;
91
- /** Filepath for the cache file. Only works with `--cache`.
92
- *
93
- * @default "~/.ncu-cache.json"
94
- */
95
- cacheFile?: string;
96
- /** Force color in terminal. */
97
- color?: boolean;
98
- /** Max number of concurrent HTTP requests to registry.
99
- *
100
- * @default 8
101
- */
102
- concurrency?: number;
103
- /** Config file name. (default: .ncurc.{json,yml,js,cjs}) */
104
- configFileName?: string;
105
- /** Directory of .ncurc config file. (default: directory of `packageFile`) */
106
- configFilePath?: string;
107
- /** Sets a minimum age (in days) for package versions to be considered for upgrade, reducing the risk of installing newly published, potentially compromised packages. Run "ncu --help --cooldown" for details. */
108
- cooldown?: number | CooldownFunction;
109
- /** Working directory in which npm will be executed. */
110
- cwd?: string;
111
- /** Run recursively in current working directory. Alias of (`--packageFile '**\/package.json'`). */
112
- deep?: boolean;
113
- /** Check one or more sections of dependencies only: dev, optional, peer, prod, or packageManager (comma-delimited).
114
- *
115
- * @default ["prod","dev","optional","packageManager"]
116
- */
117
- dep?: string | readonly string[];
118
- /** Include deprecated packages. Use `--no-deprecated` to exclude deprecated packages (20–25% slower).
119
- *
120
- * @default true
121
- */
122
- deprecated?: boolean;
123
- /** Iteratively installs upgrades and runs tests to identify breaking upgrades. Requires `-u` to execute. Run "ncu --help --doctor" for details. */
124
- doctor?: boolean;
125
- /** Specifies the install script to use in doctor mode. (default: `npm install` or the equivalent for your package manager) */
126
- doctorInstall?: string;
127
- /** Specifies the test script to use in doctor mode. (default: `npm test`) */
128
- doctorTest?: string;
129
- /** Include only packages that satisfy engines.node as specified in the package file. */
130
- enginesNode?: boolean;
131
- /** Set the error level. 1: exits with error code 0 if no errors occur. 2: exits with error code 0 if no packages need updating (useful for continuous integration).
132
- *
133
- * @default 1
134
- */
135
- errorLevel?: number;
136
- /** Include only package names matching the given string, wildcard, glob, comma-or-space-delimited list, /regex/, or predicate function. Run "ncu --help --filter" for details. */
137
- filter?: string | RegExp | readonly (string | RegExp)[] | FilterFunction;
138
- /** Filters results based on a user provided predicate function after fetching new versions. Run "ncu --help --filterResults" for details. */
139
- filterResults?: FilterResultsFunction;
140
- /** Filter on package version using comma-or-space-delimited list, /regex/, or predicate function. Run "ncu --help --filterVersion" for details. */
141
- filterVersion?: string | RegExp | readonly (string | RegExp)[] | FilterFunction;
142
- /** Modify the output formatting or show additional information. Specify one or more comma-delimited values: dep, group, ownerChanged, repo, time, lines, installedVersion. Run "ncu --help --format" for details. */
143
- format?: readonly string[];
144
- /** Check global packages instead of in the current project. */
145
- global?: boolean;
146
- /** Customize how packages are divided into groups when using `--format group`. Run "ncu --help --groupFunction" for details. */
147
- groupFunction?: GroupFunction;
148
- /** Ignore directories containing package.json files (comma-delimited). */
149
- ignoreDirs?: string | readonly string[];
150
- /** Control the auto-install behavior: always, never, prompt. Run "ncu --help --install" for details.
151
- *
152
- * @default "prompt"
153
- */
154
- install?: 'always' | 'never' | 'prompt';
155
- /** Enable interactive prompts for each dependency; implies `-u` unless one of the json options are set. */
156
- interactive?: boolean;
157
- /** Output new package file instead of human-readable message. */
158
- jsonAll?: boolean;
159
- /** Like `jsonAll` but only lists `dependencies`, `devDependencies`, `optionalDependencies`, etc of the new package data. */
160
- jsonDeps?: boolean;
161
- /** Output upgraded dependencies in json. */
162
- jsonUpgraded?: boolean;
163
- /** Amount to log: silent, error, minimal, warn, info, verbose, silly.
164
- *
165
- * @default "warn"
166
- */
167
- loglevel?: string;
168
- /** Merges nested configs with the root config file for `--deep` or `--packageFile` options. (default: false) */
169
- mergeConfig?: boolean;
170
- /** Do not upgrade newer versions that are already satisfied by the version range according to semver. */
171
- minimal?: boolean;
172
- /** Package file data (you can also use stdin). */
173
- packageData?: string | PackageFile;
174
- /** Package file(s) location. (default: ./package.json) */
175
- packageFile?: string;
176
- /** npm, yarn, pnpm, deno, bun, staticRegistry (default: npm). Run "ncu --help --packageManager" for details. */
177
- packageManager?: 'npm' | 'yarn' | 'pnpm' | 'deno' | 'bun' | 'staticRegistry';
178
- /** Check peer dependencies of installed packages and filter updates to compatible versions. Run "ncu --help --peer" for details. */
179
- peer?: boolean;
180
- /** Include prerelease versions, e.g. -alpha.0, -beta.5, -rc.2. Automatically set to 1 when `--target` is newest or greatest, or when the current version is a prerelease. (default: 0) */
181
- pre?: boolean;
182
- /** Current working directory of npm. */
183
- prefix?: string;
184
- /** Specify the registry to use when looking up package versions. */
185
- registry?: string;
186
- /** Specify whether --registry refers to a full npm registry or a simple JSON file or url: npm, json. (default: npm) Run "ncu --help --registryType" for details. */
187
- registryType?: 'npm' | 'json';
188
- /** Exclude packages matching the given string, wildcard, glob, comma-or-space-delimited list, /regex/, or predicate function. Run "ncu --help --reject" for details. */
189
- reject?: string | RegExp | readonly (string | RegExp)[] | FilterFunction;
190
- /** Exclude package.json versions using comma-or-space-delimited list, /regex/, or predicate function. Run "ncu --help --rejectVersion" for details. */
191
- rejectVersion?: string | RegExp | readonly (string | RegExp)[] | FilterFunction;
192
- /** Remove version ranges from the final package version. */
193
- removeRange?: boolean;
194
- /** Number of times to retry failed requests for package info.
195
- *
196
- * @default 3
197
- */
198
- retry?: number;
199
- /** Runs updates on the root project in addition to specified workspaces. Only allowed with `--workspace` or `--workspaces`.
200
- *
201
- * @default true
202
- */
203
- root?: boolean;
204
- /** Don't output anything. Alias for `--loglevel` silent. */
205
- silent?: boolean;
206
- /** Read package.json from stdin. */
207
- stdin?: string;
208
- /** Determines the version to upgrade to: latest, newest, greatest, minor, patch, semver, `@[tag]`, or [function]. (default: latest) Run "ncu --help --target" for details. */
209
- target?: 'latest' | 'newest' | 'greatest' | 'minor' | 'patch' | 'semver' | `@${string}` | TargetFunction;
210
- /** Global timeout in milliseconds. (default: no global timeout and 30 seconds per npm-registry-fetch) */
211
- timeout?: number;
212
- /** Overwrite package file with upgraded versions instead of just outputting to console. */
213
- upgrade?: boolean;
214
- /** Log additional information for debugging. Alias for `--loglevel` verbose. */
215
- verbose?: boolean;
216
- /** Run on one or more specified workspaces. Add `--no-root` to exclude the root project. */
217
- workspace?: readonly string[];
218
- /** Run on all workspaces. Add `--no-root` to exclude the root project. */
219
- workspaces?: boolean;
220
- }
221
-
222
- /** A function that can be provided to the --target option for custom filtering. */
223
- declare type TargetFunction = (packageName: string, versionRange: SemVer[]) => string;
224
-
225
- declare type UpgradeGroup = 'major' | 'minor' | 'patch' | 'majorVersionZero' | 'none';
226
-
227
- /** An exact version number or value. Includes SemVer and some nonstandard variants for convenience. */
228
- declare type Version = string;
229
-
230
- /** A version specification or range supported as a value in package.json dependencies. Includes SemVer, git urls, npm urls, etc. */
231
- declare type VersionSpec = string;
232
-
233
- export { }
1
+ import { SemVer } from "semver-utils";
2
+
3
+ //#region src/types/IndexType.d.ts
4
+ /** A very generic object. */
5
+ type Index<T = any> = Record<string, T>;
6
+ //#endregion
7
+ //#region src/types/PackageFileRepository.d.ts
8
+ /** Represents the repository field in package.json. */
9
+ interface PackageFileRepository {
10
+ url: string;
11
+ directory?: string;
12
+ }
13
+ //#endregion
14
+ //#region src/types/VersionSpec.d.ts
15
+ /** A version specification or range supported as a value in package.json dependencies. Includes SemVer, git urls, npm urls, etc. */
16
+ type VersionSpec = string;
17
+ //#endregion
18
+ //#region src/types/PackageFile.d.ts
19
+ type NestedVersionSpecs = {
20
+ [name: string]: VersionSpec | NestedVersionSpecs;
21
+ };
22
+ /** The relevant bits of a parsed package.json file. */
23
+ interface PackageFile {
24
+ dependencies?: Index<VersionSpec>;
25
+ devDependencies?: Index<VersionSpec>;
26
+ imports?: Index<VersionSpec>;
27
+ engines?: Index<VersionSpec>;
28
+ name?: string;
29
+ packageManager?: string;
30
+ optionalDependencies?: Index<VersionSpec>;
31
+ overrides?: NestedVersionSpecs;
32
+ peerDependencies?: Index<VersionSpec>;
33
+ repository?: string | PackageFileRepository;
34
+ scripts?: Index<string>;
35
+ workspaces?: string[] | {
36
+ packages: string[];
37
+ };
38
+ version?: string;
39
+ }
40
+ //#endregion
41
+ //#region src/types/CooldownFunction.d.ts
42
+ /** A function that can be provided to the --cooldown option for custom cooldown predicate. */
43
+ type CooldownFunction = (packageName: string) => number | null;
44
+ //#endregion
45
+ //#region src/types/FilterFunction.d.ts
46
+ /** Supported function for the --filter and --reject options. */
47
+ type FilterFunction = (packageName: string, versionRange: SemVer[]) => boolean;
48
+ //#endregion
49
+ //#region src/types/Version.d.ts
50
+ /** An exact version number or value. Includes SemVer and some nonstandard variants for convenience. */
51
+ type Version = string;
52
+ //#endregion
53
+ //#region src/types/FilterResultsFunction.d.ts
54
+ type FilterResultsFunction = (packageName: string, versioningMetadata: {
55
+ currentVersion: VersionSpec;
56
+ currentVersionSemver: SemVer[];
57
+ upgradedVersion: Version;
58
+ upgradedVersionSemver: SemVer;
59
+ }) => boolean;
60
+ //#endregion
61
+ //#region src/types/UpgradeGroup.d.ts
62
+ type UpgradeGroup = 'major' | 'minor' | 'patch' | 'majorVersionZero' | 'none';
63
+ //#endregion
64
+ //#region src/types/GroupFunction.d.ts
65
+ /** Customize how packages are divided into groups when using `--format group`. Run "ncu --help --groupFunction" for details. */
66
+ type GroupFunction = (packageName: string, defaultGroup: UpgradeGroup, currentVersionSpec: SemVer[], upgradedVersionSpec: SemVer[], upgradedVersion: SemVer | null) => UpgradeGroup | string;
67
+ //#endregion
68
+ //#region src/types/TargetFunction.d.ts
69
+ /** A function that can be provided to the --target option for custom filtering. */
70
+ type TargetFunction = (packageName: string, versionRange: SemVer[]) => string;
71
+ //#endregion
72
+ //#region src/types/RunOptions.d.ts
73
+ /** Options that can be given on the CLI or passed to the ncu module to control all behavior. */
74
+ interface RunOptions {
75
+ /** Cache versions to a local cache file. Default `--cacheFile` is ~/.ncu-cache.json and default `--cacheExpiration` is 10 minutes. */
76
+ cache?: boolean;
77
+ /** Clear the default cache, or the cache file specified by `--cacheFile`. */
78
+ cacheClear?: boolean;
79
+ /** Cache expiration in minutes. Only works with `--cache`.
80
+ *
81
+ * @default 10
82
+ */
83
+ cacheExpiration?: number;
84
+ /** Filepath for the cache file. Only works with `--cache`.
85
+ *
86
+ * @default "~/.ncu-cache.json"
87
+ */
88
+ cacheFile?: string;
89
+ /** Force color in terminal. */
90
+ color?: boolean;
91
+ /** Max number of concurrent HTTP requests to registry.
92
+ *
93
+ * @default 8
94
+ */
95
+ concurrency?: number;
96
+ /** Config file name. (default: .ncurc.{json,yml,js,cjs}) */
97
+ configFileName?: string;
98
+ /** Directory of .ncurc config file. (default: directory of `packageFile`) */
99
+ configFilePath?: string;
100
+ /** Sets a minimum age (in days) for package versions to be considered for upgrade, reducing the risk of installing newly published, potentially compromised packages. Run "ncu --help --cooldown" for details. */
101
+ cooldown?: number | CooldownFunction;
102
+ /** Working directory in which npm will be executed. */
103
+ cwd?: string;
104
+ /** Run recursively in current working directory. Alias of (`--packageFile '**\/package.json'`). */
105
+ deep?: boolean;
106
+ /** Check one or more sections of dependencies only: dev, optional, peer, prod, or packageManager (comma-delimited).
107
+ *
108
+ * @default ["prod","dev","optional","packageManager"]
109
+ */
110
+ dep?: string | readonly string[];
111
+ /** Include deprecated packages. Use `--no-deprecated` to exclude deprecated packages (20–25% slower).
112
+ *
113
+ * @default true
114
+ */
115
+ deprecated?: boolean;
116
+ /** Iteratively installs upgrades and runs tests to identify breaking upgrades. Requires `-u` to execute. Run "ncu --help --doctor" for details. */
117
+ doctor?: boolean;
118
+ /** Specifies the install script to use in doctor mode. (default: `npm install` or the equivalent for your package manager) */
119
+ doctorInstall?: string;
120
+ /** Specifies the test script to use in doctor mode. (default: `npm test`) */
121
+ doctorTest?: string;
122
+ /** Include only packages that satisfy engines.node as specified in the package file. */
123
+ enginesNode?: boolean;
124
+ /** Set the error level. 1: exits with error code 0 if no errors occur. 2: exits with error code 0 if no packages need updating (useful for continuous integration).
125
+ *
126
+ * @default 1
127
+ */
128
+ errorLevel?: number;
129
+ /** Include only package names matching the given string, wildcard, glob, comma-or-space-delimited list, /regex/, or predicate function. Run "ncu --help --filter" for details. */
130
+ filter?: string | RegExp | readonly (string | RegExp)[] | FilterFunction;
131
+ /** Filters results based on a user provided predicate function after fetching new versions. Run "ncu --help --filterResults" for details. */
132
+ filterResults?: FilterResultsFunction;
133
+ /** Filter on package version using comma-or-space-delimited list, /regex/, or predicate function. Run "ncu --help --filterVersion" for details. */
134
+ filterVersion?: string | RegExp | readonly (string | RegExp)[] | FilterFunction;
135
+ /** Modify the output formatting or show additional information. Specify one or more comma-delimited values: dep, group, ownerChanged, repo, time, lines, installedVersion. Run "ncu --help --format" for details. */
136
+ format?: readonly string[];
137
+ /** Check global packages instead of in the current project. */
138
+ global?: boolean;
139
+ /** Customize how packages are divided into groups when using `--format group`. Run "ncu --help --groupFunction" for details. */
140
+ groupFunction?: GroupFunction;
141
+ /** Ignore directories containing package.json files (comma-delimited). */
142
+ ignoreDirs?: string | readonly string[];
143
+ /** Control the auto-install behavior: always, never, prompt. Run "ncu --help --install" for details.
144
+ *
145
+ * @default "prompt"
146
+ */
147
+ install?: 'always' | 'never' | 'prompt';
148
+ /** Enable interactive prompts for each dependency; implies `-u` unless one of the json options are set. */
149
+ interactive?: boolean;
150
+ /** Output new package file instead of human-readable message. */
151
+ jsonAll?: boolean;
152
+ /** Like `jsonAll` but only lists `dependencies`, `devDependencies`, `optionalDependencies`, etc of the new package data. */
153
+ jsonDeps?: boolean;
154
+ /** Output upgraded dependencies in json. */
155
+ jsonUpgraded?: boolean;
156
+ /** Amount to log: silent, error, minimal, warn, info, verbose, silly.
157
+ *
158
+ * @default "warn"
159
+ */
160
+ loglevel?: string;
161
+ /** Merges nested configs with the root config file for `--deep` or `--packageFile` options. (default: false) */
162
+ mergeConfig?: boolean;
163
+ /** Do not upgrade newer versions that are already satisfied by the version range according to semver. */
164
+ minimal?: boolean;
165
+ /** Package file data (you can also use stdin). */
166
+ packageData?: string | PackageFile;
167
+ /** Package file(s) location. (default: ./package.json) */
168
+ packageFile?: string;
169
+ /** npm, yarn, pnpm, deno, bun, staticRegistry (default: npm). Run "ncu --help --packageManager" for details. */
170
+ packageManager?: 'npm' | 'yarn' | 'pnpm' | 'deno' | 'bun' | 'staticRegistry';
171
+ /** Check peer dependencies of installed packages and filter updates to compatible versions. Run "ncu --help --peer" for details. */
172
+ peer?: boolean;
173
+ /** Include prerelease versions, e.g. -alpha.0, -beta.5, -rc.2. Automatically set to 1 when `--target` is newest or greatest, or when the current version is a prerelease. (default: 0) */
174
+ pre?: boolean;
175
+ /** Current working directory of npm. */
176
+ prefix?: string;
177
+ /** Specify the registry to use when looking up package versions. */
178
+ registry?: string;
179
+ /** Specify whether --registry refers to a full npm registry or a simple JSON file or url: npm, json. (default: npm) Run "ncu --help --registryType" for details. */
180
+ registryType?: 'npm' | 'json';
181
+ /** Exclude packages matching the given string, wildcard, glob, comma-or-space-delimited list, /regex/, or predicate function. Run "ncu --help --reject" for details. */
182
+ reject?: string | RegExp | readonly (string | RegExp)[] | FilterFunction;
183
+ /** Exclude package.json versions using comma-or-space-delimited list, /regex/, or predicate function. Run "ncu --help --rejectVersion" for details. */
184
+ rejectVersion?: string | RegExp | readonly (string | RegExp)[] | FilterFunction;
185
+ /** Remove version ranges from the final package version. */
186
+ removeRange?: boolean;
187
+ /** Number of times to retry failed requests for package info.
188
+ *
189
+ * @default 3
190
+ */
191
+ retry?: number;
192
+ /** Runs updates on the root project in addition to specified workspaces. Only allowed with `--workspace` or `--workspaces`.
193
+ *
194
+ * @default true
195
+ */
196
+ root?: boolean;
197
+ /** Don't output anything. Alias for `--loglevel` silent. */
198
+ silent?: boolean;
199
+ /** Read package.json from stdin. */
200
+ stdin?: string;
201
+ /** Determines the version to upgrade to: latest, newest, greatest, minor, patch, semver, `@[tag]`, or [function]. (default: latest) Run "ncu --help --target" for details. */
202
+ target?: 'latest' | 'newest' | 'greatest' | 'minor' | 'patch' | 'semver' | `@${string}` | TargetFunction;
203
+ /** Global timeout in milliseconds. (default: no global timeout and 30 seconds per npm-registry-fetch) */
204
+ timeout?: number;
205
+ /** Overwrite package file with upgraded versions instead of just outputting to console. */
206
+ upgrade?: boolean;
207
+ /** Log additional information for debugging. Alias for `--loglevel` verbose. */
208
+ verbose?: boolean;
209
+ /** Run on one or more specified workspaces. Add `--no-root` to exclude the root project. */
210
+ workspace?: readonly string[];
211
+ /** Run on all workspaces. Add `--no-root` to exclude the root project. */
212
+ workspaces?: boolean;
213
+ }
214
+ //#endregion
215
+ //#region src/types/RcOptions.d.ts
216
+ /** Options that would make no sense in a .ncurc file */
217
+ type Nonsensical = 'configFileName' | 'configFilePath' | 'cwd' | 'packageData' | 'stdin';
218
+ /** Expected options that might be found in an .ncurc file. Since the config is external, this cannot be guaranteed */
219
+ type RcOptions = Omit<RunOptions, Nonsensical> & {
220
+ $schema?: string;
221
+ format?: string | string[];
222
+ };
223
+ //#endregion
224
+ //#region src/lib/defineConfig.d.ts
225
+ /**
226
+ * TypeScript helper for .npmrc config file. Similar to vite and eslint's
227
+ * defineConfig helper
228
+ */
229
+ declare function defineConfig(config: RcOptions): RcOptions;
230
+ //#endregion
231
+ //#region src/index.d.ts
232
+ /** Main entry point.
233
+ *
234
+ * @returns Promise<
235
+ * PackageFile Default returns upgraded package file.
236
+ * | Index<VersionSpec> --jsonUpgraded returns only upgraded dependencies.
237
+ * | void --global upgrade returns void.
238
+ * >
239
+ */
240
+ declare function run(runOptions?: RunOptions, {
241
+ cli
242
+ }?: {
243
+ cli?: boolean;
244
+ }): Promise<PackageFile | Index<VersionSpec> | void>;
245
+ //#endregion
246
+ export { type RcOptions, type RunOptions, run as default, run, defineConfig };
247
+ //# sourceMappingURL=index.d.ts.map