bug: fix incorrect versions in schemas (#1635)
This commit is contained in:
parent
ae0d350122
commit
bc3032cf10
|
@ -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",
|
||||
|
|
|
@ -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": {
|
||||
|
|
|
@ -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": {
|
||||
|
|
|
@ -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": {
|
||||
|
|
|
@ -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(())
|
||||
|
|
|
@ -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<FlagConfig>,
|
||||
|
|
Loading…
Reference in New Issue