@weezy20/zv 0.1.2 → 0.3.0

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/README.md CHANGED
@@ -22,7 +22,35 @@ It also doubles as a project template starter, providing multiple variants of a
22
22
 
23
23
  ## Installation
24
24
 
25
- **Step 1:** Install the binary from crates.io or GitHub
25
+
26
+ **Quick install script (Recommended):**
27
+
28
+ Linux/macOS:
29
+ ```sh
30
+ curl --proto '=https' --tlsv1.2 -LsSf https://github.com/weezy20/zv/releases/latest/download/zv-installer.sh | sh
31
+ ```
32
+
33
+ Windows (PowerShell):
34
+ ```powershell
35
+ irm https://github.com/weezy20/zv/releases/latest/download/zv-installer.ps1 | iex
36
+ ```
37
+
38
+ **HomeBrew:**
39
+ ```sh
40
+ brew install weezy20/tap/zv
41
+ ```
42
+
43
+ **NPM:**
44
+ ```sh
45
+ npm install -g @weezy20/zv
46
+ ```
47
+
48
+ <details>
49
+ <summary><b>Cargo (crates.io or build from source)</b></summary>
50
+
51
+ **Step 1:** Install the binary from crates.io or build from source
52
+
53
+ Using `cargo install`:
26
54
  ```sh
27
55
  # From crates.io
28
56
  cargo install zv
@@ -31,34 +59,88 @@ cargo install zv
31
59
  cargo install --git https://github.com/weezy20/zv --locked
32
60
  ```
33
61
 
62
+ Or build from source (clone the repo first):
63
+ ```sh
64
+ # Build release binary (creates target/release/zv)
65
+ cargo build --release
66
+ ```
67
+
34
68
  **Step 2:** Preview setup changes (optional but recommended)
69
+
70
+ Using `cargo installed binary`:
35
71
  ```sh
36
72
  $HOME/.cargo/bin/zv setup --dry-run
37
73
  # OR shorthand:
38
74
  $HOME/.cargo/bin/zv setup -d
39
75
  ```
40
76
 
77
+ Or from source:
78
+ ```sh
79
+ cargo run --release -- setup --dry-run
80
+ # OR shorthand:
81
+ cargo run --release -- setup -d
82
+ ```
83
+
41
84
  **Step 3:** Run setup to install `zv` to `ZV_DIR/bin` and configure your shell
85
+
86
+ Using `cargo installed binary`:
42
87
  ```sh
43
88
  $HOME/.cargo/bin/zv setup
44
89
  ```
90
+
91
+ Or from source:
92
+ ```sh
93
+ cargo run --release -- setup
94
+ # or if you already have ZV_DIR/bin in path
95
+ cargo run --release -- sync
96
+ ```
97
+
45
98
  This self-installs `zv` to `ZV_DIR/bin` (default: `$HOME/.zv/bin` on Unix, `%USERPROFILE%\.zv\bin` on Windows) and adds it to your PATH.
46
99
 
47
- **Step 4:** Remove the cargo binary (optional cleanup)
100
+ **Step 4:** Remove the cargo binary (optional cleanup - only if you used `cargo install`)
48
101
  ```sh
49
102
  cargo uninstall zv
50
103
  ```
104
+
51
105
  From now on, use the `zv` installed in `ZV_DIR/bin`.
52
106
 
107
+ </details>
108
+
109
+ ---
110
+
111
+ > **Note:** The quick install scripts (shell/PowerShell), Homebrew, and npm all install `zv` directly to `ZV_DIR/bin` (default: `$HOME/.zv/bin` on Unix, `%USERPROFILE%\.zv\bin` on Windows) and configure your PATH automatically. You're ready to go! If you installed via cargo, see the instructions above for running `zv setup` or `zv sync`.
53
112
 
54
- ## Updating `zv`
113
+ ## Updating `zv`
55
114
 
56
- Repeat the installation steps above, or if you have the repo cloned:
115
+ **Simple update (Recommended):**
57
116
  ```sh
58
- # Update from your local clone
59
- cargo run --release -- setup
117
+ zv update
118
+ ```
119
+
120
+ This command checks for new releases on GitHub and updates `zv` in place. It works whether you're running from `ZV_DIR/bin/zv` or from an external location (like cargo install).
121
+
122
+ **Options:**
123
+ ```sh
124
+ zv update --force # Force reinstall even if already on the latest version
125
+ ```
126
+
127
+
128
+
129
+ <details>
130
+ <summary>Alternative update methods:</summary>
131
+
132
+ If you have the repo cloned or are using a cargo-installed binary:
133
+ ```sh
134
+ # Build new version and update the binary in ZV_DIR/bin
135
+ cargo run --release -- sync
136
+
137
+ # Or if you installed from crates.io, install it and sync
138
+ cargo install zv --force
139
+ zv sync
140
+ # or if you already have ZV_DIR/bin in path
141
+ ~/.cargo/bin/zv sync # $CARGO_HOME/bin/zv sync
60
142
  ```
