Skip to content

Commit 8e67725

Browse files
ci: create publishing task
1 parent 584d956 commit 8e67725

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

.github/workflows/publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,4 @@ jobs:
4141
- name: Publish crates to crates.io
4242
env:
4343
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
44-
run: cargo workspaces publish --publish-as-is --allow-branch main
44+
run: cargo make publish-crates

Makefile.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -620,6 +620,10 @@ for workspace_dependency in ${workspace_dependencies[@]}; do
620620
done
621621
'''
622622

623+
[tasks.publish-crates]
624+
dependencies = ["install-cargo-workspaces"]
625+
script = "cargo workspaces publish --publish-as-is"
626+
623627
[tasks.install-llvm-tools-preview]
624628
install_crate = { rustup_component_name = "llvm-tools-preview" }
625629

@@ -660,6 +664,9 @@ install_crate = { crate_name = "cargo-hack", min_version = "0.6.14" }
660664
[tasks.install-toml-cli]
661665
install_crate = { crate_name = "toml-cli", min_version = "0.2.3" }
662666

667+
[tasks.install-cargo-workspaces]
668+
install_crate = { crate_name = "cargo-workspaces", min_version = "0.3.2" }
669+
663670
[config]
664671
default_to_workspace = false
665672
min_version = "0.36.3"

0 commit comments

Comments
 (0)