Move to GHA to stable Rust

This commit is contained in:
Demmie 2024-06-24 01:06:31 -04:00
parent 123a0e45ff
commit e1d5071869
No known key found for this signature in database
GPG Key ID: B06DAA3D432C6E9A
3 changed files with 8 additions and 14 deletions

View File

@ -15,9 +15,7 @@ jobs:
AW_WEBUI_DIR: ${{ github.workspace }}/aw-webui/dist AW_WEBUI_DIR: ${{ github.workspace }}/aw-webui/dist
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master - uses: dtolnay/rust-toolchain@stable
with:
toolchain: nightly-2023-11-01
- name: Install dependencies - name: Install dependencies
run: | run: |
sudo apt-get update sudo apt-get update

View File

@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly - uses: dtolnay/rust-toolchain@stable
with: with:
components: rustfmt components: rustfmt
- run: cargo fmt --check --all - run: cargo fmt --check --all
@ -24,9 +24,8 @@ jobs:
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- run: sudo apt-get install -y libdbus-1-dev - run: sudo apt-get install -y libdbus-1-dev
- uses: dtolnay/rust-toolchain@master - uses: dtolnay/rust-toolchain@stable
with: with:
toolchain: nightly-2023-11-01
components: clippy components: clippy
- uses: Swatinem/rust-cache@v2 - uses: Swatinem/rust-cache@v2
- run: cargo clippy --locked --all-targets --all-features --workspace -- -D warnings - run: cargo clippy --locked --all-targets --all-features --workspace -- -D warnings
@ -37,9 +36,8 @@ jobs:
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- run: sudo apt-get install -y libdbus-1-dev - run: sudo apt-get install -y libdbus-1-dev
- uses: dtolnay/rust-toolchain@master - uses: dtolnay/rust-toolchain@stable
with: with:
toolchain: stable
components: clippy components: clippy
- uses: Swatinem/rust-cache@v2 - uses: Swatinem/rust-cache@v2
- run: cargo clippy --locked --all-targets --workspace -- -D warnings - run: cargo clippy --locked --all-targets --workspace -- -D warnings
@ -50,9 +48,6 @@ jobs:
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- run: sudo apt-get install -y libdbus-1-dev - run: sudo apt-get install -y libdbus-1-dev
- uses: dtolnay/rust-toolchain@master - uses: dtolnay/rust-toolchain@stable
with:
toolchain: nightly-2023-11-01
components: clippy
- uses: Swatinem/rust-cache@v2 - uses: Swatinem/rust-cache@v2
- run: cargo test --all-features --workspace - run: cargo test --all-features --workspace

View File

@ -11,7 +11,9 @@ use watchers::config::FileConfig;
pub struct RunnerConfig { pub struct RunnerConfig {
pub watchers_config: Config, pub watchers_config: Config,
#[cfg(feature = "bundle")]
pub config_file: PathBuf, pub config_file: PathBuf,
#[cfg(feature = "bundle")]
pub no_tray: bool, pub no_tray: bool,
} }
@ -100,11 +102,10 @@ pub fn from_cli() -> anyhow::Result<RunnerConfig> {
filters: config.client.filters, filters: config.client.filters,
no_server: *matches.get_one("no-server").unwrap(), no_server: *matches.get_one("no-server").unwrap(),
}, },
#[cfg(feature = "bundle")]
config_file: config.config_file, config_file: config.config_file,
#[cfg(feature = "bundle")] #[cfg(feature = "bundle")]
no_tray: *matches.get_one("no-tray").unwrap(), no_tray: *matches.get_one("no-tray").unwrap(),
#[cfg(not(feature = "bundle"))]
no_tray: true,
}) })
} }