@ms-cloudpack/path-utilities 2.7.28 → 2.7.30

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.
@@ -1,2 +1,5 @@
1
+ /**
2
+ * Replace the symbols `{homedir}` and `{tmpdir}` with their respective values.
3
+ */
1
4
  export declare function pathSymbolReplacement(str: string): string;
2
5
  //# sourceMappingURL=pathSymbolReplacement.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"pathSymbolReplacement.d.ts","sourceRoot":"","sources":["../src/pathSymbolReplacement.ts"],"names":[],"mappings":"AAQA,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAGzD"}
1
+ {"version":3,"file":"pathSymbolReplacement.d.ts","sourceRoot":"","sources":["../src/pathSymbolReplacement.ts"],"names":[],"mappings":"AAQA;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAGzD"}
@@ -4,6 +4,9 @@ const fileSymbols = {
4
4
  homedir: os.homedir(),
5
5
  tmpdir: os.tmpdir(),
6
6
  };
7
+ /**
8
+ * Replace the symbols `{homedir}` and `{tmpdir}` with their respective values.
9
+ */
7
10
  export function pathSymbolReplacement(str) {
8
11
  // Replace the file symbols.
9
12
  return str.replace(/{(\w+)}/g, (match, symbol) => fileSymbols[symbol] || match);
@@ -1 +1 @@
1
- {"version":3,"file":"pathSymbolReplacement.js","sourceRoot":"","sources":["../src/pathSymbolReplacement.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,CAAC;AAEpB,0BAA0B;AAC1B,MAAM,WAAW,GAA2B;IAC1C,OAAO,EAAE,EAAE,CAAC,OAAO,EAAE;IACrB,MAAM,EAAE,EAAE,CAAC,MAAM,EAAE;CACpB,CAAC;AAEF,MAAM,UAAU,qBAAqB,CAAC,GAAW;IAC/C,4BAA4B;IAC5B,OAAO,GAAG,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,KAAK,EAAE,MAAc,EAAE,EAAE,CAAC,WAAW,CAAC,MAAM,CAAC,IAAI,KAAK,CAAC,CAAC;AAC1F,CAAC","sourcesContent":["import os from 'os';\n\n// Supported file symbols:\nconst fileSymbols: Record<string, string> = {\n homedir: os.homedir(),\n tmpdir: os.tmpdir(),\n};\n\nexport function pathSymbolReplacement(str: string): string {\n // Replace the file symbols.\n return str.replace(/{(\\w+)}/g, (match, symbol: string) => fileSymbols[symbol] || match);\n}\n"]}
1
+ {"version":3,"file":"pathSymbolReplacement.js","sourceRoot":"","sources":["../src/pathSymbolReplacement.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,CAAC;AAEpB,0BAA0B;AAC1B,MAAM,WAAW,GAA2B;IAC1C,OAAO,EAAE,EAAE,CAAC,OAAO,EAAE;IACrB,MAAM,EAAE,EAAE,CAAC,MAAM,EAAE;CACpB,CAAC;AAEF;;GAEG;AACH,MAAM,UAAU,qBAAqB,CAAC,GAAW;IAC/C,4BAA4B;IAC5B,OAAO,GAAG,CAAC,OAAO,CAAC,UAAU,EAAE,CAAC,KAAK,EAAE,MAAc,EAAE,EAAE,CAAC,WAAW,CAAC,MAAM,CAAC,IAAI,KAAK,CAAC,CAAC;AAC1F,CAAC","sourcesContent":["import os from 'os';\n\n// Supported file symbols:\nconst fileSymbols: Record<string, string> = {\n homedir: os.homedir(),\n tmpdir: os.tmpdir(),\n};\n\n/**\n * Replace the symbols `{homedir}` and `{tmpdir}` with their respective values.\n */\nexport function pathSymbolReplacement(str: string): string {\n // Replace the file symbols.\n return str.replace(/{(\\w+)}/g, (match, symbol: string) => fileSymbols[symbol] || match);\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ms-cloudpack/path-utilities",
3
- "version": "2.7.28",
3
+ "version": "2.7.30",
4
4
  "description": "Utilities for resolving paths between source/intermediate/output locations in Cloudpack.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -24,11 +24,11 @@
24
24
  "test": "cloudpack-scripts test"
25
25
  },
26
26
  "dependencies": {
27
- "@ms-cloudpack/path-string-parsing": "^1.2.3",
27
+ "@ms-cloudpack/path-string-parsing": "^1.2.4",
28
28
  "fast-glob": "^3.2.12"
29
29
  },
30
30
  "devDependencies": {
31
- "@ms-cloudpack/common-types": "^0.13.2",
31
+ "@ms-cloudpack/common-types": "^0.13.4",
32
32
  "@ms-cloudpack/eslint-plugin-internal": "^0.0.1",
33
33
  "@ms-cloudpack/scripts": "^0.0.1",
34
34
  "@ms-cloudpack/test-utilities": "^0.5.0"