⚙️ Update script metadata and add command aliases in commit.ts

This commit is contained in:
2026-04-12 10:31:53 +08:00
parent 38b6f22145
commit cf27d7657d
2 changed files with 11 additions and 6 deletions

View File

@@ -63,12 +63,12 @@
},
"commit.ts": {
"script_name": "commit.ts",
"script_length": 3718,
"script_sha256": "5acf15ef8b809dc87ff38e4498467c40199eaf344bd1a37ce99c1b3dba38521e",
"script_length": 3837,
"script_sha256": "b40a5ba431e499e98cf812cdc997aedcdfb2daedfc4d304fa64461a15c94f4d8",
"script_full_url": "https://git.hatter.ink/hatter/ts-scripts/raw/branch/main/single-scripts/commit.ts",
"single_script_file": true,
"publish_time": 1769318306585,
"update_time": 1775960755579
"update_time": 1775961111350
},
"decode-uri-component.ts": {
"script_name": "decode-uri-component.ts",

View File

@@ -22,6 +22,11 @@ async function checkRev(): Promise<boolean> {
async function main() {
const flags = parseArgs(Deno.args, {
boolean: ["help", "check-only", "auto-commit"],
alias: {
H: "help",
C: "check-only",
A: "auto-commit",
},
});
const checkOnly = flags["check-only"];
const autoCommit = flags["auto-commit"];
@@ -29,9 +34,9 @@ async function main() {
if (flags.help) {
console.log(`commit.ts
commit.ts [--help] - show help message
commit.ts [--check-only] - check rev and status only
commit.ts [--auto-commit] - auto commit with AI summarize
commit.ts [-H|--help] - show help message
commit.ts [-C|--check-only] - check rev and status only
commit.ts [-A|--auto-commit] - auto commit with AI summarize
`);
return;
}