@verdaccio/config 8.0.0-next-8.21 → 8.0.0-next-8.23
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/address.d.ts +2 -2
- package/build/address.js +13 -9
- package/build/address.js.map +1 -1
- package/build/conf/default.yaml +4 -0
- package/build/config-path.js.map +1 -1
- package/package.json +3 -3
package/build/address.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Logger } from '@verdaccio/types';
|
|
1
|
+
import { ListenAddress as ConfigListenAddress, Logger } from '@verdaccio/types';
|
|
2
2
|
export interface ListenAddress {
|
|
3
3
|
proto: string;
|
|
4
4
|
host?: string;
|
|
@@ -31,4 +31,4 @@ export declare function parseAddress(urlAddress: string): ListenAddress | null;
|
|
|
31
31
|
- localhost:5557
|
|
32
32
|
@return {Array}
|
|
33
33
|
*/
|
|
34
|
-
export declare function getListenAddress(listen:
|
|
34
|
+
export declare function getListenAddress(listen: ConfigListenAddress | string | undefined, logger: Logger): ListenAddress;
|
package/build/address.js
CHANGED
|
@@ -79,24 +79,28 @@ function getListenAddress(listen, logger) {
|
|
|
79
79
|
throw new Error('Listen addresses array cannot be empty');
|
|
80
80
|
}
|
|
81
81
|
const invalid = [];
|
|
82
|
+
const valid = [];
|
|
82
83
|
for (const raw of filteredListen) {
|
|
83
84
|
const candidate = parseAddress(raw);
|
|
84
85
|
if (candidate) {
|
|
85
86
|
debug('valid listen address found: %o', candidate);
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
logger.warn(`Multiple listen addresses are not supported, using the first valid one ${addrToString(candidate)}`);
|
|
91
|
-
}
|
|
92
|
-
return candidate;
|
|
87
|
+
valid.push(candidate);
|
|
88
|
+
} else {
|
|
89
|
+
debug('invalid address found: %o', raw);
|
|
90
|
+
invalid.push(raw);
|
|
93
91
|
}
|
|
94
|
-
invalid.push(raw);
|
|
95
92
|
}
|
|
96
93
|
invalid.forEach(bad => logger.warn({
|
|
97
94
|
addr: bad
|
|
98
95
|
}, 'invalid address - @{addr}, we expect a port (e.g. "4873"), ' + 'host:port (e.g. "localhost:4873"), full url ' + '(e.g. "http://localhost:4873/") or unix:/path/socket'));
|
|
99
|
-
|
|
96
|
+
if (valid.length === 0) {
|
|
97
|
+
throw new Error('No valid listen addresses found in configuration array');
|
|
98
|
+
}
|
|
99
|
+
const firstValid = valid[0];
|
|
100
|
+
if (listen.length > 1) {
|
|
101
|
+
logger.warn(`Multiple listen addresses are not supported, using the first valid one ${addrToString(firstValid)}`);
|
|
102
|
+
}
|
|
103
|
+
return firstValid;
|
|
100
104
|
}
|
|
101
105
|
const single = parseAddress(listen);
|
|
102
106
|
if (!single) {
|
package/build/address.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"address.js","names":["_debug","_interopRequireDefault","require","_core","e","__esModule","default","debug","createDebug","parseAddress","urlAddress","urlPattern","exec","proto","DEFAULT_PROTOCOL","host","DEFAULT_DOMAIN","port","DEFAULT_PORT","unixPattern","path","addrToString","a","getListenAddress","listen","logger","Array","isArray","filteredListen","filter","item","length","Error","invalid","raw","candidate","forEach","bad","warn","addr","
|
|
1
|
+
{"version":3,"file":"address.js","names":["_debug","_interopRequireDefault","require","_core","e","__esModule","default","debug","createDebug","parseAddress","urlAddress","urlPattern","exec","proto","DEFAULT_PROTOCOL","host","DEFAULT_DOMAIN","port","DEFAULT_PORT","unixPattern","path","addrToString","a","getListenAddress","listen","logger","Array","isArray","filteredListen","filter","item","length","Error","invalid","valid","raw","candidate","push","forEach","bad","warn","addr","firstValid","single"],"sources":["../src/address.ts"],"sourcesContent":["import createDebug from 'debug';\n\nimport { DEFAULT_DOMAIN, DEFAULT_PORT, DEFAULT_PROTOCOL } from '@verdaccio/core';\nimport { ListenAddress as ConfigListenAddress, Logger } from '@verdaccio/types';\n\nconst debug = createDebug('verdaccio:config:address');\n\nexport interface ListenAddress {\n proto: string;\n host?: string;\n port?: string;\n path?: string;\n}\n\n/**\n * Parse an internet address\n * Allow:\n - https:localhost:1234 - protocol + host + port\n - localhost:1234 - host + port\n - 1234 - port\n - http::1234 - protocol + port\n - https://localhost:443/ - full url + https\n - http://[::1]:443/ - ipv6\n - unix:/tmp/http.sock - unix sockets\n - https://unix:/tmp/http.sock - unix sockets (https)\n * @param {*} urlAddress the internet address definition\n * @return {Object|Null} literal object that represent the address parsed\n */\nexport function parseAddress(urlAddress: string): ListenAddress | null {\n //\n // TODO: refactor it to something more reasonable?\n //\n // protocol : // ( host )|( ipv6 ): port /\n const urlPattern = /^((https?):(\\/\\/)?)?((([^\\/:]*)|\\[([^\\[\\]]+)\\]):)?(\\d+)\\/?$/.exec(urlAddress);\n\n if (urlPattern) {\n return {\n proto: urlPattern[2] || DEFAULT_PROTOCOL,\n host: urlPattern[6] || urlPattern[7] || DEFAULT_DOMAIN,\n port: urlPattern[8] || DEFAULT_PORT,\n };\n }\n\n const unixPattern = /^(?:(https?):\\/\\/)?unix:(\\/.*)$/.exec(urlAddress);\n if (!unixPattern) {\n // if we cannot match the unix pattern, we return null\n // this is to avoid returning a wrong object\n return null;\n }\n\n return {\n host: unixPattern[2],\n proto: unixPattern[1] || 'unix',\n path: unixPattern[2],\n };\n}\n\nfunction addrToString(a: ListenAddress): string {\n return a.proto === 'unix' ? `unix:${a.host}` : `${a.proto}://${a.host}:${a.port}`;\n}\n\n/**\n * Retrieve all addresses defined in the config file.\n * Verdaccio is able to listen multiple ports\n * @param {String} argListen\n * @param {String} configListen\n * eg:\n * listen:\n - localhost:5555\n - localhost:5557\n @return {Array}\n */\nexport function getListenAddress(\n listen: ConfigListenAddress | string | undefined,\n logger: Logger\n): ListenAddress {\n debug('getListenAddress called with %o', listen);\n\n if (!listen) {\n debug('No listen address provided, using default');\n return { proto: DEFAULT_PROTOCOL, host: DEFAULT_DOMAIN, port: DEFAULT_PORT };\n }\n\n if (Array.isArray(listen)) {\n const filteredListen = listen.filter((item) => typeof item === 'string');\n\n if (filteredListen.length === 0) {\n throw new Error('Listen addresses array cannot be empty');\n }\n\n const invalid: string[] = [];\n const valid: ListenAddress[] = [];\n\n for (const raw of filteredListen) {\n const candidate = parseAddress(raw as string);\n if (candidate) {\n debug('valid listen address found: %o', candidate);\n valid.push(candidate);\n } else {\n debug('invalid address found: %o', raw);\n invalid.push(raw as string);\n }\n }\n\n invalid.forEach((bad) =>\n logger.warn(\n { addr: bad },\n 'invalid address - @{addr}, we expect a port (e.g. \"4873\"), ' +\n 'host:port (e.g. \"localhost:4873\"), full url ' +\n '(e.g. \"http://localhost:4873/\") or unix:/path/socket'\n )\n );\n\n if (valid.length === 0) {\n throw new Error('No valid listen addresses found in configuration array');\n }\n\n const firstValid = valid[0];\n\n if (listen.length > 1) {\n logger.warn(\n `Multiple listen addresses are not supported, using the first valid one ${addrToString(\n firstValid\n )}`\n );\n }\n\n return firstValid;\n }\n\n const single = parseAddress(listen as string);\n if (!single) {\n throw new Error(\n `Invalid address - ${listen}, we expect a port (e.g. \"4873\"), ` +\n `host:port (e.g. \"localhost:4873\"), full url ` +\n `(e.g. \"http://localhost:4873/\") or unix:/path/socket`\n );\n }\n return single;\n}\n"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AAEA,IAAAC,KAAA,GAAAD,OAAA;AAAiF,SAAAD,uBAAAG,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAGjF,MAAMG,KAAK,GAAG,IAAAC,cAAW,EAAC,0BAA0B,CAAC;AASrD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAASC,YAAYA,CAACC,UAAkB,EAAwB;EACrE;EACA;EACA;EACA;EACA,MAAMC,UAAU,GAAG,6DAA6D,CAACC,IAAI,CAACF,UAAU,CAAC;EAEjG,IAAIC,UAAU,EAAE;IACd,OAAO;MACLE,KAAK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ount of users allowed to register, defaults to "+inf".
|
|
73
73
|
# You can set this to -1 to disable registration.
|
|
74
74
|
# max_users: 1000
|
|
75
|
+
# Hash algorithm, possible options are: "bcrypt", "md5", "sha1", "crypt".
|
|
76
|
+
# algorithm: bcrypt # by default is crypt, but is recommended use bcrypt for new installations
|
|
77
|
+
# Rounds number for "bcrypt", will be ignored for other algorithms.
|
|
78
|
+
# rounds: 10
|
|
75
79
|
|
|
76
80
|
# A list of other known repositories we can talk to
|
|
77
81
|
# https://verdaccio.org/docs/configuration#uplinks
|
package/build/config-path.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-path.js","names":["_debug","_interopRequireDefault","require","_lodash","_nodeFs","_nodeOs","_nodePath","_configUtils","e","__esModule","default","CONFIG_FILE","XDG","pkgJSON","name","debug","buildDebug","findConfigFile","configPath","configLocation","path","resolve","configPaths","getConfigPaths","length","Error","primaryConf","_","find","fileExists","createConfigFile","createConfigFolder","defaultConfig","updateStorageLinks","readDefaultConfig","fs","writeFileSync","pathDefaultConf","__dirname","accessSync","constants","R_OK","TypeError","readFileSync","folder","dirname","mkdirSync","recursive","type","dataDir","process","env","XDG_DATA_HOME","join","HOME","folderExists","replace","listPaths","getXDGDirectory","getWindowsDirectory","getRelativeDefaultDirectory","getOldDirectory","reduce","acc","currentValue","push","xDGConfigPath","XDG_CONFIG_HOME","os","platform","APPDATA","relativePath","oldPath"],"sources":["../src/config-path.ts"],"sourcesContent":["import buildDebug from 'debug';\nimport _ from 'lodash';\nimport fs from 'node:fs';\nimport os from 'node:os';\nimport path from 'node:path';\n\nimport { fileExists, folderExists } from './config-utils';\n\nconst CONFIG_FILE = 'config.yaml';\nconst XDG = 'xdg';\n// eslint-disable-next-line\nconst pkgJSON = {\n name: 'verdaccio',\n};\n\nexport type SetupDirectory = {\n path: string;\n type: 'xdg' | 'win' | 'win32' | 'def' | 'old';\n};\n\nconst debug = buildDebug('verdaccio:config:config-path');\n\n/**\n * Find and get the first config file that match.\n * @return {String} the config file path\n */\nfunction findConfigFile(configPath?: string): string {\n debug('searching for config file %o', configPath);\n if (typeof configPath !== 'undefined') {\n const configLocation = path.resolve(configPath);\n debug('custom location %s', configLocation);\n return configLocation;\n }\n\n const configPaths: SetupDirectory[] = getConfigPaths();\n debug('%o posible locations found', configPaths.length);\n if (configPaths.length === 0) {\n debug('no configuration files can be processed');\n // this should never happens\n throw new Error('no configuration files can be processed');\n }\n\n // find the first location that already exist\n const primaryConf: SetupDirectory | void = _.find(configPaths, (configLocation: SetupDirectory) =>\n fileExists(configLocation.path)\n );\n\n if (typeof primaryConf !== 'undefined') {\n debug('at least one primary location detected at %s', primaryConf?.path);\n return primaryConf.path;\n }\n debug('no previous location found, creating a new one');\n debug('generating the first match path location %s', configPaths[0].path);\n return createConfigFile(configPaths[0]).path;\n}\n\nfunction createConfigFile(configLocation: SetupDirectory): SetupDirectory {\n createConfigFolder(configLocation);\n\n const defaultConfig = updateStorageLinks(configLocation, readDefaultConfig());\n\n fs.writeFileSync(configLocation.path, defaultConfig);\n\n return configLocation;\n}\n\nexport function readDefaultConfig(): string {\n const pathDefaultConf: string = path.resolve(__dirname, 'conf/default.yaml');\n try {\n debug('the path of default config used from %s', pathDefaultConf);\n fs.accessSync(pathDefaultConf, fs.constants.R_OK);\n debug('configuration file has enough permissions for reading');\n } catch {\n debug('configuration file does not have enough permissions for reading');\n throw new TypeError('configuration file does not have enough permissions for reading');\n }\n\n return fs.readFileSync(pathDefaultConf, 'utf8');\n}\n\nfunction createConfigFolder(configLocation): void {\n const folder = path.dirname(configLocation.path);\n debug(`creating default config file folder at %o`, folder);\n fs.mkdirSync(folder, { recursive: true });\n debug(`folder %o created`, folder);\n}\n\n/**\n * Update the storage links to the new location if it is necessary.\n * @param configLocation\n * @param defaultConfig\n * @returns\n */\nfunction updateStorageLinks(configLocation: SetupDirectory, defaultConfig: string): string {\n debug('checking storage links for %s and type %s', configLocation.path, configLocation.type);\n if (configLocation.type !== XDG) {\n debug(`skip storage override for %s`, configLocation.type);\n return defaultConfig;\n }\n\n // $XDG_DATA_HOME defines the base directory relative to which user specific data\n // files should be stored, If $XDG_DATA_HOME is either not set or empty, a default\n // equal to $HOME/.local/share should be used.\n let dataDir =\n process.env.XDG_DATA_HOME || path.join(process.env.HOME as string, '.local', 'share');\n if (folderExists(dataDir)) {\n debug(`previous storage located`);\n debug(`update storage links to %s`, dataDir);\n dataDir = path.resolve(path.join(dataDir, pkgJSON.name, 'storage'));\n return defaultConfig.replace(/^storage: .\\/storage$/m, `storage: ${dataDir}`);\n }\n debug(`could not find a previous storage location, skip override`);\n return defaultConfig;\n}\n\n/**\n * Return a list of configuration locations by platform.\n * @returns\n */\nfunction getConfigPaths(): SetupDirectory[] {\n const listPaths: (SetupDirectory | void)[] = [\n getXDGDirectory(),\n getWindowsDirectory(),\n getRelativeDefaultDirectory(),\n getOldDirectory(),\n ];\n\n return listPaths.reduce(function (acc, currentValue: SetupDirectory | void): SetupDirectory[] {\n if (typeof currentValue !== 'undefined') {\n debug(\n 'posible directory path generated %s for type %s',\n currentValue?.path,\n currentValue.type\n );\n acc.push(currentValue);\n }\n return acc;\n }, [] as SetupDirectory[]);\n}\n\n/**\n * Get XDG_CONFIG_HOME or HOME location (usually unix)\n *\n * The XDG_CONFIG_HOME environment variable is also part of the XDG Base Directory Specification,\n * which aims to standardize the locations where applications store configuration files and other\n * user-specific data on Unix-like operating systems.\n *\n *\n *\n * https://specifications.freedesktop.org/basedir-spec/latest/\n *\n *\n * @returns\n */\nconst getXDGDirectory = (): SetupDirectory | void => {\n const xDGConfigPath =\n process.env.XDG_CONFIG_HOME || (process.env.HOME && path.join(process.env.HOME, '.config'));\n debug('XDGConfig folder path %s', xDGConfigPath);\n if (xDGConfigPath && folderExists(xDGConfigPath)) {\n debug('XDGConfig folder path %s', xDGConfigPath);\n return {\n path: path.join(xDGConfigPath, pkgJSON.name, CONFIG_FILE),\n type: XDG,\n };\n }\n};\n\n/**\n * Detect windows location, APPDATA\n * usually something like C:\\User\\<Build User>\\AppData\\Local\n * @returns\n */\nconst getWindowsDirectory = (): SetupDirectory | void => {\n if (os.platform() === 'win32' && process.env.APPDATA && folderExists(process.env.APPDATA)) {\n debug('windows appdata folder path %s', process.env.APPDATA);\n return {\n path: path.resolve(path.join(process.env.APPDATA, pkgJSON.name, CONFIG_FILE)),\n type: 'win',\n };\n }\n};\n\n/**\n * Return relative directory, this is the default.\n * It will cretate config in your {currentLocation/verdaccio/config.yaml}\n * @returns\n */\nconst getRelativeDefaultDirectory = (): SetupDirectory => {\n const relativePath = path.resolve(path.join('.', pkgJSON.name, CONFIG_FILE));\n debug('relative folder path %s', relativePath);\n return {\n path: relativePath,\n type: 'def',\n };\n};\n\n/**\n * This should never happens, consider it DEPRECATED\n * @returns\n */\nconst getOldDirectory = (): SetupDirectory => {\n const oldPath = path.resolve(path.join('.', CONFIG_FILE));\n debug('old folder path %s', oldPath);\n return {\n path: oldPath,\n type: 'old',\n };\n};\n\nexport { findConfigFile };\n"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,OAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,OAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,OAAA,GAAAJ,sBAAA,CAAAC,OAAA;AACA,IAAAI,SAAA,GAAAL,sBAAA,CAAAC,OAAA;AAEA,IAAAK,YAAA,GAAAL,OAAA;AAA0D,SAAAD,uBAAAO,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAE1D,MAAMG,WAAW,GAAG,aAAa;AACjC,MAAMC,GAAG,GAAG,KAAK;AACjB;AACA,MAAMC,OAAO,GAAG;EACdC,IAAI,EAAE;AACR,CAAC;AAOD,MAAMC,KAAK,GAAG,IAAAC,cAAU,EAAC,8BAA8B,CAAC;;AAExD;AACA;AACA;AACA;AACA,SAASC,cAAcA,C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C5C,MAAMW,OAAO,GAAGpD,iBAAI,CAACC,OAAO,CAACD,iBAAI,CAACiC,IAAI,CAAC,GAAG,EAAE1C,WAAW,CAAC,CAAC;EACzDI,KAAK,CAAC,oBAAoB,EAAEyD,OAAO,CAAC;EACpC,OAAO;IACLpD,IAAI,EAAEoD,OAAO;IACbxB,IAAI,EAAE;EACR,CAAC;AACH,CAAC","ignoreList":[]}
|
|
1
|
+
{"version":3,"file":"config-path.js","names":["_debug","_interopRequireDefault","require","_lodash","_nodeFs","_nodeOs","_nodePath","_configUtils","e","__esModule","default","CONFIG_FILE","XDG","pkgJSON","name","debug","buildDebug","findConfigFile","configPath","configLocation","path","resolve","configPaths","getConfigPaths","length","Error","primaryConf","_","find","fileExists","createConfigFile","createConfigFolder","defaultConfig","updateStorageLinks","readDefaultConfig","fs","writeFileSync","pathDefaultConf","__dirname","accessSync","constants","R_OK","TypeError","readFileSync","folder","dirname","mkdirSync","recursive","type","dataDir","process","env","XDG_DATA_HOME","join","HOME","folderExists","replace","listPaths","getXDGDirectory","getWindowsDirectory","getRelativeDefaultDirectory","getOldDirectory","reduce","acc","currentValue","push","xDGConfigPath","XDG_CONFIG_HOME","os","platform","APPDATA","relativePath","oldPath"],"sources":["../src/config-path.ts"],"sourcesContent":["import buildDebug from 'debug';\nimport _ from 'lodash';\nimport fs from 'node:fs';\nimport os from 'node:os';\nimport path from 'node:path';\n\nimport { fileExists, folderExists } from './config-utils';\n\nconst CONFIG_FILE = 'config.yaml';\nconst XDG = 'xdg';\n// eslint-disable-next-line\nconst pkgJSON = {\n name: 'verdaccio',\n};\n\nexport type SetupDirectory = {\n path: string;\n type: 'xdg' | 'win' | 'win32' | 'def' | 'old';\n};\n\nconst debug = buildDebug('verdaccio:config:config-path');\n\n/**\n * Find and get the first config file that match.\n * @return {String} the config file path\n */\nfunction findConfigFile(configPath?: string): string {\n debug('searching for config file %o', configPath);\n if (typeof configPath !== 'undefined') {\n const configLocation = path.resolve(configPath);\n debug('custom location %s', configLocation);\n return configLocation;\n }\n\n const configPaths: SetupDirectory[] = getConfigPaths();\n debug('%o posible locations found', configPaths.length);\n if (configPaths.length === 0) {\n debug('no configuration files can be processed');\n // this should never happens\n throw new Error('no configuration files can be processed');\n }\n\n // find the first location that already exist\n const primaryConf: SetupDirectory | void = _.find(configPaths, (configLocation: SetupDirectory) =>\n fileExists(configLocation.path)\n );\n\n if (typeof primaryConf !== 'undefined') {\n debug('at least one primary location detected at %s', primaryConf?.path);\n return primaryConf.path;\n }\n debug('no previous location found, creating a new one');\n debug('generating the first match path location %s', configPaths[0].path);\n return createConfigFile(configPaths[0]).path;\n}\n\nfunction createConfigFile(configLocation: SetupDirectory): SetupDirectory {\n createConfigFolder(configLocation);\n\n const defaultConfig = updateStorageLinks(configLocation, readDefaultConfig());\n\n fs.writeFileSync(configLocation.path, defaultConfig);\n\n return configLocation;\n}\n\nexport function readDefaultConfig(): string {\n const pathDefaultConf: string = path.resolve(__dirname, 'conf/default.yaml');\n try {\n debug('the path of default config used from %s', pathDefaultConf);\n fs.accessSync(pathDefaultConf, fs.constants.R_OK);\n debug('configuration file has enough permissions for reading');\n } catch {\n debug('configuration file does not have enough permissions for reading');\n throw new TypeError('configuration file does not have enough permissions for reading');\n }\n\n return fs.readFileSync(pathDefaultConf, 'utf8');\n}\n\nfunction createConfigFolder(configLocation: SetupDirectory): void {\n const folder = path.dirname(configLocation.path);\n debug(`creating default config file folder at %o`, folder);\n fs.mkdirSync(folder, { recursive: true });\n debug(`folder %o created`, folder);\n}\n\n/**\n * Update the storage links to the new location if it is necessary.\n * @param configLocation\n * @param defaultConfig\n * @returns\n */\nfunction updateStorageLinks(configLocation: SetupDirectory, defaultConfig: string): string {\n debug('checking storage links for %s and type %s', configLocation.path, configLocation.type);\n if (configLocation.type !== XDG) {\n debug(`skip storage override for %s`, configLocation.type);\n return defaultConfig;\n }\n\n // $XDG_DATA_HOME defines the base directory relative to which user specific data\n // files should be stored, If $XDG_DATA_HOME is either not set or empty, a default\n // equal to $HOME/.local/share should be used.\n let dataDir =\n process.env.XDG_DATA_HOME || path.join(process.env.HOME as string, '.local', 'share');\n if (folderExists(dataDir)) {\n debug(`previous storage located`);\n debug(`update storage links to %s`, dataDir);\n dataDir = path.resolve(path.join(dataDir, pkgJSON.name, 'storage'));\n return defaultConfig.replace(/^storage: .\\/storage$/m, `storage: ${dataDir}`);\n }\n debug(`could not find a previous storage location, skip override`);\n return defaultConfig;\n}\n\n/**\n * Return a list of configuration locations by platform.\n * @returns\n */\nfunction getConfigPaths(): SetupDirectory[] {\n const listPaths: (SetupDirectory | void)[] = [\n getXDGDirectory(),\n getWindowsDirectory(),\n getRelativeDefaultDirectory(),\n getOldDirectory(),\n ];\n\n return listPaths.reduce(function (acc, currentValue: SetupDirectory | void): SetupDirectory[] {\n if (typeof currentValue !== 'undefined') {\n debug(\n 'posible directory path generated %s for type %s',\n currentValue?.path,\n currentValue.type\n );\n acc.push(currentValue);\n }\n return acc;\n }, [] as SetupDirectory[]);\n}\n\n/**\n * Get XDG_CONFIG_HOME or HOME location (usually unix)\n *\n * The XDG_CONFIG_HOME environment variable is also part of the XDG Base Directory Specification,\n * which aims to standardize the locations where applications store configuration files and other\n * user-specific data on Unix-like operating systems.\n *\n *\n *\n * https://specifications.freedesktop.org/basedir-spec/latest/\n *\n *\n * @returns\n */\nconst getXDGDirectory = (): SetupDirectory | void => {\n const xDGConfigPath =\n process.env.XDG_CONFIG_HOME || (process.env.HOME && path.join(process.env.HOME, '.config'));\n debug('XDGConfig folder path %s', xDGConfigPath);\n if (xDGConfigPath && folderExists(xDGConfigPath)) {\n debug('XDGConfig folder path %s', xDGConfigPath);\n return {\n path: path.join(xDGConfigPath, pkgJSON.name, CONFIG_FILE),\n type: XDG,\n };\n }\n};\n\n/**\n * Detect windows location, APPDATA\n * usually something like C:\\User\\<Build User>\\AppData\\Local\n * @returns\n */\nconst getWindowsDirectory = (): SetupDirectory | void => {\n if (os.platform() === 'win32' && process.env.APPDATA && folderExists(process.env.APPDATA)) {\n debug('windows appdata folder path %s', process.env.APPDATA);\n return {\n path: path.resolve(path.join(process.env.APPDATA, pkgJSON.name, CONFIG_FILE)),\n type: 'win',\n };\n }\n};\n\n/**\n * Return relative directory, this is the default.\n * It will cretate config in your {currentLocation/verdaccio/config.yaml}\n * @returns\n */\nconst getRelativeDefaultDirectory = (): SetupDirectory => {\n const relativePath = path.resolve(path.join('.', pkgJSON.name, CONFIG_FILE));\n debug('relative folder path %s', relativePath);\n return {\n path: relativePath,\n type: 'def',\n };\n};\n\n/**\n * This should never happens, consider it DEPRECATED\n * @returns\n */\nconst getOldDirectory = (): SetupDirectory => {\n const oldPath = path.resolve(path.join('.', CONFIG_FILE));\n debug('old folder path %s', oldPath);\n return {\n path: oldPath,\n type: 'old',\n };\n};\n\nexport { findConfigFile };\n"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,OAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,OAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,OAAA,GAAAJ,sBAAA,CAAAC,OAAA;AACA,IAAAI,SAAA,GAAAL,sBAAA,CAAAC,OAAA;AAEA,IAAAK,YAAA,GAAAL,OAAA;AAA0D,SAAAD,uBAAAO,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAE1D,MAAMG,WAAW,GAAG,aAAa;AACjC,MAAMC,GAAG,GAAG,KAAK;AACjB;AACA,MAAMC,OAAO,GAAG;EACdC,IAAI,EAAE;AACR,CAAC;AAOD,MAAMC,KAAK,GAAG,IAAAC,cAAU,EAAC,8BAA8B,CAAC;;AAExD;AACA;AACA;AACA;AACA,SAASC,cAAcA,CAACC,UAAmB,EAAU;EACnDH,KAAK,CAAC,8BAA8B,EAAEG,UAAU,CAAC;EACjD,IAAI,OAAOA,UAAU,KAAK,WAAW,EAAE;IACrC,MA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I,KAAK,CAAC,oBAAoB,EAAEyD,OAAO,CAAC;EACpC,OAAO;IACLpD,IAAI,EAAEoD,OAAO;IACbxB,IAAI,EAAE;EACR,CAAC;AACH,CAAC","ignoreList":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@verdaccio/config",
|
|
3
|
-
"version": "8.0.0-next-8.
|
|
3
|
+
"version": "8.0.0-next-8.23",
|
|
4
4
|
"description": "Verdaccio Configuration",
|
|
5
5
|
"main": "./build/index.js",
|
|
6
6
|
"types": "build/index.d.ts",
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
"node": ">=18"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@verdaccio/core": "8.0.0-next-8.
|
|
37
|
-
"debug": "4.4.
|
|
36
|
+
"@verdaccio/core": "8.0.0-next-8.23",
|
|
37
|
+
"debug": "4.4.3",
|
|
38
38
|
"js-yaml": "4.1.0",
|
|
39
39
|
"lodash": "4.17.21",
|
|
40
40
|
"minimatch": "7.4.6"
|