@vellumai/cli 0.1.9 → 0.1.11

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vellumai/cli",
3
- "version": "0.1.9",
3
+ "version": "0.1.11",
4
4
  "description": "CLI tools for vellum-assistant",
5
5
  "type": "module",
6
6
  "bin": {
@@ -79,6 +79,23 @@ ensure_bun() {
79
79
  success "bun installed ($(bun --version))"
80
80
  }
81
81
 
82
+ install_vellum() {
83
+ if command -v vellum >/dev/null 2>&1; then
84
+ info "Updating vellum to latest..."
85
+ bun install -g vellum@latest
86
+ else
87
+ info "Installing vellum globally..."
88
+ bun install -g vellum@latest
89
+ fi
90
+
91
+ if ! command -v vellum >/dev/null 2>&1; then
92
+ error "vellum installation failed. Please install manually: bun install -g vellum"
93
+ exit 1
94
+ fi
95
+
96
+ success "vellum installed ($(vellum --version 2>/dev/null || echo 'unknown'))"
97
+ }
98
+
82
99
  main() {
83
100
  printf "\n"
84
101
  printf ' %bVellum Installer%b\n' "$BOLD" "$RESET"
@@ -86,13 +103,14 @@ main() {
86
103
 
87
104
  ensure_git
88
105
  ensure_bun
106
+ install_vellum
89
107
 
90
108
  info "Running vellum hatch..."
91
109
  printf "\n"
92
110
  if [ -n "${VELLUM_SSH_USER:-}" ] && [ "$(id -u)" = "0" ]; then
93
- su - "$VELLUM_SSH_USER" -c "set -a; [ -f \"\$HOME/.vellum/.env\" ] && . \"\$HOME/.vellum/.env\"; set +a; export PATH=\"$HOME/.bun/bin:\$PATH\"; bunx vellum hatch"
111
+ su - "$VELLUM_SSH_USER" -c "set -a; [ -f \"\$HOME/.vellum/.env\" ] && . \"\$HOME/.vellum/.env\"; set +a; export PATH=\"$HOME/.bun/bin:\$PATH\"; vellum hatch"
94
112
  else
95
- bunx vellum hatch
113
+ vellum hatch
96
114
  fi
97
115
  }
98
116