61
- This replaces your existing `ZV_DIR/bin/zv` installation.
143
+ </details>
62
144
 
63
145
  ## Usage
64
146
 
@@ -104,7 +186,8 @@ zv clean --except <version,*> # Clean up every version except the versi
104
186
  zv rm master # Clean up the `master` branch toolchain.
105
187
  zv rm master --outdated # Clean up any older master versions in the master folder that don't match latest `master`
106
188
  zv setup # Set up shell environment for zv with interactive prompts (use --no-interactive for automation)
107
- zv sync # Resync community mirrors list from [ziglang.org/download/community-mirrors.txt]; also force resync of index to fetch latest nightly builds.
189
+ zv sync # Resync community mirrors list from [ziglang.org/download/community-mirrors.txt]; also force resync of index to fetch latest nightly builds. Replaces `ZV_DIR/bin/zv` if outdated against current invocation.
190
+ zv update # Update zv to the latest release only if present in GH Releases: https://github.com/weezy20/zv/releases
108
191
  zv help # Detailed instructions for zv. Use `--help` for long help or `-h` for short help with a subcommand.
109
192
  ```
110
193
 
@@ -23,7 +23,7 @@
23
23
  "hasInstallScript": true,
24
24
  "license": "MIT",
25
25
  "name": "@weezy20/zv",
26
- "version": "0.1.2"
26
+ "version": "0.3.0"
27
27
  },
28
28
  "node_modules/@isaacs/balanced-match": {
29
29
  "engines": {
@@ -896,5 +896,5 @@
896
896
  }
897
897
  },
898
898
  "requires": true,
899
- "version": "0.1.2"
899
+ "version": "0.3.0"
900
900
  }
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "artifactDownloadUrl": "https://github.com/weezy20/zv/releases/download/v0.1.2",
2
+ "artifactDownloadUrl": "https://github.com/weezy20/zv/releases/download/v0.3.0",
3
3
  "author": "Abhishek Shah <abhishekshah3@gmail.com>",
4
4
  "bin": {
5
5
  "zv": "run-zv.js"
@@ -42,11 +42,11 @@
42
42
  },
43
43
  "supportedPlatforms": {
44
44
  "aarch64-apple-darwin": {
45
- "artifactName": "zv-aarch64-apple-darwin.tar.xz",
45
+ "artifactName": "zv-aarch64-apple-darwin.tar.gz",
46
46
  "bins": {
47
47
  "zv": "zv"
48
48
  },
49
- "zipExt": ".tar.xz"
49
+ "zipExt": ".tar.gz"
50
50
  },
51
51
  "aarch64-pc-windows-msvc": {
52
52
  "artifactName": "zv-x86_64-pc-windows-msvc.zip",
@@ -56,18 +56,18 @@
56
56
  "zipExt": ".zip"
57
57
  },
58
58
  "aarch64-unknown-linux-gnu": {
59
- "artifactName": "zv-aarch64-unknown-linux-gnu.tar.xz",
59
+ "artifactName": "zv-aarch64-unknown-linux-gnu.tar.gz",
60
60
  "bins": {
61
61
  "zv": "zv"
62
62
  },
63
- "zipExt": ".tar.xz"
63
+ "zipExt": ".tar.gz"
64
64
  },
65
65
  "x86_64-apple-darwin": {
66
- "artifactName": "zv-x86_64-apple-darwin.tar.xz",
66
+ "artifactName": "zv-x86_64-apple-darwin.tar.gz",
67
67
  "bins": {
68
68
  "zv": "zv"
69
69
  },
70
- "zipExt": ".tar.xz"
70
+ "zipExt": ".tar.gz"
71
71
  },
72
72
  "x86_64-pc-windows-gnu": {
73
73
  "artifactName": "zv-x86_64-pc-windows-msvc.zip",
@@ -84,14 +84,28 @@
84
84
  "zipExt": ".zip"
85
85
  },
86
86
  "x86_64-unknown-linux-gnu": {
87
- "artifactName": "zv-x86_64-unknown-linux-gnu.tar.xz",
87
+ "artifactName": "zv-x86_64-unknown-linux-gnu.tar.gz",
88
88
  "bins": {
89
89
  "zv": "zv"
90
90
  },
91
- "zipExt": ".tar.xz"
91
+ "zipExt": ".tar.gz"
92
+ },
93
+ "x86_64-unknown-linux-musl-dynamic": {
94
+ "artifactName": "zv-x86_64-unknown-linux-musl.tar.gz",
95
+ "bins": {
96
+ "zv": "zv"
97
+ },
98
+ "zipExt": ".tar.gz"
99
+ },
100
+ "x86_64-unknown-linux-musl-static": {
101
+ "artifactName": "zv-x86_64-unknown-linux-musl.tar.gz",
102
+ "bins": {
103
+ "zv": "zv"
104
+ },
105
+ "zipExt": ".tar.gz"
92
106
  }
93
107
  },
94
- "version": "0.1.2",
108
+ "version": "0.3.0",
95
109
  "volta": {
96
110
  "node": "18.14.1",
97
111
  "npm": "9.5.0"