Skip to content

Commit

Permalink
chore(types): add node type
Browse files Browse the repository at this point in the history
  • Loading branch information
honghuangdc committed May 24, 2023
1 parent 367eb63 commit aba8db1
Show file tree
Hide file tree
Showing 5 changed files with 111 additions and 86 deletions.
94 changes: 51 additions & 43 deletions bin/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,7 @@ var import_kolorist2 = require("kolorist");
// package.json
var package_default = {
name: "@soybeanjs/cli",
version: "0.1.9",
version: "0.2.0",
description: "SoybeanJS's command lint tools",
author: {
name: "Soybean",
Expand Down Expand Up @@ -303,9 +303,10 @@ var package_default = {
commit: "soy git-commit",
cleanup: "soy cleanup",
"update-pkg": "soy update-pkg",
"update-version": "bumpp package.json",
"update-version": 'bumpp package.json --execute="pnpm gen-log" --commit --all --push --tag',
"publish-pkg": "pnpm -r publish --access public",
release: "pnpm update-version && pnpm publish-pkg"
release: "pnpm update-version && pnpm publish-pkg",
"gen-log": "conventional-changelog -p angular -i CHANGELOG.md -s"
},
dependencies: {
commander: "10.0.1",
Expand All @@ -314,13 +315,15 @@ var package_default = {
kolorist: "1.8.0",
minimist: "1.2.8",
"npm-check-updates": "16.10.12",
rimraf: "5.0.0"
rimraf: "5.0.1"
},
devDependencies: {
"@soybeanjs/cli": "link:",
"@types/node": "^20.2.3",
bumpp: "9.1.0",
eslint: "8.40.0",
"eslint-config-soybeanjs": "0.3.7",
"conventional-changelog-cli": "^2.2.2",
eslint: "8.41.0",
"eslint-config-soybeanjs": "0.3.8",
"lint-staged": "13.2.2",
"simple-git-hooks": "2.8.1",
tsup: "6.7.0",
Expand Down Expand Up @@ -422,10 +425,10 @@ function verifyGitCommit() {
// src/scripts/cleanup.ts
var import_rimraf = require("rimraf");

// node_modules/.pnpm/minimatch@9.0.0/node_modules/minimatch/dist/mjs/index.js
// node_modules/.pnpm/minimatch@9.0.1/node_modules/minimatch/dist/mjs/index.js
var import_brace_expansion = __toESM(require_brace_expansion(), 1);

// node_modules/.pnpm/minimatch@9.0.0/node_modules/minimatch/dist/mjs/assert-valid-pattern.js
// node_modules/.pnpm/minimatch@9.0.1/node_modules/minimatch/dist/mjs/assert-valid-pattern.js
var MAX_PATTERN_LENGTH = 1024 * 64;
var assertValidPattern = (pattern) => {
if (typeof pattern !== "string") {
Expand All @@ -436,7 +439,7 @@ var assertValidPattern = (pattern) => {
}
};

// node_modules/.pnpm/minimatch@9.0.0/node_modules/minimatch/dist/mjs/brace-expressions.js
// node_modules/.pnpm/minimatch@9.0.1/node_modules/minimatch/dist/mjs/brace-expressions.js
var posixClasses = {
"[:alnum:]": ["\\p{L}\\p{Nl}\\p{Nd}", true],
"[:alpha:]": ["\\p{L}\\p{Nl}", true],
Expand Down Expand Up @@ -546,12 +549,12 @@ var parseClass = (glob2, position) => {
return [comb, uflag, endPos - pos, true];
};

// node_modules/.pnpm/minimatch@9.0.0/node_modules/minimatch/dist/mjs/unescape.js
// node_modules/.pnpm/minimatch@9.0.1/node_modules/minimatch/dist/mjs/unescape.js
var unescape = (s, { windowsPathsNoEscape = false } = {}) => {
return windowsPathsNoEscape ? s.replace(/\[([^\/\\])\]/g, "$1") : s.replace(/((?!\\).|^)\[([^\/\\])\]/g, "$1$2").replace(/\\([^\/])/g, "$1");
};

// node_modules/.pnpm/minimatch@9.0.0/node_modules/minimatch/dist/mjs/ast.js
// node_modules/.pnpm/minimatch@9.0.1/node_modules/minimatch/dist/mjs/ast.js
var types2 = /* @__PURE__ */ new Set(["!", "?", "+", "*", "@"]);
var isExtglobType = (c) => types2.has(c);
var startNoTraversal = "(?!\\.\\.?(?:$|/))";
Expand Down Expand Up @@ -1037,12 +1040,12 @@ parseGlob_fn = function(glob2, hasMagic2, noEmpty = false) {
__privateAdd(AST, _parseAST);
__privateAdd(AST, _parseGlob);

// node_modules/.pnpm/minimatch@9.0.0/node_modules/minimatch/dist/mjs/escape.js
// node_modules/.pnpm/minimatch@9.0.1/node_modules/minimatch/dist/mjs/escape.js
var escape = (s, { windowsPathsNoEscape = false } = {}) => {
return windowsPathsNoEscape ? s.replace(/[?*()[\]]/g, "[$&]") : s.replace(/[?*()[\]\\]/g, "\\$&");
};

// node_modules/.pnpm/minimatch@9.0.0/node_modules/minimatch/dist/mjs/index.js
// node_modules/.pnpm/minimatch@9.0.1/node_modules/minimatch/dist/mjs/index.js
var minimatch = (p, pattern, options = {}) => {
assertValidPattern(pattern);
if (!options.nocomment && pattern.charAt(0) === "#") {
Expand Down Expand Up @@ -1529,26 +1532,21 @@ var Minimatch = class {
matchOne(file, pattern, partial = false) {
const options = this.options;
if (this.isWindows) {
const fileUNC = file[0] === "" && file[1] === "" && file[2] === "?" && typeof file[3] === "string" && /^[a-z]:$/i.test(file[3]);
const patternUNC = pattern[0] === "" && pattern[1] === "" && pattern[2] === "?" && typeof pattern[3] === "string" && /^[a-z]:$/i.test(pattern[3]);
if (fileUNC && patternUNC) {
const fd = file[3];
const pd = pattern[3];
const fileDrive = typeof file[0] === "string" && /^[a-z]:$/i.test(file[0]);
const fileUNC = !fileDrive && file[0] === "" && file[1] === "" && file[2] === "?" && /^[a-z]:$/i.test(file[3]);
const patternDrive = typeof pattern[0] === "string" && /^[a-z]:$/i.test(pattern[0]);
const patternUNC = !patternDrive && pattern[0] === "" && pattern[1] === "" && pattern[2] === "?" && typeof pattern[3] === "string" && /^[a-z]:$/i.test(pattern[3]);
const fdi = fileUNC ? 3 : fileDrive ? 0 : void 0;
const pdi = patternUNC ? 3 : patternDrive ? 0 : void 0;
if (typeof fdi === "number" && typeof pdi === "number") {
const [fd, pd] = [file[fdi], pattern[pdi]];
if (fd.toLowerCase() === pd.toLowerCase()) {
file[3] = pd;
}
} else if (patternUNC && typeof file[0] === "string") {
const pd = pattern[3];
const fd = file[0];
if (pd.toLowerCase() === fd.toLowerCase()) {
pattern[3] = fd;
pattern = pattern.slice(3);
}
} else if (fileUNC && typeof pattern[0] === "string") {
const fd = file[3];
if (fd.toLowerCase() === pattern[0].toLowerCase()) {
pattern[0] = fd;
file = file.slice(3);
pattern[pdi] = fd;
if (pdi > fdi) {
pattern = pattern.slice(pdi);
} else if (fdi > pdi) {
file = file.slice(fdi);
}
}
}
}
Expand Down Expand Up @@ -2990,14 +2988,14 @@ var LRUCache = class {
}
};

// node_modules/.pnpm/path-scurry@1.8.0/node_modules/path-scurry/dist/mjs/index.js
// node_modules/.pnpm/path-scurry@1.9.2/node_modules/path-scurry/dist/mjs/index.js
var import_path = require("path");
var import_url = require("url");
var actualFS = __toESM(require("fs"), 1);
var import_fs2 = require("fs");
var import_promises = require("fs/promises");

// node_modules/.pnpm/minipass@5.0.0/node_modules/minipass/index.mjs
// node_modules/.pnpm/minipass@6.0.2/node_modules/minipass/index.mjs
var import_events = __toESM(require("events"), 1);
var import_stream = __toESM(require("stream"), 1);
var import_string_decoder = __toESM(require("string_decoder"), 1);
Expand Down Expand Up @@ -3598,7 +3596,7 @@ var Minipass = class extends import_stream.default {
}
};

// node_modules/.pnpm/path-scurry@1.8.0/node_modules/path-scurry/dist/mjs/index.js
// node_modules/.pnpm/path-scurry@1.9.2/node_modules/path-scurry/dist/mjs/index.js
var realpathSync = import_fs2.realpathSync.native;
var defaultFS = {
lstatSync: import_fs2.lstatSync,
Expand Down Expand Up @@ -3795,6 +3793,16 @@ var PathBase = class {
#children;
#linkTarget;
#realpath;
/**
* This property is for compatibility with the Dirent class as of
* Node v20, where Dirent['path'] refers to the path of the directory
* that was passed to readdir. So, somewhat counterintuitively, this
* property refers to the *parent* path, not the path object itself.
* For root entries, it's the path to the entry itself.
*/
get path() {
return (this.parent || this).fullpath();
}
/**
* Do not create new Path objects directly. They should always be accessed
* via the PathScurry class or other methods on the Path class.
Expand Down Expand Up @@ -5284,10 +5292,10 @@ var PathScurryDarwin = class extends PathScurryPosix {
var Path = process.platform === "win32" ? PathWin32 : PathPosix;
var PathScurry = process.platform === "win32" ? PathScurryWin32 : process.platform === "darwin" ? PathScurryDarwin : PathScurryPosix;

// node_modules/.pnpm/glob@10.2.3/node_modules/glob/dist/mjs/glob.js
// node_modules/.pnpm/glob@10.2.6/node_modules/glob/dist/mjs/glob.js
var import_url2 = require("url");

// node_modules/.pnpm/glob@10.2.3/node_modules/glob/dist/mjs/pattern.js
// node_modules/.pnpm/glob@10.2.6/node_modules/glob/dist/mjs/pattern.js
var isPatternList = (pl) => pl.length >= 1;
var isGlobList = (gl) => gl.length >= 1;
var Pattern = class {
Expand Down Expand Up @@ -5452,7 +5460,7 @@ var Pattern = class {
}
};

// node_modules/.pnpm/glob@10.2.3/node_modules/glob/dist/mjs/ignore.js
// node_modules/.pnpm/glob@10.2.6/node_modules/glob/dist/mjs/ignore.js
var defaultPlatform2 = typeof process === "object" && process && typeof process.platform === "string" ? process.platform : "linux";
var Ignore = class {
relative;
Expand Down Expand Up @@ -5527,7 +5535,7 @@ var Ignore = class {
}
};

// node_modules/.pnpm/glob@10.2.3/node_modules/glob/dist/mjs/processor.js
// node_modules/.pnpm/glob@10.2.6/node_modules/glob/dist/mjs/processor.js
var HasWalkedCache = class {
store;
constructor(store = /* @__PURE__ */ new Map()) {
Expand Down Expand Up @@ -5754,7 +5762,7 @@ var Processor = class {
}
};

// node_modules/.pnpm/glob@10.2.3/node_modules/glob/dist/mjs/walker.js
// node_modules/.pnpm/glob@10.2.6/node_modules/glob/dist/mjs/walker.js
var makeIgnore = (ignore, opts) => typeof ignore === "string" ? new Ignore([ignore], opts) : Array.isArray(ignore) ? new Ignore(ignore, opts) : ignore;
var GlobUtil = class {
path;
Expand Down Expand Up @@ -6058,7 +6066,7 @@ var GlobStream = class extends GlobUtil {
}
};

// node_modules/.pnpm/glob@10.2.3/node_modules/glob/dist/mjs/glob.js
// node_modules/.pnpm/glob@10.2.6/node_modules/glob/dist/mjs/glob.js
var defaultPlatform3 = typeof process === "object" && process && typeof process.platform === "string" ? process.platform : "linux";
var Glob = class {
absolute;
Expand Down Expand Up @@ -6247,7 +6255,7 @@ var Glob = class {
}
};

// node_modules/.pnpm/glob@10.2.3/node_modules/glob/dist/mjs/has-magic.js
// node_modules/.pnpm/glob@10.2.6/node_modules/glob/dist/mjs/has-magic.js
var hasMagic = (pattern, options = {}) => {
if (!Array.isArray(pattern)) {
pattern = [pattern];
Expand All @@ -6259,7 +6267,7 @@ var hasMagic = (pattern, options = {}) => {
return false;
};

// node_modules/.pnpm/glob@10.2.3/node_modules/glob/dist/mjs/index.js
// node_modules/.pnpm/glob@10.2.6/node_modules/glob/dist/mjs/index.js
function globStreamSync(pattern, options = {}) {
return new Glob(pattern, options).streamSync();
}
Expand Down
Loading

0 comments on commit aba8db1

Please sign in to comment.