diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 3aa8616..fd3fb56 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -14,7 +14,7 @@ jobs: steps: - uses: actions/checkout@v4 - name: nixci - run: nixci build --build-systems "github:nix-systems/${{ matrix.system }}" + run: nixci build --systems "github:nix-systems/${{ matrix.system }}" # FIXME: This should run only darwin - name: Integration Test run: nix develop -c cargo test -F integration_test diff --git a/CHANGELOG.md b/CHANGELOG.md index f2ab6a7..df806e4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,7 +3,7 @@ - New features - Add new config `nixci.*.*.systems` acting as a whitelist of systems to build that subflake. - - Add `--build-systems` option to build on an arbitrary systems (\#39) + - Add `nixci build --systems` option to build on an arbitrary systems (\#39) - Allow selecting sub-flake to build, e.g.: `nixci .#default.myflake` (\#45) - Add subcommand to generate Github Actions matrix (\#50) - Consequently, you must run `nixci build` instead of `nixci` now. diff --git a/README.md b/README.md index a311b3c..9323e19 100644 --- a/README.md +++ b/README.md @@ -83,7 +83,7 @@ jobs: fail-fast: false steps: - uses: actions/checkout@v4 - - run: nixci build --build-systems "github:nix-systems/${{ matrix.system }}" .#default.${{ matrix.subflake}} + - run: nixci build --systems "github:nix-systems/${{ matrix.system }}" .#default.${{ matrix.subflake}} ``` ## Configuring diff --git a/src/cli.rs b/src/cli.rs index 8dc218d..54af02a 100644 --- a/src/cli.rs +++ b/src/cli.rs @@ -106,7 +106,7 @@ pub struct BuildConfig { /// of systems. You may use one of the lists from /// https://github.com/nix-systems. #[arg(long, default_value = "github:nix-systems/empty")] - pub build_systems: SystemsListFlakeRef, + pub systems: SystemsListFlakeRef, /// Flake URL or github URL /// @@ -125,8 +125,8 @@ pub struct BuildConfig { } impl BuildConfig { - pub async fn get_build_systems(&self) -> Result> { - let systems = SystemsList::from_flake(&self.build_systems).await?.0; + pub async fn get_systems(&self) -> Result> { + let systems = SystemsList::from_flake(&self.systems).await?.0; if systems.is_empty() { let current_system = get_current_system().await?; Ok(vec![current_system]) diff --git a/src/config.rs b/src/config.rs index 0008554..5c0554e 100644 --- a/src/config.rs +++ b/src/config.rs @@ -145,7 +145,7 @@ impl SubFlakish { .chain([ "--override-input".to_string(), "systems".to_string(), - build_cfg.build_systems.0 .0.clone(), + build_cfg.systems.0 .0.clone(), ]) .chain(build_cfg.extra_nix_build_args.iter().cloned()) .collect() diff --git a/src/lib.rs b/src/lib.rs index ca1f879..7ce6edc 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -35,7 +35,7 @@ async fn nixci_build( ) -> anyhow::Result> { let mut all_outs = HashSet::new(); - let systems = build_cfg.get_build_systems().await?; + let systems = build_cfg.get_systems().await?; for (subflake_name, subflake) in &cfg.subflakes.0 { let name = format!("{}.{}", cfg.name, subflake_name).italic();