From 9f902d714527d42b8ba2ba7f99511a5d403d2728 Mon Sep 17 00:00:00 2001 From: Kattouf Date: Mon, 8 Jul 2024 12:34:37 +0700 Subject: [PATCH 1/3] feat: add progressline completion spec --- src/progressline.ts | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 src/progressline.ts diff --git a/src/progressline.ts b/src/progressline.ts new file mode 100644 index 000000000000..81c6950d1855 --- /dev/null +++ b/src/progressline.ts @@ -0,0 +1,41 @@ +const completionSpec: Fig.Spec = { + name: "progressline", + description: "⏳Track commands progress in a compact one-line format", + + options: [ + { + name: ["--help", "-h"], + description: "Show help for progressline", + }, + { + name: ["--log-all", "-a"], + description: "Log all lines above the progress line", + }, + { + name: ["--activity-style", "-s"], + args: { + name: "style", + default: "dots", + suggestions: ["dots", "kitt", "snake"], + }, + description: "Set style of the activity indicator", + }, + { + name: ["--original-log-path", "-l"], + description: "Save the original log to a file", + args: { + name: "path", + template: "filepaths", + }, + }, + { + name: ["--log-matches", "-m"], + description: + "Log above progress line lines matching the given regular expressions", + args: { + name: "regex", + }, + }, + ], +}; +export default completionSpec; From f45ae416f441aeb6a9820bdcecb4fd7244b433b0 Mon Sep 17 00:00:00 2001 From: Kattouf Date: Sat, 7 Sep 2024 07:31:01 +0700 Subject: [PATCH 2/3] add info about --static-text feature --- src/progressline.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/progressline.ts b/src/progressline.ts index 81c6950d1855..52f018d0668d 100644 --- a/src/progressline.ts +++ b/src/progressline.ts @@ -11,6 +11,13 @@ const completionSpec: Fig.Spec = { name: ["--log-all", "-a"], description: "Log all lines above the progress line", }, + { + name: ["--static-text", "-t"], + description: "Set static text to display instead of the latest stdin data", + args: { + name: "text", + }, + }, { name: ["--activity-style", "-s"], args: { From b164d6b9a84fbd898cc27dc573be19d7add9752b Mon Sep 17 00:00:00 2001 From: Kattouf Date: Sat, 7 Sep 2024 07:36:03 +0700 Subject: [PATCH 3/3] fix lint violation --- src/progressline.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/progressline.ts b/src/progressline.ts index 52f018d0668d..db1fa9db9006 100644 --- a/src/progressline.ts +++ b/src/progressline.ts @@ -13,7 +13,8 @@ const completionSpec: Fig.Spec = { }, { name: ["--static-text", "-t"], - description: "Set static text to display instead of the latest stdin data", + description: + "Set static text to display instead of the latest stdin data", args: { name: "text", },