diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ce8b55148..22aa44bdb 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -137,6 +137,7 @@ jobs: RUST_BACKTRACE: full # Try running cargo build on all other platforms. + # # TODO: Maybe some of these should be allowed to fail? If so, I guess we can add back the "unofficial" MSRV, # I would also put android there. other-check: @@ -231,9 +232,6 @@ jobs: no-clippy: true, } - # Seems like cross' FreeBSD image is a bit broken? I - # get build errors, may be related to this issue: - # https://github.com/cross-rs/cross/issues/1291 steps: - name: Checkout repository uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 @@ -252,24 +250,6 @@ jobs: key: ${{ matrix.info.target }} cache-all-crates: true - # - name: Test (default features) - # uses: ClementTsang/cargo-action@v0.0.5 - # if: ${{ matrix.info.no-default-features != true }} - # with: - # command: test - # args: --all-targets --workspace --target=${{ matrix.info.target }} --locked - # use-cross: ${{ matrix.info.cross }} - # cross-version: ${{ matrix.info.cross-version || '0.2.5' }} - - # - name: Test (no features enabled) - # uses: ClementTsang/cargo-action@v0.0.5 - # if: ${{ matrix.info.no-default-features == true }} - # with: - # command: test - # args: --all-targets --workspace --target=${{ matrix.info.target }} --locked --no-default-features - # use-cross: ${{ matrix.info.cross }} - # cross-version: ${{ matrix.info.cross-version || '0.2.5' }} - - name: Check (default features) uses: ClementTsang/cargo-action@v0.0.5 if: ${{ matrix.info.no-default-features != true }} @@ -298,6 +278,11 @@ jobs: fail-fast: false matrix: info: + # Seems like cross' FreeBSD image is a bit broken? I + # get build errors, may be related to this issue: + # https://github.com/cross-rs/cross/issues/1291 + # + # Alas, that's why we do it with VMs. - { type: "freebsd", os_release: "14.1", diff --git a/schema/nightly/bottom.json b/schema/nightly/bottom.json index 47ade4e9a..9ff9ec9f4 100644 --- a/schema/nightly/bottom.json +++ b/schema/nightly/bottom.json @@ -1,7 +1,7 @@ { "$schema": "http://json-schema.org/draft-07/schema#", "$id": "https://github.com/ClementTsang/bottom/blob/main/schema/nightly/bottom.json", - "title": "Schema for bottom's configs (nightly)", + "title": "Schema for bottom's config file (nightly)", "description": "https://clementtsang.github.io/bottom/nightly/configuration/config-file", "type": "object", "properties": { diff --git a/schema/v0.10/bottom.json b/schema/v0.10/bottom.json index d109e0114..9cd2afd4a 100644 --- a/schema/v0.10/bottom.json +++ b/schema/v0.10/bottom.json @@ -1,8 +1,8 @@ { "$schema": "http://json-schema.org/draft-07/schema#", - "$id": "https://github.com/ClementTsang/bottom/blob/main/schema/nightly/bottom.json", - "title": "Schema for bottom's configs (nightly)", - "description": "https://clementtsang.github.io/bottom/nightly/configuration/config-file", + "$id": "https://github.com/ClementTsang/bottom/blob/main/schema/v0.10/bottom.json", + "title": "Schema for bottom's configs (v0.10)", + "description": "https://clementtsang.github.io/bottom/0.10.0/configuration/config-file/", "type": "object", "properties": { "cpu": { diff --git a/schema/v0.9/bottom.json b/schema/v0.9/bottom.json index 043226453..4b1f4f403 100644 --- a/schema/v0.9/bottom.json +++ b/schema/v0.9/bottom.json @@ -1,8 +1,8 @@ { "$schema": "http://json-schema.org/draft-07/schema#", - "$id": "https://github.com/ClementTsang/bottom/blob/main/schema/v1.0/bottom.json", + "$id": "https://github.com/ClementTsang/bottom/blob/main/schema/v0.9/bottom.json", "$comment": "https://clementtsang.github.io/bottom/0.9.6/configuration/config-file/default-config/", - "title": "Schema for bottom's configs (v1.0)", + "title": "Schema for bottom's configs (v0.9)", "type": "object", "definitions": { "row": { diff --git a/src/bin/schema.rs b/src/bin/schema.rs index d04fdd9f2..58e0cedad 100644 --- a/src/bin/schema.rs +++ b/src/bin/schema.rs @@ -60,6 +60,7 @@ fn generate_schema(schema_options: SchemaOptions) -> anyhow::Result<()> { "stable" } )); + metadata.title = Some(format!("Schema for bottom's config file ({version})",)); println!("{}", serde_json::to_string_pretty(&schema).unwrap()); Ok(()) diff --git a/src/options/config.rs b/src/options/config.rs index 2c105a776..073153acf 100644 --- a/src/options/config.rs +++ b/src/options/config.rs @@ -20,11 +20,7 @@ use self::{cpu::CpuConfig, layout::Row, process::ProcessesConfig}; /// Overall config for `bottom`. #[derive(Clone, Debug, Default, Deserialize)] -#[cfg_attr( - feature = "generate_schema", - derive(schemars::JsonSchema), - schemars(title = "Schema for bottom's configs (nightly)") -)] +#[cfg_attr(feature = "generate_schema", derive(schemars::JsonSchema))] #[cfg_attr(test, serde(deny_unknown_fields), derive(PartialEq, Eq))] pub struct Config { pub(crate) flags: Option,