Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
67 changes: 34 additions & 33 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,31 +120,50 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-24.04
- ubuntu-24.04-arm
- windows-latest
- windows-11-arm
- macos-15-intel # x86
- macos-latest # arm64
include:
- os: ubuntu-24.04
asset: sysand-linux-x86_64
ext: tar.xz
- os: ubuntu-24.04-arm
asset: sysand-linux-arm64
ext: tar.xz
- os: windows-latest
asset: sysand-windows-x86_64
ext: zip
- os: windows-11-arm
asset: sysand-windows-arm64
ext: zip
- os: macos-15-intel
asset: sysand-macos-x86_64
ext: tar.xz
- os: macos-latest
asset: sysand-macos-arm64
ext: tar.xz
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1

- name: cargo build ...
run: cargo build --locked --bin sysand --release

- name: Relocate binaries
- name: Package binary (unix)
if: runner.os != 'Windows'
run: |
mkdir -p dist
ext=${{ (matrix.os == 'windows-latest' || matrix.os == 'windows-11-arm') && '.exe' || '' }}
cp target/release/sysand${ext} dist/sysand-${{ matrix.os }}${ext}
mkdir dist
tar -cJf "dist/${{ matrix.asset }}.tar.xz" -C target/release sysand

- name: Package binary (windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
mkdir dist
Compress-Archive -DestinationPath "dist\${{ matrix.asset }}.zip" -Path target\release\sysand.exe

- name: Upload binaries
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7
with:
name: sysand-cli-${{ matrix.os }}
path: dist
name: ${{ matrix.asset }}
path: dist/${{ matrix.asset }}.${{ matrix.ext }}
if-no-files-found: error

ci-gate:
Expand Down Expand Up @@ -180,23 +199,14 @@ jobs:
with:
subject-path: "artifacts/*"

- name: Rename artifacts
run: |
mv artifacts/sysand-ubuntu-24.04 artifacts/sysand-linux-x86_64
mv artifacts/sysand-ubuntu-24.04-arm artifacts/sysand-linux-arm64
mv artifacts/sysand-windows-latest.exe artifacts/sysand-windows-x86_64.exe
mv artifacts/sysand-windows-11-arm.exe artifacts/sysand-windows-arm64.exe
mv artifacts/sysand-macos-15-intel artifacts/sysand-macos-x86_64
mv artifacts/sysand-macos-latest artifacts/sysand-macos-arm64

- name: Create a nightly release
run: |
NEW_TAG=$(date +v-%Y-%m-%d-%H%M)
gh release create "$NEW_TAG" \
--title "Nightly Release $NEW_TAG" \
--prerelease \
--target "$GITHUB_SHA" \
artifacts/*
artifacts/sysand-*.tar.xz artifacts/sysand-*.zip
env:
GH_TOKEN: ${{ github.token }}
GH_REPO: ${{ github.repository }}
Expand All @@ -223,21 +233,12 @@ jobs:
with:
subject-path: "artifacts/*"

- name: Rename artifacts
run: |
mv artifacts/sysand-ubuntu-24.04 artifacts/sysand-linux-x86_64
mv artifacts/sysand-ubuntu-24.04-arm artifacts/sysand-linux-arm64
mv artifacts/sysand-windows-latest.exe artifacts/sysand-windows-x86_64.exe
mv artifacts/sysand-windows-11-arm.exe artifacts/sysand-windows-arm64.exe
mv artifacts/sysand-macos-15-intel artifacts/sysand-macos-x86_64
mv artifacts/sysand-macos-latest artifacts/sysand-macos-arm64

- name: Create a release
run: |
gh release create "$TRIGGERING_TAG" \
--title "Release $TRIGGERING_TAG" \
--verify-tag \
artifacts/*
artifacts/sysand-*.tar.xz artifacts/sysand-*.zip
env:
GH_TOKEN: ${{ github.token }}
GH_REPO: ${{ github.repository }}
Expand Down
61 changes: 34 additions & 27 deletions docs/src/getting_started/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,19 +59,23 @@ or from [latest GitHub release][gh_rel].
</tr>
<tr>
<td><strong>x86_x64</strong></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-windows-x86_64.exe"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-macos-x86_64"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-linux-x86_64"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-windows-x86_64.zip"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-macos-x86_64.tar.xz"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-linux-x86_64.tar.xz"><button><i class="fas fa-download"></i> Download</button></a></td>
</tr>
<tr>
<td><strong>ARM64</strong></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-windows-arm64.exe"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-macos-arm64"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-linux-arm64"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-windows-arm64.zip"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-macos-arm64.tar.xz"><button><i class="fas fa-download"></i> Download</button></a></td>
<td><a href="https://github.com/sensmetry/sysand/releases/latest/download/sysand-linux-arm64.tar.xz"><button><i class="fas fa-download"></i> Download</button></a></td>
</tr>
</table>
<!-- markdownlint-enable MD033 MD013 -->
After downloading the appropriate file, installation depends on your platform:

The download is an archive (`.zip` on Windows, `.tar.xz` on macOS and
Linux) containing a single `sysand` executable (`sysand.exe` on
Windows). After downloading, extract the archive and follow the steps
for your platform:

- [Windows (both x86_64 and ARM64)](#windows)
- [macOS (both Intel and ARM64 (a.k.a. Apple Silicon))](#macos)
Expand All @@ -81,13 +85,14 @@ It is recommended to then [verify the installation](#verify-the-installation).

### Windows

The downloaded binary can either be installed manually or by running
a few PowerShell commands.
The downloaded `.zip` archive contains `sysand.exe`. It can either be
installed manually or by running a few PowerShell commands.

#### Manual installation

1. Move the downloaded `.exe` file to `%LOCALAPPDATA%\Programs\Sysand\sysand.exe`
2. Add to `PATH` via Environment Variables:
1. Right-click the downloaded `.zip` file and choose "Extract All..."
2. Move the extracted `sysand.exe` to `%LOCALAPPDATA%\Programs\Sysand\sysand.exe`
3. Add to `PATH` via Environment Variables:
1. Open "Environment Variables" (search in Start menu)
2. Under "User variables", select "Path" and click "Edit"
3. Click "New" and add `%LOCALAPPDATA%\Programs\Sysand`
Expand All @@ -101,15 +106,17 @@ a few PowerShell commands.
```powershell
# For x86_64 systems

# Create directory and move to it
# Create directory and extract the archive into it
mkdir "$env:LOCALAPPDATA\Programs\Sysand" -Force
mv sysand-windows-x86_64.exe "$env:LOCALAPPDATA\Programs\Sysand\sysand.exe"
Expand-Archive -Path sysand-windows-x86_64.zip `
-DestinationPath "$env:LOCALAPPDATA\Programs\Sysand" -Force

# For ARM64 systems

# Create directory and move to it
# Create directory and extract the archive into it
mkdir "$env:LOCALAPPDATA\Programs\Sysand" -Force
mv sysand-windows-arm64.exe "$env:LOCALAPPDATA\Programs\Sysand\sysand.exe"
Expand-Archive -Path sysand-windows-arm64.zip `
-DestinationPath "$env:LOCALAPPDATA\Programs\Sysand" -Force
```

3. Add folder to `PATH`:
Expand All @@ -131,17 +138,17 @@ if ($currentPath -notlike "*$newPath*") {
#### System installation (requires `sudo`)

1. Open Terminal
2. Make the binary executable and move to a folder in `PATH` by running the
following commands:
2. Extract the archive and move the `sysand` binary to a folder in
`PATH` by running the following commands:

```sh
# For Intel Macs
chmod +x ~/Downloads/sysand-macos-x86_64
sudo mv ~/Downloads/sysand-macos-x86_64 /usr/local/bin/sysand
tar -xJf ~/Downloads/sysand-macos-x86_64.tar.xz -C ~/Downloads
sudo mv ~/Downloads/sysand /usr/local/bin/sysand

# For Apple Silicon Macs
chmod +x ~/Downloads/sysand-macos-arm64
sudo mv ~/Downloads/sysand-macos-arm64 /usr/local/bin/sysand
tar -xJf ~/Downloads/sysand-macos-arm64.tar.xz -C ~/Downloads
sudo mv ~/Downloads/sysand /usr/local/bin/sysand
```

#### Alternative: user installation (no `sudo` required)
Expand Down Expand Up @@ -169,17 +176,17 @@ source ~/.zshrc
#### System installation (requires `sudo`)

1. Open a terminal
2. Make the binary executable and move to a folder in `PATH` by running the
following commands:
2. Extract the archive and move the `sysand` binary to a folder in
`PATH` by running the following commands:

```sh
# For x86_64 systems
chmod +x sysand-linux-x86_64
sudo mv sysand-linux-x86_64 /usr/local/bin/sysand
tar -xJf sysand-linux-x86_64.tar.xz
sudo mv sysand /usr/local/bin/sysand

# For ARM64 systems
chmod +x sysand-linux-arm64
sudo mv sysand-linux-arm64 /usr/local/bin/sysand
tar -xJf sysand-linux-arm64.tar.xz
sudo mv sysand /usr/local/bin/sysand
```

#### Alternative: user installation (no `sudo` required)
Expand Down
Loading