@dylanpiercey/work 0.0.1 → 0.0.2
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.
- package/bin/work.mjs +3 -1
- package/install.sh +12 -1
- package/package.json +5 -1
package/bin/work.mjs
CHANGED
|
@@ -83,7 +83,9 @@ async function setup() {
|
|
|
83
83
|
"bottom",
|
|
84
84
|
"pnpm",
|
|
85
85
|
];
|
|
86
|
-
|
|
86
|
+
// Note: ast-grep's short alias `sg` collides with the coreutils
|
|
87
|
+
// setgroups command — check the long binary name.
|
|
88
|
+
const binOf = { ripgrep: "rg", bottom: "btm" };
|
|
87
89
|
for (const tool of tools) {
|
|
88
90
|
if (have(binOf[tool] || tool)) continue;
|
|
89
91
|
log(`installing ${tool} via mise`);
|
package/install.sh
CHANGED
|
@@ -18,6 +18,11 @@ log() { printf '==> %s\n' "$*"; }
|
|
|
18
18
|
die() { printf 'error: %s\n' "$*" >&2; exit 1; }
|
|
19
19
|
have() { command -v "$1" >/dev/null 2>&1; }
|
|
20
20
|
|
|
21
|
+
# Everything runs inside main() so bash parses the whole script before
|
|
22
|
+
# executing anything — when piped from curl, commands that read stdin
|
|
23
|
+
# (apt-get, installers) would otherwise swallow the rest of the script.
|
|
24
|
+
main() {
|
|
25
|
+
|
|
21
26
|
PKG="${WORK_PKG:-@dylanpiercey/work@latest}"
|
|
22
27
|
SUDO=""
|
|
23
28
|
if [[ "$(id -u)" != 0 ]]; then
|
|
@@ -100,5 +105,11 @@ log "running work setup"
|
|
|
100
105
|
if [[ "${WORK_YES:-0}" == 1 ]]; then
|
|
101
106
|
work setup --yes
|
|
102
107
|
else
|
|
103
|
-
|
|
108
|
+
# Reattach the terminal for interactive prompts (gh auth) — stdin is
|
|
109
|
+
# the script itself under `curl | bash`.
|
|
110
|
+
work setup </dev/tty || work setup --yes
|
|
104
111
|
fi
|
|
112
|
+
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
main "$@"
|
package/package.json
CHANGED
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dylanpiercey/work",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Web GUI for agentic dev workspaces",
|
|
6
6
|
"license": "MIT",
|
|
7
|
+
"repository": {
|
|
8
|
+
"type": "git",
|
|
9
|
+
"url": "git+https://github.com/DylanPiercey/work.git"
|
|
10
|
+
},
|
|
7
11
|
"bin": {
|
|
8
12
|
"work": "bin/work.mjs"
|
|
9
13
|
},
|