Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renamed and merged crates #40

Merged
merged 1 commit into from
Sep 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 1 addition & 8 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,6 @@ jobs:
run: cargo set-version "$(echo "${{ github.ref_name }}" | sed -e 's/^v//')"

- name: Build and publish prdoclib
run: cargo publish -p prdoclib --token "${CRATESIO_TOKEN}"
env:
CRATESIO_TOKEN: ${{ secrets.CRATESIO_TOKEN }}

- name: Build and publish prdoc
# `set-version` will change Cargo.toml in `cli` package as it depends on `prdoclib`
# thus, we need --allow-dirty, to include uncommitted changes;
run: cargo publish --allow-dirty -p prdoc --token "${CRATESIO_TOKEN}"
run: cargo publish -p parity-prdoc --token "${CRATESIO_TOKEN}"
env:
CRATESIO_TOKEN: ${{ secrets.CRATESIO_TOKEN }}
63 changes: 26 additions & 37 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

43 changes: 36 additions & 7 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[workspace.package]
[package]
name = "parity-prdoc"
version = "0.0.0-updated-from-ci"
authors = ["chevdor <chevdor@gmail.com>", "Wilfried Kopp <wilfried@parity.io>", "Yuri Volkov <0@mcornholio.ru>"]
edition = "2021"
Expand All @@ -7,16 +8,44 @@ keywords = ["cli", "documentation", "parity"]
license = "MIT"
repository = "https://github.com/paritytech/prdoc"

[workspace]
resolver = "2"
members = [
"cli",
"prdoclib",
]
[lib]
name = "prdoclib"
path = "src/lib.rs"

[[bin]]
name = "prdoc"

[profile.production]
inherits = "release"
lto = true
panic = "abort"
opt-level = "z"
codegen-units = 1

[dependencies]
log = "0.4"
regex = "1.10"
exitcode = "1.1"
thiserror = "1.0"
serde = { version = "1.0", features = ["derive"] }
serde_yaml = { version = "0.9", optional = false }
serde_json = { version = "1.0", optional = false }
valico = { version = "4.0", default-features = false, features = [] }
toml = "0.8.19"
assert_cmd = "2.0"
color-eyre = "0.6"
env_logger = "0.11"
clap = { version = "4", features = [
"derive",
"env",
"unicode",
"cargo",
"color",
"help",
"usage",
"error-context",
"suggestions",
] }

[dev-dependencies]
assert_cmd = "2.0"
12 changes: 6 additions & 6 deletions cli/build.rs → build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@ pub fn generate_cargo_key_build_date() {
Ok(o) if o.status.success() => {
let sha = String::from_utf8_lossy(&o.stdout).trim().to_owned();
Cow::from(sha)
}
},
Ok(o) => {
let status = o.status;
println!("cargo:warning=Failed fetching the date timestamp: {status}");
Cow::from("unknown")
}
},
Err(err) => {
println!("cargo:warning=Failed fetching the datge: {err}");
Cow::from("unknown")
}
},
};

println!("cargo:rustc-env=PRDOC_CLI_BUILD_DATE={build_date}");
Expand All @@ -38,16 +38,16 @@ pub fn generate_cargo_key_git() {
Ok(o) if o.status.success() => {
let tmsp = String::from_utf8_lossy(&o.stdout).trim().to_owned();
Cow::from(tmsp)
}
},
Ok(o) => {
let status = o.status;
println!("cargo:warning=Git command failed with status: {status}");
Cow::from("unknown")
}
},
Err(err) => {
println!("cargo:warning=Failed to execute git command: {err}");
Cow::from("unknown")
}
},
}
};

Expand Down
4 changes: 0 additions & 4 deletions cli/.rustfmt.toml

This file was deleted.

39 changes: 0 additions & 39 deletions cli/Cargo.toml

This file was deleted.

1 change: 0 additions & 1 deletion cli/README.md

This file was deleted.

65 changes: 0 additions & 65 deletions cli/tests/check.rs

This file was deleted.

11 changes: 0 additions & 11 deletions cli/tests/common.rs

This file was deleted.

47 changes: 0 additions & 47 deletions cli/tests/generate.rs

This file was deleted.

Loading
Loading