Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion npmDepsHash
Original file line number Diff line number Diff line change
@@ -1 +1 @@
sha256-/SFcicpWX1SFllzmz0acUYxtIV0LuBw1PU32Uk5hLzw=
sha256-q99IFZwwPBR/p2m18c5DOApks12rB779c8rUW160k3g=
163 changes: 143 additions & 20 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@
"sodium-native": "*"
},
"devDependencies": {
"@apidevtools/json-schema-ref-parser": "^11.9.3",
"@fast-check/jest": "^2.1.1",
"@matrixai/errors": "^2.1.3",
"@matrixai/exec": "^1.0.3",
Expand All @@ -149,6 +150,8 @@
"@typescript-eslint/eslint-plugin": "^5.61.0",
"@typescript-eslint/parser": "^5.61.0",
"@yao-pkg/pkg": "^6.4.0",
"ajv": "^8.17.1",
"ajv-formats": "^3.0.1",
"commander": "^8.3.0",
"cross-env": "^7.0.3",
"esbuild": "0.19.4",
Expand All @@ -162,7 +165,7 @@
"nexpect": "^0.6.0",
"node-gyp-build": "^4.8.4",
"open": "^10.1.2",
"polykey": "^2.5.0",
"polykey": "^2.6.0",
"shelljs": "^0.8.5",
"shx": "^0.3.4",
"tsx": "^3.12.7",
Expand Down
14 changes: 13 additions & 1 deletion src/errors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,11 @@ class ErrorPolykeyCLIDuplicateEnvName<T> extends ErrorPolykeyCLI<T> {
exitCode = sysexits.USAGE;
}

class ErrorPolykeyCLIMissingRequiredEnvName<T> extends ErrorPolykeyCLI<T> {
static description = 'A required environment variable is not present';
exitCode = sysexits.USAGE;
}

class ErrorPolykeyCLIMakeDirectory<T> extends ErrorPolykeyCLI<T> {
static description = 'Failed to create one or more directories';
exitCode = 1;
Expand Down Expand Up @@ -197,10 +202,15 @@ class ErrorPolykeyCLITouchSecret<T> extends ErrorPolykeyCLI<T> {
}

class ErrorPolykeyCLIInvalidJWT<T> extends ErrorPolykeyCLI<T> {
static description: 'JWT is not valid';
static description = 'JWT is not valid';
exitCode = sysexits.USAGE;
}

class ErrorPolykeyCLISchemaInvalid<T> extends ErrorPolykeyCLI<T> {
static description = 'The provided JSON schema is invalid';
exitCode = sysexits.CONFIG;
}

export {
ErrorPolykeyCLI,
ErrorPolykeyCLIUncaughtException,
Expand All @@ -223,11 +233,13 @@ export {
ErrorPolykeyCLINodePingFailed,
ErrorPolykeyCLIInvalidEnvName,
ErrorPolykeyCLIDuplicateEnvName,
ErrorPolykeyCLIMissingRequiredEnvName,
ErrorPolykeyCLIMakeDirectory,
ErrorPolykeyCLIRenameSecret,
ErrorPolykeyCLIRemoveSecret,
ErrorPolykeyCLICatSecret,
ErrorPolykeyCLIEditSecret,
ErrorPolykeyCLITouchSecret,
ErrorPolykeyCLIInvalidJWT,
ErrorPolykeyCLISchemaInvalid,
};
Loading