Run manpage and completions in release when we've already built in releases

This commit is contained in:
Félix Saparelli 2024-04-21 01:57:09 +12:00
parent 62af5dd868
commit 0ef87821f2
No known key found for this signature in database
2 changed files with 10 additions and 15 deletions

View File

@ -196,19 +196,14 @@ jobs:
with:
tool: cross
- name: Build (cargo)
if: "!matrix.cross"
run: cargo build --package watchexec-cli --release --locked --target ${{ matrix.target }}
- name: Build (cross)
if: matrix.cross
run: cross build --package watchexec-cli --release --locked --target ${{ matrix.target }}
- name: Build
run: ${{ matrix.cross && 'cross' || 'cargo' }} build --package watchexec-cli --release --locked --target ${{ matrix.target }}
- name: Make manpage
run: cargo run -p watchexec-cli -- --manual > doc/watchexec.1
run: cargo run -p watchexec-cli ${{ matrix.cross && '' || '--release' }} -- --manual > doc/watchexec.1
- name: Make completions
run: bin/completions
run: bin/completions ${{ matrix.cross && '' || '--release' }}
- name: Package
shell: bash

View File

@ -1,7 +1,7 @@
#!/bin/sh
cargo run -p watchexec-cli -- --completions bash > completions/bash
cargo run -p watchexec-cli -- --completions elvish > completions/elvish
cargo run -p watchexec-cli -- --completions fish > completions/fish
cargo run -p watchexec-cli -- --completions nu > completions/nu
cargo run -p watchexec-cli -- --completions powershell > completions/powershell
cargo run -p watchexec-cli -- --completions zsh > completions/zsh
cargo run -p watchexec-cli $* -- --completions bash > completions/bash
cargo run -p watchexec-cli $* -- --completions elvish > completions/elvish
cargo run -p watchexec-cli $* -- --completions fish > completions/fish
cargo run -p watchexec-cli $* -- --completions nu > completions/nu
cargo run -p watchexec-cli $* -- --completions powershell > completions/powershell
cargo run -p watchexec-cli $* -- --completions zsh > completions/zsh