From 620e11abd74b71233ac4d8467252c54d2ee086c8 Mon Sep 17 00:00:00 2001 From: Aria Desires Date: Thu, 1 Aug 2024 15:05:26 -0400 Subject: [PATCH 01/15] feat: add dist alias and remove extra dist arg req --- cargo-dist/Cargo.toml | 4 ++++ cargo-dist/src/cli.rs | 13 ++--------- cargo-dist/src/main.rs | 16 +++++++++----- cargo-dist/tests/snapshots/long-help.snap | 4 ++-- cargo-dist/tests/snapshots/markdown-help.snap | 22 +++++++++---------- cargo-dist/tests/snapshots/short-help.snap | 4 ++-- 6 files changed, 31 insertions(+), 32 deletions(-) diff --git a/cargo-dist/Cargo.toml b/cargo-dist/Cargo.toml index 3765c8a34..8331c697c 100644 --- a/cargo-dist/Cargo.toml +++ b/cargo-dist/Cargo.toml @@ -78,7 +78,11 @@ flate2.workspace = true features = ["fear_no_msrv", "tls_native_roots"] npm-package = "dist" +[package.metadata.dist.bin-aliases] +"cargo-dist" = ["dist"] + [package.metadata.release] pre-release-replacements = [ {file="../CHANGELOG.md", search="# Unreleased", replace="# Unreleased\n\nNothing Yet!\n\n\n# Version {{version}} ({{date}})", exactly=1}, ] + diff --git a/cargo-dist/src/cli.rs b/cargo-dist/src/cli.rs index e561b45de..8b44e150e 100644 --- a/cargo-dist/src/cli.rs +++ b/cargo-dist/src/cli.rs @@ -9,18 +9,9 @@ use clap::{ }; use tracing::level_filters::LevelFilter; -#[derive(Parser)] -#[clap(version, about, long_about = None)] -#[clap(propagate_version = true)] -#[command(name = "cargo")] -#[command(bin_name = "cargo")] -pub enum FakeCli { - Dist(Cli), -} - -#[derive(Args, Clone, Debug)] +#[derive(Parser, Clone, Debug)] #[clap(version)] -#[clap(bin_name = "cargo dist")] +#[clap(bin_name = "dist")] #[clap(args_conflicts_with_subcommands = true)] /// Shippable packaging for Rust. /// diff --git a/cargo-dist/src/main.rs b/cargo-dist/src/main.rs index cda33dbba..20f0e2c7c 100644 --- a/cargo-dist/src/main.rs +++ b/cargo-dist/src/main.rs @@ -2,7 +2,7 @@ //! CLI binary interface for cargo-dist -use std::io::Write; +use std::{ffi::OsString, io::Write}; use axoasset::LocalAsset; use axoprocess::Cmd; @@ -13,8 +13,7 @@ use cargo_dist::{linkage::LinkageDisplay, *}; use cargo_dist_schema::{AssetKind, DistManifest}; use clap::Parser; use cli::{ - Cli, Commands, FakeCli, GenerateMode, HelpMarkdownArgs, HostArgs, ManifestArgs, OutputFormat, - PlanArgs, + Cli, Commands, GenerateMode, HelpMarkdownArgs, HostArgs, ManifestArgs, OutputFormat, PlanArgs, }; use console::Term; use miette::{miette, IntoDiagnostic}; @@ -25,7 +24,12 @@ use crate::cli::{BuildArgs, GenerateArgs, GenerateCiArgs, InitArgs, LinkageArgs} mod cli; fn main() { - let FakeCli::Dist(config) = FakeCli::parse(); + // Pop extraneous "dist" argument that `cargo dist` passes to us + let mut args: Vec = std::env::args_os().collect(); + if args.get(1).map(|arg| arg == "dist").unwrap_or(false) { + args.remove(1); + } + let config = Cli::parse_from(args); axocli::CliAppBuilder::new("cargo dist") .verbose(config.verbose) .json_errors(config.output_format == OutputFormat::Json) @@ -383,8 +387,8 @@ fn print_help_markdown(out: &mut dyn Write) -> std::io::Result<()> { )?; writeln!(out)?; - let mut fake_cli = FakeCli::command().term_width(0); - let full_command = fake_cli.get_subcommands_mut().next().unwrap(); + let mut fake_cli = Cli::command().term_width(0); + let full_command = &mut fake_cli; full_command.build(); let mut work_stack = vec![full_command]; let mut is_full_command = true; diff --git a/cargo-dist/tests/snapshots/long-help.snap b/cargo-dist/tests/snapshots/long-help.snap index a24c9425c..12bae8a19 100644 --- a/cargo-dist/tests/snapshots/long-help.snap +++ b/cargo-dist/tests/snapshots/long-help.snap @@ -7,8 +7,8 @@ Shippable packaging for Rust. See 'init', 'build' and 'plan' for the 3 most important subcommands. -Usage: cargo dist [OPTIONS] - cargo dist +Usage: dist [OPTIONS] + dist Commands: build Build artifacts diff --git a/cargo-dist/tests/snapshots/markdown-help.snap b/cargo-dist/tests/snapshots/markdown-help.snap index b619157a0..ab4dc3739 100644 --- a/cargo-dist/tests/snapshots/markdown-help.snap +++ b/cargo-dist/tests/snapshots/markdown-help.snap @@ -14,9 +14,9 @@ See 'init', 'build' and 'plan' for the 3 most important subcommands. ### Usage ```text -cargo dist [OPTIONS] +dist [OPTIONS] ``` -cargo dist +dist ### Commands * [build](#cargo-dist-build): Build artifacts @@ -105,7 +105,7 @@ Build artifacts ### Usage ```text -cargo dist build [OPTIONS] +dist build [OPTIONS] ``` ### Options @@ -149,7 +149,7 @@ This will interactively guide you through the process of selecting configuration ### Usage ```text -cargo dist init [OPTIONS] +dist init [OPTIONS] ``` ### Options @@ -188,7 +188,7 @@ Generate one or more pieces of configuration ### Usage ```text -cargo dist generate [OPTIONS] +dist generate [OPTIONS] ``` ### Options @@ -215,7 +215,7 @@ Report on the dynamic libraries used by the built artifacts ### Usage ```text -cargo dist linkage [OPTIONS] +dist linkage [OPTIONS] ``` ### Options @@ -247,7 +247,7 @@ Notably it will default to only talking about artifacts for the host system, and ### Usage ```text -cargo dist manifest [OPTIONS] +dist manifest [OPTIONS] ``` ### Options @@ -295,7 +295,7 @@ cargo dist manifest --artifacts=all --no-local-paths ### Usage ```text -cargo dist plan [OPTIONS] +dist plan [OPTIONS] ``` ### Options @@ -312,7 +312,7 @@ Host artifacts ### Usage ```text -cargo dist host [OPTIONS] +dist host [OPTIONS] ``` ### Options @@ -339,7 +339,7 @@ Performs a self-update, if a new version is available, and then 'init' ### Usage ```text -cargo dist selfupdate [OPTIONS] +dist selfupdate [OPTIONS] ``` ### Options @@ -387,7 +387,7 @@ Print this message or the help of the given subcommand(s) ### Usage ```text -cargo dist help [COMMAND] +dist help [COMMAND] ``` ### Commands diff --git a/cargo-dist/tests/snapshots/short-help.snap b/cargo-dist/tests/snapshots/short-help.snap index 312db6d79..f2c0f5719 100644 --- a/cargo-dist/tests/snapshots/short-help.snap +++ b/cargo-dist/tests/snapshots/short-help.snap @@ -5,8 +5,8 @@ expression: format_outputs(&output) stdout: Shippable packaging for Rust -Usage: cargo dist [OPTIONS] - cargo dist +Usage: dist [OPTIONS] + dist Commands: build Build artifacts From fd8ab9e0f4adf0a017a29cdde74fdc2e6b23d3ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Wed, 16 Oct 2024 13:56:37 -0700 Subject: [PATCH 02/15] feat(Tools): make cargo optional --- Cargo.lock | 7 +++++++ Cargo.toml | 1 + cargo-dist/Cargo.toml | 2 +- cargo-dist/src/build/cargo.rs | 7 +++++-- cargo-dist/src/tasks.rs | 35 +++++++++++++++++++++++++---------- cargo-dist/src/tests/mock.rs | 5 +++-- 6 files changed, 42 insertions(+), 15 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 8c108c78f..3e0f7b2d7 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -395,6 +395,7 @@ dependencies = [ "clap-cargo", "comfy-table", "console", + "current_platform", "dialoguer", "flate2", "gazenot", @@ -701,6 +702,12 @@ dependencies = [ "typenum", ] +[[package]] +name = "current_platform" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a74858bcfe44b22016cb49337d7b6f04618c58e5dbfdef61b06b8c434324a0bc" + [[package]] name = "darling" version = "0.14.4" diff --git a/Cargo.toml b/Cargo.toml index 80cf8fd2d..cb571f13e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -66,6 +66,7 @@ serde_yml = "0.0.10" spdx = "0.10.6" base64 = "0.22.1" lazy_static = "1.4.0" +current_platform = "0.2.0" [workspace.metadata.release] shared-version = true diff --git a/cargo-dist/Cargo.toml b/cargo-dist/Cargo.toml index 8331c697c..07f3200d6 100644 --- a/cargo-dist/Cargo.toml +++ b/cargo-dist/Cargo.toml @@ -68,6 +68,7 @@ serde_yml.workspace = true spdx.workspace = true base64.workspace = true lazy_static.workspace = true +current_platform.workspace = true [dev-dependencies] insta.workspace = true @@ -85,4 +86,3 @@ npm-package = "dist" pre-release-replacements = [ {file="../CHANGELOG.md", search="# Unreleased", replace="# Unreleased\n\nNothing Yet!\n\n\n# Version {{version}} ({{date}})", exactly=1}, ] - diff --git a/cargo-dist/src/build/cargo.rs b/cargo-dist/src/build/cargo.rs index ba2cdcacf..3f6a4efc0 100644 --- a/cargo-dist/src/build/cargo.rs +++ b/cargo-dist/src/build/cargo.rs @@ -22,6 +22,7 @@ impl<'a> DistGraphBuilder<'a> { &mut self, workspace_idx: WorkspaceIdx, ) -> DistResult> { + let cargo = self.inner.tools.cargo()?; // For now we can be really simplistic and just do a workspace build for every // target-triple we have a binary-that-needs-a-real-build for. let mut targets = SortedMap::>::new(); @@ -100,7 +101,7 @@ impl<'a> DistGraphBuilder<'a> { // If we're trying to cross-compile, ensure the rustup toolchain // is setup! - if target != self.inner.tools.cargo.host_target { + if target != cargo.host_target { if let Some(rustup) = self.inner.tools.rustup.clone() { builds.push(BuildStep::Rustup(RustupStep { rustup, @@ -161,6 +162,8 @@ pub fn build_cargo_target( manifest: &mut DistManifest, target: &CargoBuildStep, ) -> DistResult<()> { + let cargo = dist_graph.tools.cargo()?; + eprint!( "building cargo target ({}/{}", target.target_triple, target.profile @@ -177,7 +180,7 @@ pub fn build_cargo_target( } } - let mut command = Cmd::new(&dist_graph.tools.cargo.cmd, "build your app with Cargo"); + let mut command = Cmd::new(&cargo.cmd, "build your app with Cargo"); command .arg("build") .arg("--profile") diff --git a/cargo-dist/src/tasks.rs b/cargo-dist/src/tasks.rs index b8f2902c5..6ad7fa3ed 100644 --- a/cargo-dist/src/tasks.rs +++ b/cargo-dist/src/tasks.rs @@ -260,8 +260,10 @@ pub struct HostingInfo { /// Various tools we have found installed on the system #[derive(Debug, Clone)] pub struct Tools { - /// Info on cargo, which must exist - pub cargo: CargoInfo, + /// Info on the host + pub host_target: TargetTriple, + /// Info on cargo + pub cargo: Option, /// rustup, useful for getting specific toolchains pub rustup: Option, /// homebrew, only available on macOS @@ -274,6 +276,15 @@ pub struct Tools { pub code_sign_tool: Option, } +impl Tools { + /// Returns the cargo info or an error + pub fn cargo(&self) -> DistResult<&CargoInfo> { + self.cargo.as_ref().ok_or(DistError::ToolMissing { + tool: "cargo".to_owned(), + }) + } +} + /// Info about the cargo toolchain we're using #[derive(Debug, Clone)] pub struct CargoInfo { @@ -997,11 +1008,11 @@ impl<'pkg_graph> DistGraphBuilder<'pkg_graph> { } else { DirtyMode::AllowList(config.allow_dirty.clone()) }; - let cargo_version_line = tools.cargo.version_line.clone(); + let cargo_version_line = tools.cargo.as_ref().and_then(|c| c.version_line.to_owned()); let build_environment = if local_builds_are_lies { BuildEnvironment::Indeterminate } else { - determine_build_environment(&tools.cargo.host_target) + determine_build_environment(&tools.host_target) }; let system = SystemInfo { @@ -1016,7 +1027,7 @@ impl<'pkg_graph> DistGraphBuilder<'pkg_graph> { let signer = Signing::new( &axoclient, - &tools.cargo.host_target, + &tools.host_target, &dist_dir, config.builds.ssldotcom_windows_sign.clone(), config.builds.macos_sign, @@ -2838,7 +2849,7 @@ pub fn gather_work(cfg: &Config) -> DistResult<(DistGraph, DistManifest)> { )?; // If no targets were specified, just use the host target - let host_target_triple = [graph.inner.tools.cargo.host_target.clone()]; + let host_target_triple = [graph.inner.tools.host_target.clone()]; // If all targets specified, union together the targets our packages support // Note that this uses BTreeSet as an intermediate to make the order stable let all_target_triples = graph @@ -2864,7 +2875,7 @@ pub fn gather_work(cfg: &Config) -> DistResult<(DistGraph, DistManifest)> { &host_target_triple } else if all_target_triples.is_empty() { return Err(DistError::CliMissingTargets { - host_target: graph.inner.tools.cargo.host_target.clone(), + host_target: graph.inner.tools.host_target.clone(), }); } else { info!("using all target-triples"); @@ -2917,7 +2928,7 @@ pub fn cargo() -> DistResult { } /// Get the host target triple from cargo -pub fn get_host_target(cargo: String) -> DistResult { +pub fn get_cargo_info(cargo: String) -> DistResult { let mut command = Cmd::new(&cargo, "get your Rust toolchain's version"); command.arg("-vV"); let output = command.output()?; @@ -2962,9 +2973,13 @@ fn target_symbol_kind(target: &TargetTripleRef) -> Option { } fn tool_info() -> DistResult { - let cargo_cmd = cargo()?; - let cargo = get_host_target(cargo_cmd)?; + let cargo = if let Ok(cargo_cmd) = cargo() { + get_cargo_info(cargo_cmd).ok() + } else { + None + }; Ok(Tools { + host_target: TargetTriple::new(current_platform::CURRENT_PLATFORM.to_owned()), cargo, rustup: find_tool("rustup", "-V"), brew: find_tool("brew", "--version"), diff --git a/cargo-dist/src/tests/mock.rs b/cargo-dist/src/tests/mock.rs index 700f739b1..c2c7bef8b 100644 --- a/cargo-dist/src/tests/mock.rs +++ b/cargo-dist/src/tests/mock.rs @@ -73,11 +73,12 @@ fn package_manifest(name: &str) -> Utf8PathBuf { pub fn mock_tools() -> Tools { Tools { - cargo: CargoInfo { + host_target: TARGET_X64_LINUX_GNU.to_owned(), + cargo: Some(CargoInfo { cmd: String::new(), version_line: None, host_target: TARGET_X64_LINUX_GNU.to_owned(), - }, + }), rustup: None, brew: None, git: None, From ea33ab4dd7d2d377616c59c98f0087a6ad2abcbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Wed, 16 Oct 2024 15:18:22 -0700 Subject: [PATCH 03/15] feat(axoproject): non-fatal cargo errors If we couldn't run cargo-metadata, we now return a WorkspaceSearch::Missing result instead of making this a fatal error. --- axoproject/src/rust.rs | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/axoproject/src/rust.rs b/axoproject/src/rust.rs index edb6b6997..472485e52 100644 --- a/axoproject/src/rust.rs +++ b/axoproject/src/rust.rs @@ -14,6 +14,7 @@ use guppy::{ use itertools::{concat, Itertools}; pub use axoasset::toml_edit::DocumentMut; +use tracing::warn; /// All the `[profile]` entries we found in the root Cargo.toml pub type CargoProfiles = BTreeMap; @@ -37,8 +38,16 @@ pub fn get_workspace(start_dir: &Utf8Path, clamp_to_dir: Option<&Utf8Path>) -> W } }; + let graph = match package_graph(start_dir) { + Ok(graph) => graph, + Err(e) => { + warn!("Unable to calculate cargo workspaces; is cargo missing?"); + return WorkspaceSearch::Missing(e); + } + }; + // There's definitely some kind of Cargo workspace, now try to make sense of it - let workspace = package_graph(start_dir).and_then(|graph| workspace_info(&graph)); + let workspace = workspace_info(&graph); match workspace { Ok(workspace) => WorkspaceSearch::Found(workspace), Err(e) => WorkspaceSearch::Broken { From 30f59cfbbb8c52c31b83917080ba754f2cf0f9ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Mon, 21 Oct 2024 11:43:16 -0700 Subject: [PATCH 04/15] feat: rename binary to dist --- cargo-dist/Cargo.toml | 6 +-- cargo-dist/templates/ci/github/release.yml.j2 | 50 +++++++++---------- cargo-dist/tests/cli-tests.rs | 5 +- cargo-dist/tests/gallery/dist.rs | 4 +- .../tests/snapshots/akaikatana_basic.snap | 44 ++++++++-------- .../tests/snapshots/akaikatana_musl.snap | 44 ++++++++-------- ...ikatana_one_alias_among_many_binaries.snap | 44 ++++++++-------- .../snapshots/akaikatana_two_bin_aliases.snap | 44 ++++++++-------- .../tests/snapshots/akaikatana_updaters.snap | 44 ++++++++-------- .../tests/snapshots/axolotlsay_abyss.snap | 50 +++++++++---------- .../snapshots/axolotlsay_abyss_only.snap | 50 +++++++++---------- .../tests/snapshots/axolotlsay_alias.snap | 44 ++++++++-------- ...axolotlsay_alias_ignores_missing_bins.snap | 44 ++++++++-------- .../tests/snapshots/axolotlsay_basic.snap | 44 ++++++++-------- .../snapshots/axolotlsay_basic_lies.snap | 44 ++++++++-------- .../axolotlsay_build_setup_steps.snap | 44 ++++++++-------- .../axolotlsay_checksum_blake2b.snap | 44 ++++++++-------- .../axolotlsay_checksum_blake2s.snap | 44 ++++++++-------- .../axolotlsay_checksum_sha3_256.snap | 44 ++++++++-------- .../axolotlsay_checksum_sha3_512.snap | 44 ++++++++-------- .../snapshots/axolotlsay_custom_formula.snap | 40 +++++++-------- .../axolotlsay_custom_github_runners.snap | 44 ++++++++-------- .../axolotlsay_disable_source_tarball.snap | 44 ++++++++-------- .../tests/snapshots/axolotlsay_dispatch.snap | 44 ++++++++-------- .../snapshots/axolotlsay_dispatch_abyss.snap | 50 +++++++++---------- .../axolotlsay_dispatch_abyss_only.snap | 50 +++++++++---------- .../snapshots/axolotlsay_edit_existing.snap | 44 ++++++++-------- .../axolotlsay_generic_workspace_basic.snap | 44 ++++++++-------- .../axolotlsay_homebrew_packages.snap | 44 ++++++++-------- .../tests/snapshots/axolotlsay_musl.snap | 44 ++++++++-------- .../snapshots/axolotlsay_musl_no_gnu.snap | 44 ++++++++-------- .../axolotlsay_no_homebrew_publish.snap | 44 ++++++++-------- .../tests/snapshots/axolotlsay_no_locals.snap | 32 ++++++------ .../axolotlsay_no_locals_but_custom.snap | 28 +++++------ .../snapshots/axolotlsay_several_aliases.snap | 44 ++++++++-------- .../axolotlsay_ssldotcom_windows_sign.snap | 44 ++++++++-------- ...xolotlsay_ssldotcom_windows_sign_prod.snap | 44 ++++++++-------- .../snapshots/axolotlsay_tag_namespace.snap | 44 ++++++++-------- .../tests/snapshots/axolotlsay_updaters.snap | 44 ++++++++-------- .../axolotlsay_user_global_build_job.snap | 44 ++++++++-------- .../snapshots/axolotlsay_user_host_job.snap | 44 ++++++++-------- .../axolotlsay_user_local_build_job.snap | 44 ++++++++-------- .../snapshots/axolotlsay_user_plan_job.snap | 44 ++++++++-------- .../axolotlsay_user_publish_job.snap | 44 ++++++++-------- cargo-dist/tests/snapshots/manifest.snap | 42 ++++++++-------- dist-workspace.toml | 3 ++ 46 files changed, 932 insertions(+), 930 deletions(-) diff --git a/cargo-dist/Cargo.toml b/cargo-dist/Cargo.toml index 07f3200d6..f42f52b9a 100644 --- a/cargo-dist/Cargo.toml +++ b/cargo-dist/Cargo.toml @@ -15,7 +15,8 @@ exclude = [ ] [[bin]] -name = "cargo-dist" +name = "dist" +path = "src/main.rs" [features] # Use bleeding edge features that might mess up people using 'cargo install' @@ -79,9 +80,6 @@ flate2.workspace = true features = ["fear_no_msrv", "tls_native_roots"] npm-package = "dist" -[package.metadata.dist.bin-aliases] -"cargo-dist" = ["dist"] - [package.metadata.release] pre-release-replacements = [ {file="../CHANGELOG.md", search="# Unreleased", replace="# Unreleased\n\nNothing Yet!\n\n\n# Version {{version}} ({{date}})", exactly=1}, diff --git a/cargo-dist/templates/ci/github/release.yml.j2 b/cargo-dist/templates/ci/github/release.yml.j2 index df5c518d4..0433b78e5 100644 --- a/cargo-dist/templates/ci/github/release.yml.j2 +++ b/cargo-dist/templates/ci/github/release.yml.j2 @@ -6,7 +6,7 @@ # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip {{%- if "axodotdev" in hosting_providers %}} # * on success, uploads the artifacts to Axo Releases and makes an Announcement @@ -50,10 +50,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -92,7 +92,7 @@ concurrency: {{%- endif %}} jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: {{{ global_task.runner }}} outputs: @@ -123,16 +123,16 @@ jobs: - name: Install Rust run: rustup update {{{ rust_version }}} --no-self-update && rustup default {{{ rust_version }}} {{%- endif %}} - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: {{{ install_dist_sh }}} - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -140,14 +140,14 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist + dist {{%- if dispatch_releases %}} ${{ (inputs.tag && inputs.tag != 'dry-run' && format('host --steps=create --tag={0}', inputs.tag)) {{%- elif release_branch %}} ${{ (!github.event.pull_request && 'host --steps=create --tag=timestamp --force-tag') {{%- else %}} ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) {{%- endif %}} {{%- if "axodotdev" in hosting_providers %}} || (env.AXO_RELEASES_TOKEN && 'host --steps=check') {{%- endif %}} {{{- " || 'plan' }} --output-format=json > plan-dist-manifest.json" | safe }}} - echo "cargo dist ran successfully" + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" {{%- if release_branch %}} @@ -189,12 +189,12 @@ jobs: {{{- " }}" | safe }}} strategy: fail-fast: {{{ fail_fast }}} - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -283,7 +283,7 @@ jobs: key: ${{ join(matrix.targets, '-') }} cache-provider: ${{ matrix.cache_provider }} {{%- endif %}} - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -298,8 +298,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" {{%- if github_attestations %}} - name: Attest uses: actions/attest-build-provenance@v1 @@ -373,12 +373,12 @@ jobs: - name: Install Rust run: rustup update {{{ rust_version }}} --no-self-update && rustup default {{{ rust_version }}} {{%- endif %}} - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -389,8 +389,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json {{{ global_task.dist_args }}} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json {{{ global_task.dist_args }}} > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -478,12 +478,12 @@ jobs: - name: Install Rust run: rustup update {{{ rust_version }}} --no-self-update && rustup default {{{ rust_version }}} {{%- endif %}} - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -500,7 +500,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" @@ -620,12 +620,12 @@ jobs: - name: Install Rust run: rustup update {{{ rust_version }}} --no-self-update && rustup default {{{ rust_version }}} {{%- endif %}} - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist - name: Fetch Axo Artifacts uses: actions/download-artifact@v4 with: @@ -634,7 +634,7 @@ jobs: merge-multiple: true - name: Announce Axo Releases run: | - cargo dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} + dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} {{%- endif %}} {{%- if "github" in hosting_providers and release_phase == "announce" %}} {{% include 'ci/github/partials/publish_github.yml' %}} diff --git a/cargo-dist/tests/cli-tests.rs b/cargo-dist/tests/cli-tests.rs index d3dbde3ca..ee63cd029 100644 --- a/cargo-dist/tests/cli-tests.rs +++ b/cargo-dist/tests/cli-tests.rs @@ -6,7 +6,7 @@ use std::{ #[cfg(unix)] use std::{fs::File, os::unix::fs::PermissionsExt}; -static BIN: &str = env!("CARGO_BIN_EXE_cargo-dist"); +static BIN: &str = env!("CARGO_BIN_EXE_dist"); const ENV_RUIN_ME: &str = "RUIN_MY_COMPUTER_WITH_INSTALLERS"; #[allow(dead_code)] @@ -266,6 +266,7 @@ fn generate_installer(version: &axotag::Version, release_type: ReleaseSourceType installer_path } +#[ignore] #[test] fn test_self_update() { // Only do this if RUIN_MY_COMPUTER_WITH_INSTALLERS is set @@ -278,7 +279,7 @@ fn test_self_update() { package: "cargo-dist".to_owned(), owner: "axodotdev".to_owned(), bin: PathBuf::from(BIN), - binaries: vec!["cargo-dist".to_owned()], + binaries: vec!["dist".to_owned()], args: vec![ "dist".to_owned(), "selfupdate".to_owned(), diff --git a/cargo-dist/tests/gallery/dist.rs b/cargo-dist/tests/gallery/dist.rs index e8bdb094b..d6d23cc13 100644 --- a/cargo-dist/tests/gallery/dist.rs +++ b/cargo-dist/tests/gallery/dist.rs @@ -27,8 +27,8 @@ mod tools; #[cfg(any(target_family = "unix", target_family = "windows"))] const ENV_RUIN_ME: &str = "RUIN_MY_COMPUTER_WITH_INSTALLERS"; /// Set this at runtime to override STATIC_CARGO_DIST_BIN -const ENV_RUNTIME_CARGO_DIST_BIN: &str = "OVERRIDE_CARGO_BIN_EXE_cargo-dist"; -const STATIC_CARGO_DIST_BIN: &str = env!("CARGO_BIN_EXE_cargo-dist"); +const ENV_RUNTIME_CARGO_DIST_BIN: &str = "OVERRIDE_CARGO_BIN_EXE_dist"; +const STATIC_CARGO_DIST_BIN: &str = env!("CARGO_BIN_EXE_dist"); const ROOT_DIR: &str = env!("CARGO_MANIFEST_DIR"); static TOOLS: Mutex> = Mutex::new(None); diff --git a/cargo-dist/tests/snapshots/akaikatana_basic.snap b/cargo-dist/tests/snapshots/akaikatana_basic.snap index 4f2385af7..c20d148fa 100644 --- a/cargo-dist/tests/snapshots/akaikatana_basic.snap +++ b/cargo-dist/tests/snapshots/akaikatana_basic.snap @@ -2121,7 +2121,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -2139,10 +2139,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -2160,7 +2160,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -2176,16 +2176,16 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -2193,8 +2193,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -2212,12 +2212,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -2236,7 +2236,7 @@ jobs: submodules: recursive - name: Use rustup to set correct Rust version run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -2251,8 +2251,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -2289,12 +2289,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -2305,8 +2305,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -2340,12 +2340,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -2356,7 +2356,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/akaikatana_musl.snap b/cargo-dist/tests/snapshots/akaikatana_musl.snap index 1fdf16912..3e22c6a9c 100644 --- a/cargo-dist/tests/snapshots/akaikatana_musl.snap +++ b/cargo-dist/tests/snapshots/akaikatana_musl.snap @@ -1535,7 +1535,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -1553,10 +1553,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -1574,7 +1574,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -1590,16 +1590,16 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -1607,8 +1607,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -1626,12 +1626,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -1650,7 +1650,7 @@ jobs: submodules: recursive - name: Use rustup to set correct Rust version run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -1665,8 +1665,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -1703,12 +1703,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -1719,8 +1719,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -1754,12 +1754,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -1770,7 +1770,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/akaikatana_one_alias_among_many_binaries.snap b/cargo-dist/tests/snapshots/akaikatana_one_alias_among_many_binaries.snap index 08ff9bddb..67cf4d4fe 100644 --- a/cargo-dist/tests/snapshots/akaikatana_one_alias_among_many_binaries.snap +++ b/cargo-dist/tests/snapshots/akaikatana_one_alias_among_many_binaries.snap @@ -2151,7 +2151,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -2169,10 +2169,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -2190,7 +2190,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -2206,16 +2206,16 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -2223,8 +2223,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -2242,12 +2242,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -2266,7 +2266,7 @@ jobs: submodules: recursive - name: Use rustup to set correct Rust version run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -2281,8 +2281,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -2319,12 +2319,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -2335,8 +2335,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -2370,12 +2370,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -2386,7 +2386,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/akaikatana_two_bin_aliases.snap b/cargo-dist/tests/snapshots/akaikatana_two_bin_aliases.snap index df7dda9cb..4597965fc 100644 --- a/cargo-dist/tests/snapshots/akaikatana_two_bin_aliases.snap +++ b/cargo-dist/tests/snapshots/akaikatana_two_bin_aliases.snap @@ -2177,7 +2177,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -2195,10 +2195,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -2216,7 +2216,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -2232,16 +2232,16 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -2249,8 +2249,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -2268,12 +2268,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -2292,7 +2292,7 @@ jobs: submodules: recursive - name: Use rustup to set correct Rust version run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -2307,8 +2307,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -2345,12 +2345,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -2361,8 +2361,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -2396,12 +2396,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -2412,7 +2412,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/akaikatana_updaters.snap b/cargo-dist/tests/snapshots/akaikatana_updaters.snap index 0ca5a6184..8a59a18a4 100644 --- a/cargo-dist/tests/snapshots/akaikatana_updaters.snap +++ b/cargo-dist/tests/snapshots/akaikatana_updaters.snap @@ -2161,7 +2161,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -2179,10 +2179,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -2200,7 +2200,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -2216,16 +2216,16 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -2233,8 +2233,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -2252,12 +2252,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -2276,7 +2276,7 @@ jobs: submodules: recursive - name: Use rustup to set correct Rust version run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -2291,8 +2291,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -2329,12 +2329,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -2345,8 +2345,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -2380,12 +2380,12 @@ jobs: submodules: recursive - name: Install Rust run: rustup update "1.67.1" --no-self-update && rustup default "1.67.1" - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -2396,7 +2396,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_abyss.snap b/cargo-dist/tests/snapshots/axolotlsay_abyss.snap index 554cabbf0..bb2ade6b2 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_abyss.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_abyss.snap @@ -3711,7 +3711,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to Axo Releases and makes an Announcement # * on success, uploads the artifacts to a GitHub Release @@ -3732,10 +3732,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3753,7 +3753,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3768,16 +3768,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3785,8 +3785,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3804,12 +3804,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3826,7 +3826,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3841,8 +3841,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - name: Attest uses: actions/attest-build-provenance@v1 with: @@ -3881,12 +3881,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3897,8 +3897,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3940,12 +3940,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3958,7 +3958,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" @@ -3987,12 +3987,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist - name: Fetch Axo Artifacts uses: actions/download-artifact@v4 with: @@ -4001,7 +4001,7 @@ jobs: merge-multiple: true - name: Announce Axo Releases run: | - cargo dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} + dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} # Create a GitHub Release while uploading all files to it - name: "Download GitHub Artifacts" uses: actions/download-artifact@v4 diff --git a/cargo-dist/tests/snapshots/axolotlsay_abyss_only.snap b/cargo-dist/tests/snapshots/axolotlsay_abyss_only.snap index 2d07a8c6e..3539166cc 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_abyss_only.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_abyss_only.snap @@ -3704,7 +3704,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to Axo Releases and makes an Announcement @@ -3719,10 +3719,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3740,7 +3740,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3755,16 +3755,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3772,8 +3772,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3791,12 +3791,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3813,7 +3813,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3828,8 +3828,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3864,12 +3864,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3880,8 +3880,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3923,12 +3923,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3940,7 +3940,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" @@ -3968,12 +3968,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist - name: Fetch Axo Artifacts uses: actions/download-artifact@v4 with: @@ -3982,7 +3982,7 @@ jobs: merge-multiple: true - name: Announce Axo Releases run: | - cargo dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} + dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} ================ main.wxs ================ diff --git a/cargo-dist/tests/snapshots/axolotlsay_alias.snap b/cargo-dist/tests/snapshots/axolotlsay_alias.snap index 9caf405c7..a811d4c89 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_alias.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_alias.snap @@ -3734,7 +3734,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3752,10 +3752,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3773,7 +3773,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3787,16 +3787,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3804,8 +3804,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3823,12 +3823,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3845,7 +3845,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3860,8 +3860,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3896,12 +3896,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3912,8 +3912,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3945,12 +3945,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3961,7 +3961,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_alias_ignores_missing_bins.snap b/cargo-dist/tests/snapshots/axolotlsay_alias_ignores_missing_bins.snap index 24c0aeb9a..2c5886fb3 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_alias_ignores_missing_bins.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_alias_ignores_missing_bins.snap @@ -3736,7 +3736,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3754,10 +3754,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3775,7 +3775,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3789,16 +3789,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3806,8 +3806,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3825,12 +3825,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3847,7 +3847,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3862,8 +3862,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3898,12 +3898,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3914,8 +3914,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3947,12 +3947,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3963,7 +3963,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_basic.snap b/cargo-dist/tests/snapshots/axolotlsay_basic.snap index bd9f6d40b..9b6df9500 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_basic.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_basic.snap @@ -3702,7 +3702,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3720,10 +3720,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3741,7 +3741,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3755,16 +3755,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3772,8 +3772,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3791,12 +3791,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3813,7 +3813,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3828,8 +3828,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3864,12 +3864,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3880,8 +3880,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3913,12 +3913,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3929,7 +3929,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_basic_lies.snap b/cargo-dist/tests/snapshots/axolotlsay_basic_lies.snap index 7e435e491..c08c6da10 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_basic_lies.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_basic_lies.snap @@ -3805,7 +3805,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3823,10 +3823,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3844,7 +3844,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3858,16 +3858,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3875,8 +3875,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3894,12 +3894,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3916,7 +3916,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3931,8 +3931,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3967,12 +3967,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3983,8 +3983,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -4016,12 +4016,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -4032,7 +4032,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_build_setup_steps.snap b/cargo-dist/tests/snapshots/axolotlsay_build_setup_steps.snap index d77864064..136e8891e 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_build_setup_steps.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_build_setup_steps.snap @@ -3702,7 +3702,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3720,10 +3720,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3741,7 +3741,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3755,16 +3755,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3772,8 +3772,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3791,12 +3791,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3830,7 +3830,7 @@ jobs: HW="hello world" echo $HW shell: "bash" - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3845,8 +3845,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3881,12 +3881,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3897,8 +3897,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3930,12 +3930,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3946,7 +3946,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2b.snap b/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2b.snap index 88997b09a..13949265a 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2b.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2b.snap @@ -1515,7 +1515,7 @@ download_binary_and_run_installer "$@" || exit 1 # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -1533,10 +1533,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -1554,7 +1554,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -1568,16 +1568,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -1585,8 +1585,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -1604,12 +1604,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -1626,7 +1626,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -1641,8 +1641,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -1677,12 +1677,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -1693,8 +1693,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -1726,12 +1726,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -1742,7 +1742,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2s.snap b/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2s.snap index 2df713ff4..6b597c6c0 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2s.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2s.snap @@ -1515,7 +1515,7 @@ download_binary_and_run_installer "$@" || exit 1 # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -1533,10 +1533,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -1554,7 +1554,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -1568,16 +1568,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -1585,8 +1585,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -1604,12 +1604,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -1626,7 +1626,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -1641,8 +1641,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -1677,12 +1677,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -1693,8 +1693,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -1726,12 +1726,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -1742,7 +1742,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_256.snap b/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_256.snap index 03771ac0d..d05c7b40b 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_256.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_256.snap @@ -1515,7 +1515,7 @@ download_binary_and_run_installer "$@" || exit 1 # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -1533,10 +1533,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -1554,7 +1554,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -1568,16 +1568,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -1585,8 +1585,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -1604,12 +1604,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -1626,7 +1626,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -1641,8 +1641,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -1677,12 +1677,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -1693,8 +1693,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -1726,12 +1726,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -1742,7 +1742,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_512.snap b/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_512.snap index 9a1addab0..d22257bb7 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_512.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_512.snap @@ -1515,7 +1515,7 @@ download_binary_and_run_installer "$@" || exit 1 # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -1533,10 +1533,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -1554,7 +1554,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -1568,16 +1568,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -1585,8 +1585,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -1604,12 +1604,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -1626,7 +1626,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -1641,8 +1641,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -1677,12 +1677,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -1693,8 +1693,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -1726,12 +1726,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -1742,7 +1742,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_custom_formula.snap b/cargo-dist/tests/snapshots/axolotlsay_custom_formula.snap index 8b7916f4a..7bcade56a 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_custom_formula.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_custom_formula.snap @@ -380,7 +380,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -403,7 +403,7 @@ concurrency: group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -417,16 +417,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -434,8 +434,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && 'host --steps=create --tag=timestamp --force-tag') || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && 'host --steps=create --tag=timestamp --force-tag') || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" echo "tag=$(jq --raw-output ".announcement_tag" plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" @@ -455,12 +455,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -481,7 +481,7 @@ jobs: with: key: ${{ join(matrix.targets, '-') }} cache-provider: ${{ matrix.cache_provider }} - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -496,8 +496,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -532,12 +532,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -548,8 +548,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -581,12 +581,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -597,7 +597,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_custom_github_runners.snap b/cargo-dist/tests/snapshots/axolotlsay_custom_github_runners.snap index 9e2981376..3329be416 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_custom_github_runners.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_custom_github_runners.snap @@ -304,7 +304,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -322,10 +322,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -343,7 +343,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "buildjet-8vcpu-ubuntu-2204" outputs: @@ -357,16 +357,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -374,8 +374,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -393,12 +393,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -415,7 +415,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -430,8 +430,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -466,12 +466,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -482,8 +482,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -515,12 +515,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -531,7 +531,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_disable_source_tarball.snap b/cargo-dist/tests/snapshots/axolotlsay_disable_source_tarball.snap index 06cbc8494..7bcbe24b0 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_disable_source_tarball.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_disable_source_tarball.snap @@ -3690,7 +3690,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3708,10 +3708,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3729,7 +3729,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3743,16 +3743,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3760,8 +3760,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3779,12 +3779,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3801,7 +3801,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3816,8 +3816,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3852,12 +3852,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3868,8 +3868,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3901,12 +3901,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3917,7 +3917,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_dispatch.snap b/cargo-dist/tests/snapshots/axolotlsay_dispatch.snap index fcad906bf..43debd78d 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_dispatch.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_dispatch.snap @@ -302,7 +302,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -320,10 +320,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -345,7 +345,7 @@ on: type: string jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -359,16 +359,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -376,8 +376,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (inputs.tag && inputs.tag != 'dry-run' && format('host --steps=create --tag={0}', inputs.tag)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (inputs.tag && inputs.tag != 'dry-run' && format('host --steps=create --tag={0}', inputs.tag)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -395,12 +395,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') || inputs.tag == 'dry-run' }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -417,7 +417,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -432,8 +432,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -468,12 +468,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -484,8 +484,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -517,12 +517,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -533,7 +533,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss.snap b/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss.snap index f88b19e14..0bc0f60f4 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss.snap @@ -310,7 +310,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to Axo Releases and makes an Announcement # * on success, uploads the artifacts to a GitHub Release @@ -329,10 +329,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -354,7 +354,7 @@ on: type: string jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -369,16 +369,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -386,8 +386,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (inputs.tag && inputs.tag != 'dry-run' && format('host --steps=create --tag={0}', inputs.tag)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (inputs.tag && inputs.tag != 'dry-run' && format('host --steps=create --tag={0}', inputs.tag)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -405,12 +405,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') || inputs.tag == 'dry-run' }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -427,7 +427,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -442,8 +442,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -478,12 +478,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -494,8 +494,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -537,12 +537,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -555,7 +555,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" @@ -584,12 +584,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist - name: Fetch Axo Artifacts uses: actions/download-artifact@v4 with: @@ -598,7 +598,7 @@ jobs: merge-multiple: true - name: Announce Axo Releases run: | - cargo dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} + dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} # Create a GitHub Release while uploading all files to it - name: "Download GitHub Artifacts" uses: actions/download-artifact@v4 diff --git a/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss_only.snap b/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss_only.snap index 40396e57f..c548cffe9 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss_only.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss_only.snap @@ -304,7 +304,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to Axo Releases and makes an Announcement @@ -319,10 +319,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -344,7 +344,7 @@ on: type: string jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -359,16 +359,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -376,8 +376,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (inputs.tag && inputs.tag != 'dry-run' && format('host --steps=create --tag={0}', inputs.tag)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (inputs.tag && inputs.tag != 'dry-run' && format('host --steps=create --tag={0}', inputs.tag)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -395,12 +395,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') || inputs.tag == 'dry-run' }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -417,7 +417,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -432,8 +432,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -468,12 +468,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -484,8 +484,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -527,12 +527,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -544,7 +544,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" @@ -572,12 +572,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist - name: Fetch Axo Artifacts uses: actions/download-artifact@v4 with: @@ -586,4 +586,4 @@ jobs: merge-multiple: true - name: Announce Axo Releases run: | - cargo dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} + dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} diff --git a/cargo-dist/tests/snapshots/axolotlsay_edit_existing.snap b/cargo-dist/tests/snapshots/axolotlsay_edit_existing.snap index b24722a46..fd983bc0d 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_edit_existing.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_edit_existing.snap @@ -3624,7 +3624,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3642,10 +3642,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3663,7 +3663,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3677,16 +3677,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3694,8 +3694,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3713,12 +3713,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3735,7 +3735,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3750,8 +3750,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3786,12 +3786,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3802,8 +3802,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3835,12 +3835,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3851,7 +3851,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_generic_workspace_basic.snap b/cargo-dist/tests/snapshots/axolotlsay_generic_workspace_basic.snap index 687321aeb..485161f7c 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_generic_workspace_basic.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_generic_workspace_basic.snap @@ -4111,7 +4111,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -4129,10 +4129,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -4150,7 +4150,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -4164,16 +4164,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -4181,8 +4181,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -4200,12 +4200,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -4226,7 +4226,7 @@ jobs: with: key: ${{ join(matrix.targets, '-') }} cache-provider: ${{ matrix.cache_provider }} - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -4241,8 +4241,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -4277,12 +4277,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -4293,8 +4293,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -4326,12 +4326,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -4342,7 +4342,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_homebrew_packages.snap b/cargo-dist/tests/snapshots/axolotlsay_homebrew_packages.snap index 201a13915..d0682dc2a 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_homebrew_packages.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_homebrew_packages.snap @@ -3704,7 +3704,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3722,10 +3722,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3743,7 +3743,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3757,16 +3757,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3774,8 +3774,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3793,12 +3793,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3815,7 +3815,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3830,8 +3830,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3866,12 +3866,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3882,8 +3882,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3915,12 +3915,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3931,7 +3931,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_musl.snap b/cargo-dist/tests/snapshots/axolotlsay_musl.snap index 030d6fdc0..d3a564c8e 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_musl.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_musl.snap @@ -3030,7 +3030,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3048,10 +3048,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3069,7 +3069,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3083,16 +3083,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3100,8 +3100,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3119,12 +3119,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3141,7 +3141,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3156,8 +3156,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3192,12 +3192,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3208,8 +3208,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3241,12 +3241,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3257,7 +3257,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_musl_no_gnu.snap b/cargo-dist/tests/snapshots/axolotlsay_musl_no_gnu.snap index fd04dc906..7a8d29caa 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_musl_no_gnu.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_musl_no_gnu.snap @@ -2956,7 +2956,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -2974,10 +2974,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -2995,7 +2995,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3009,16 +3009,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3026,8 +3026,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3045,12 +3045,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3067,7 +3067,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3082,8 +3082,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3118,12 +3118,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3134,8 +3134,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3167,12 +3167,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3183,7 +3183,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_no_homebrew_publish.snap b/cargo-dist/tests/snapshots/axolotlsay_no_homebrew_publish.snap index b0180b255..3575a682c 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_no_homebrew_publish.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_no_homebrew_publish.snap @@ -3624,7 +3624,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3642,10 +3642,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3663,7 +3663,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3677,16 +3677,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3694,8 +3694,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3713,12 +3713,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3739,7 +3739,7 @@ jobs: with: key: ${{ join(matrix.targets, '-') }} cache-provider: ${{ matrix.cache_provider }} - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3754,8 +3754,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3790,12 +3790,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3806,8 +3806,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3839,12 +3839,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3855,7 +3855,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_no_locals.snap b/cargo-dist/tests/snapshots/axolotlsay_no_locals.snap index a21718d64..0daedb87b 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_no_locals.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_no_locals.snap @@ -302,7 +302,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -320,10 +320,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -341,7 +341,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -355,16 +355,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -372,8 +372,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -394,12 +394,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -410,8 +410,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -442,12 +442,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -458,7 +458,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_no_locals_but_custom.snap b/cargo-dist/tests/snapshots/axolotlsay_no_locals_but_custom.snap index b1f3e835b..67e62084f 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_no_locals_but_custom.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_no_locals_but_custom.snap @@ -302,7 +302,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -325,7 +325,7 @@ concurrency: group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -339,16 +339,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -356,8 +356,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && 'host --steps=create --tag=timestamp --force-tag') || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && 'host --steps=create --tag=timestamp --force-tag') || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" echo "tag=$(jq --raw-output ".announcement_tag" plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" @@ -392,12 +392,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -408,8 +408,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -441,12 +441,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -457,7 +457,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_several_aliases.snap b/cargo-dist/tests/snapshots/axolotlsay_several_aliases.snap index ea5995222..52ff4b256 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_several_aliases.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_several_aliases.snap @@ -3740,7 +3740,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3758,10 +3758,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3779,7 +3779,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3793,16 +3793,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3810,8 +3810,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3829,12 +3829,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3851,7 +3851,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3866,8 +3866,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3902,12 +3902,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3918,8 +3918,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3951,12 +3951,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3967,7 +3967,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign.snap b/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign.snap index b5bf710d0..abc88848b 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign.snap @@ -2114,7 +2114,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -2132,10 +2132,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -2153,7 +2153,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -2167,16 +2167,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -2184,8 +2184,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -2203,12 +2203,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -2229,7 +2229,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -2244,8 +2244,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -2280,12 +2280,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -2296,8 +2296,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -2329,12 +2329,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -2345,7 +2345,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign_prod.snap b/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign_prod.snap index b5bf710d0..abc88848b 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign_prod.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign_prod.snap @@ -2114,7 +2114,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -2132,10 +2132,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -2153,7 +2153,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -2167,16 +2167,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -2184,8 +2184,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -2203,12 +2203,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -2229,7 +2229,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -2244,8 +2244,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -2280,12 +2280,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -2296,8 +2296,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -2329,12 +2329,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -2345,7 +2345,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_tag_namespace.snap b/cargo-dist/tests/snapshots/axolotlsay_tag_namespace.snap index 0782e527c..194b66355 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_tag_namespace.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_tag_namespace.snap @@ -302,7 +302,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -320,10 +320,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -341,7 +341,7 @@ on: - 'owo**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -355,16 +355,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -372,8 +372,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -391,12 +391,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -413,7 +413,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -428,8 +428,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -464,12 +464,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -480,8 +480,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -513,12 +513,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -529,7 +529,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_updaters.snap b/cargo-dist/tests/snapshots/axolotlsay_updaters.snap index 922389429..d22bf0c60 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_updaters.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_updaters.snap @@ -3742,7 +3742,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3760,10 +3760,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3781,7 +3781,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3795,16 +3795,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3812,8 +3812,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3831,12 +3831,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3853,7 +3853,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3868,8 +3868,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3904,12 +3904,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3920,8 +3920,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3953,12 +3953,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3969,7 +3969,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_global_build_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_global_build_job.snap index 3409d724f..e011e82dd 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_global_build_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_global_build_job.snap @@ -3624,7 +3624,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3642,10 +3642,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3663,7 +3663,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3677,16 +3677,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3694,8 +3694,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3713,12 +3713,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3735,7 +3735,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3750,8 +3750,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3786,12 +3786,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3802,8 +3802,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3855,12 +3855,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3871,7 +3871,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_host_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_host_job.snap index f4ae6bdc3..347470d91 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_host_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_host_job.snap @@ -3624,7 +3624,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3642,10 +3642,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3663,7 +3663,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3677,16 +3677,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3694,8 +3694,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3713,12 +3713,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3735,7 +3735,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3750,8 +3750,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3786,12 +3786,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3802,8 +3802,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3835,12 +3835,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3851,7 +3851,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_local_build_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_local_build_job.snap index a3ebcb808..be5530167 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_local_build_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_local_build_job.snap @@ -3624,7 +3624,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3642,10 +3642,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3663,7 +3663,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3677,16 +3677,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3694,8 +3694,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3713,12 +3713,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3735,7 +3735,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3750,8 +3750,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3806,12 +3806,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3822,8 +3822,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3857,12 +3857,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3873,7 +3873,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_plan_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_plan_job.snap index 6f18d1231..e81ce0254 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_plan_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_plan_job.snap @@ -3624,7 +3624,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3642,10 +3642,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3663,7 +3663,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3677,16 +3677,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3694,8 +3694,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3723,12 +3723,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3749,7 +3749,7 @@ jobs: with: key: ${{ join(matrix.targets, '-') }} cache-provider: ${{ matrix.cache_provider }} - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3764,8 +3764,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3800,12 +3800,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3816,8 +3816,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3849,12 +3849,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3865,7 +3865,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_publish_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_publish_job.snap index f764ce8be..6782a5a21 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_publish_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_publish_job.snap @@ -3624,7 +3624,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to a GitHub Release # @@ -3642,10 +3642,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -3663,7 +3663,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -3677,16 +3677,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/vSOME_VERSION/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -3694,8 +3694,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -3713,12 +3713,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -3735,7 +3735,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -3750,8 +3750,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - id: cargo-dist name: Post-build # We force bash here just because github makes it really hard to get values up @@ -3786,12 +3786,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -3802,8 +3802,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -3835,12 +3835,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -3851,7 +3851,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" diff --git a/cargo-dist/tests/snapshots/manifest.snap b/cargo-dist/tests/snapshots/manifest.snap index 02b60721a..b00e5ae95 100644 --- a/cargo-dist/tests/snapshots/manifest.snap +++ b/cargo-dist/tests/snapshots/manifest.snap @@ -93,9 +93,9 @@ stdout: "kind": "readme" }, { - "id": "cargo-dist-aarch64-apple-darwin-exe-cargo-dist", - "name": "cargo-dist", - "path": "cargo-dist", + "id": "cargo-dist-aarch64-apple-darwin-exe-dist", + "name": "dist", + "path": "dist", "kind": "executable" } ], @@ -136,9 +136,9 @@ stdout: "kind": "readme" }, { - "id": "cargo-dist-aarch64-unknown-linux-gnu-exe-cargo-dist", - "name": "cargo-dist", - "path": "cargo-dist", + "id": "cargo-dist-aarch64-unknown-linux-gnu-exe-dist", + "name": "dist", + "path": "dist", "kind": "executable" } ], @@ -179,9 +179,9 @@ stdout: "kind": "readme" }, { - "id": "cargo-dist-aarch64-unknown-linux-musl-exe-cargo-dist", - "name": "cargo-dist", - "path": "cargo-dist", + "id": "cargo-dist-aarch64-unknown-linux-musl-exe-dist", + "name": "dist", + "path": "dist", "kind": "executable" } ], @@ -325,9 +325,9 @@ stdout: "kind": "readme" }, { - "id": "cargo-dist-x86_64-apple-darwin-exe-cargo-dist", - "name": "cargo-dist", - "path": "cargo-dist", + "id": "cargo-dist-x86_64-apple-darwin-exe-dist", + "name": "dist", + "path": "dist", "kind": "executable" } ], @@ -368,9 +368,9 @@ stdout: "kind": "readme" }, { - "id": "cargo-dist-x86_64-pc-windows-msvc-exe-cargo-dist", - "name": "cargo-dist", - "path": "cargo-dist.exe", + "id": "cargo-dist-x86_64-pc-windows-msvc-exe-dist", + "name": "dist", + "path": "dist.exe", "kind": "executable" } ], @@ -411,9 +411,9 @@ stdout: "kind": "readme" }, { - "id": "cargo-dist-x86_64-unknown-linux-gnu-exe-cargo-dist", - "name": "cargo-dist", - "path": "cargo-dist", + "id": "cargo-dist-x86_64-unknown-linux-gnu-exe-dist", + "name": "dist", + "path": "dist", "kind": "executable" } ], @@ -454,9 +454,9 @@ stdout: "kind": "readme" }, { - "id": "cargo-dist-x86_64-unknown-linux-musl-exe-cargo-dist", - "name": "cargo-dist", - "path": "cargo-dist", + "id": "cargo-dist-x86_64-unknown-linux-musl-exe-dist", + "name": "dist", + "path": "dist", "kind": "executable" } ], diff --git a/dist-workspace.toml b/dist-workspace.toml index a54ea87f6..723c9db5b 100644 --- a/dist-workspace.toml +++ b/dist-workspace.toml @@ -35,3 +35,6 @@ build = ["cargo", "run", "--release", "--", "dist", "manifest-schema", "--output [dist.github-custom-runners] aarch64-unknown-linux-gnu = "buildjet-8vcpu-ubuntu-2204-arm" aarch64-unknown-linux-musl = "buildjet-8vcpu-ubuntu-2204-arm" + +[dist.bin-aliases] +"dist" = ["cargo-dist"] From 4617bbcdeadfa417ce4393728ea1282643077743 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Mon, 21 Oct 2024 15:34:32 -0700 Subject: [PATCH 05/15] chore: improve messaging with missing cargo --- axoproject/src/errors.rs | 5 +++++ axoproject/src/rust.rs | 14 +++++++++++--- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/axoproject/src/errors.rs b/axoproject/src/errors.rs index d46cd56c4..01bf9cb50 100644 --- a/axoproject/src/errors.rs +++ b/axoproject/src/errors.rs @@ -138,6 +138,11 @@ pub enum AxoprojectError { /// Version we were looking for version: Version, }, + + /// We couldn't parse a workspace because there's no Cargo + #[error("Your app has a Cargo.toml, but you don't appear to have cargo installed.")] + #[diagnostic(help("Is cargo in your PATH? You can install cargo via: https://rustup.rs"))] + CargoMissing {}, } /// Errors related to finding the project diff --git a/axoproject/src/rust.rs b/axoproject/src/rust.rs index 472485e52..393f699bc 100644 --- a/axoproject/src/rust.rs +++ b/axoproject/src/rust.rs @@ -14,7 +14,6 @@ use guppy::{ use itertools::{concat, Itertools}; pub use axoasset::toml_edit::DocumentMut; -use tracing::warn; /// All the `[profile]` entries we found in the root Cargo.toml pub type CargoProfiles = BTreeMap; @@ -41,8 +40,17 @@ pub fn get_workspace(start_dir: &Utf8Path, clamp_to_dir: Option<&Utf8Path>) -> W let graph = match package_graph(start_dir) { Ok(graph) => graph, Err(e) => { - warn!("Unable to calculate cargo workspaces; is cargo missing?"); - return WorkspaceSearch::Missing(e); + let error = match e { + // Indicates we failed to run `cargo metadata`; this is the + // one we want to intercept and replace with a friendlier error. + crate::AxoprojectError::CargoMetadata(guppy::Error::CommandError(_)) => { + crate::AxoprojectError::CargoMissing {} + } + // Any other errors are less expected, and we should pass + // those through unaltered. + _ => e, + }; + return WorkspaceSearch::Missing(error); } }; From 2fe0c4ebec66b8f431a30389c2dcec52bb8f20aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Tue, 22 Oct 2024 15:47:53 -0700 Subject: [PATCH 06/15] release: 0.24.0-prerelease.1 --- Cargo.lock | 6 +++--- Cargo.toml | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 3e0f7b2d7..981814ad1 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -187,7 +187,7 @@ dependencies = [ [[package]] name = "axoproject" -version = "0.23.0" +version = "0.24.0-prerelease.1" dependencies = [ "axoasset", "axoprocess", @@ -377,7 +377,7 @@ dependencies = [ [[package]] name = "cargo-dist" -version = "0.23.0" +version = "0.24.0-prerelease.1" dependencies = [ "axoasset", "axocli", @@ -426,7 +426,7 @@ dependencies = [ [[package]] name = "cargo-dist-schema" -version = "0.23.0" +version = "0.24.0-prerelease.1" dependencies = [ "camino", "gazenot", diff --git a/Cargo.toml b/Cargo.toml index cb571f13e..6531da3ad 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -12,12 +12,12 @@ edition = "2021" license = "MIT OR Apache-2.0" repository = "https://github.com/axodotdev/cargo-dist" homepage = "https://opensource.axo.dev/cargo-dist/" -version = "0.23.0" +version = "0.24.0-prerelease.1" [workspace.dependencies] # intra-workspace deps (you need to bump these versions when you cut releases too! -cargo-dist-schema = { version = "=0.23.0", path = "cargo-dist-schema" } -axoproject = { version = "=0.23.0", path = "axoproject", default-features = false, features = ["cargo-projects", "generic-projects", "npm-projects"] } +cargo-dist-schema = { version = "=0.24.0-prerelease.1", path = "cargo-dist-schema" } +axoproject = { version = "=0.24.0-prerelease.1", path = "axoproject", default-features = false, features = ["cargo-projects", "generic-projects", "npm-projects"] } # first-party deps axocli = { version = "0.2.0" } From 6278e93d08594a27204333f44b452cae1f473d2c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Tue, 22 Oct 2024 17:30:45 -0700 Subject: [PATCH 07/15] chore: update own cargo-dist --- .github/workflows/release.yml | 52 +++++++++++++++++------------------ dist-workspace.toml | 4 +-- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f44301b35..d84b22999 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -6,7 +6,7 @@ # CI that: # # * checks for a Git Tag that looks like a release -# * builds artifacts with cargo-dist (archives, installers, hashes) +# * builds artifacts with dist (archives, installers, hashes) # * uploads those artifacts to temporary workflow zip # * on success, uploads the artifacts to Axo Releases and makes an Announcement # * on success, uploads the artifacts to a GitHub Release @@ -27,10 +27,10 @@ permissions: # must be a Cargo-style SemVer Version (must have at least major.minor.patch). # # If PACKAGE_NAME is specified, then the announcement will be for that -# package (erroring out if it doesn't have the given version or isn't cargo-dist-able). +# package (erroring out if it doesn't have the given version or isn't dist-able). # # If PACKAGE_NAME isn't specified, then the announcement will be for all -# (cargo-dist-able) packages in the workspace with that version (this mode is +# (dist-able) packages in the workspace with that version (this mode is # intended for workspaces with only one dist-able package, or with all dist-able # packages versioned/released in lockstep). # @@ -48,7 +48,7 @@ on: - '**[0-9]+.[0-9]+.[0-9]+*' jobs: - # Run 'cargo dist plan' (or host) to determine what tasks we need to do + # Run 'dist plan' (or host) to determine what tasks we need to do plan: runs-on: "ubuntu-20.04" outputs: @@ -63,16 +63,16 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash - run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.23.0/cargo-dist-installer.sh | sh" - - name: Cache cargo-dist + run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.24.0-prerelease.1/cargo-dist-installer.sh | sh" + - name: Cache dist uses: actions/upload-artifact@v4 with: name: cargo-dist-cache - path: ~/.cargo/bin/cargo-dist + path: ~/.cargo/bin/dist # sure would be cool if github gave us proper conditionals... # so here's a doubly-nested ternary-via-truthiness to try to provide the best possible # functionality based on whether this is a pull_request, and whether it's from a fork. @@ -80,8 +80,8 @@ jobs: # but also really annoying to build CI around when it needs secrets to work right.) - id: plan run: | - cargo dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json - echo "cargo dist ran successfully" + dist ${{ (!github.event.pull_request && format('host --steps=create --tag={0}', github.ref_name)) || (env.AXO_RELEASES_TOKEN && 'host --steps=check') || 'plan' }} --output-format=json > plan-dist-manifest.json + echo "dist ran successfully" cat plan-dist-manifest.json echo "manifest=$(jq -c "." plan-dist-manifest.json)" >> "$GITHUB_OUTPUT" - name: "Upload dist-manifest.json" @@ -99,12 +99,12 @@ jobs: if: ${{ fromJson(needs.plan.outputs.val).ci.github.artifacts_matrix.include != null && (needs.plan.outputs.publishing == 'true' || fromJson(needs.plan.outputs.val).ci.github.pr_run_mode == 'upload') }} strategy: fail-fast: false - # Target platforms/runners are computed by cargo-dist in create-release. + # Target platforms/runners are computed by dist in create-release. # Each member of the matrix has the following arguments: # # - runner: the github runner - # - dist-args: cli flags to pass to cargo dist - # - install-dist: expression to run to install cargo-dist on the runner + # - dist-args: cli flags to pass to dist + # - install-dist: expression to run to install dist on the runner # # Typically there will be: # - 1 "global" task that builds universal installers @@ -121,7 +121,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cargo-dist + - name: Install dist run: ${{ matrix.install_dist }} # Get the dist-manifest - name: Fetch local artifacts @@ -136,8 +136,8 @@ jobs: - name: Build artifacts run: | # Actually do builds and make zips and whatnot - cargo dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json + echo "dist ran successfully" - name: Attest uses: actions/attest-build-provenance@v1 with: @@ -176,12 +176,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Get all the local artifacts for the global tasks to use (for e.g. checksums) - name: Fetch local artifacts uses: actions/download-artifact@v4 @@ -192,8 +192,8 @@ jobs: - id: cargo-dist shell: bash run: | - cargo dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json - echo "cargo dist ran successfully" + dist build ${{ needs.plan.outputs.tag-flag }} --output-format=json "--artifacts=global" > dist-manifest.json + echo "dist ran successfully" # Parse out what we just built and upload it to scratch storage echo "paths<> "$GITHUB_OUTPUT" @@ -235,12 +235,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist # Fetch artifacts from scratch-storage - name: Fetch artifacts uses: actions/download-artifact@v4 @@ -253,7 +253,7 @@ jobs: - id: host shell: bash run: | - cargo dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json + dist host ${{ needs.plan.outputs.tag-flag }} --steps=upload --steps=release --output-format=json > dist-manifest.json echo "artifacts uploaded and released successfully" cat dist-manifest.json echo "manifest=$(jq -c "." dist-manifest.json)" >> "$GITHUB_OUTPUT" @@ -372,12 +372,12 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - name: Install cached cargo-dist + - name: Install cached dist uses: actions/download-artifact@v4 with: name: cargo-dist-cache path: ~/.cargo/bin/ - - run: chmod +x ~/.cargo/bin/cargo-dist + - run: chmod +x ~/.cargo/bin/dist - name: Fetch Axo Artifacts uses: actions/download-artifact@v4 with: @@ -386,7 +386,7 @@ jobs: merge-multiple: true - name: Announce Axo Releases run: | - cargo dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} + dist host --steps=announce ${{ needs.plan.outputs.tag-flag }} # Create a GitHub Release while uploading all files to it - name: "Download GitHub Artifacts" uses: actions/download-artifact@v4 diff --git a/dist-workspace.toml b/dist-workspace.toml index 723c9db5b..151f4527e 100644 --- a/dist-workspace.toml +++ b/dist-workspace.toml @@ -4,11 +4,11 @@ members = ["cargo:."] # Config for 'cargo dist' [dist] # The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) -cargo-dist-version = "0.23.0" +cargo-dist-version = "0.24.0-prerelease.1" # CI backends to support ci = "github" # The installers to generate for each app -installers = ["shell", "powershell", "homebrew", "npm"] +installers = ["shell", "powershell", "npm", "homebrew"] # A GitHub repo to push Homebrew formulas to tap = "axodotdev/homebrew-tap" # A namespace to use when publishing this package to the npm registry From 9019b7d529ec922de3b34579285eb5cb59051a4a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Wed, 23 Oct 2024 10:18:39 -0700 Subject: [PATCH 08/15] chore: internal dist rename --- .github/workflows/publish-crates.yml | 2 +- .github/workflows/web.yml | 6 ++-- README.md | 26 ++++++++--------- axoproject/README.md | 2 +- axoproject/src/generic.rs | 2 +- axoproject/src/lib.rs | 4 +-- cargo-dist-schema/README.md | 14 +++++----- cargo-dist-schema/src/lib.rs | 16 +++++------ .../snapshots/cargo_dist_schema__emit.snap | 10 +++---- cargo-dist/src/announce.rs | 14 +++++----- cargo-dist/src/backend/ci/github.rs | 10 +++---- cargo-dist/src/backend/ci/mod.rs | 12 ++++---- cargo-dist/src/backend/installer/msi.rs | 2 +- cargo-dist/src/backend/mod.rs | 2 +- cargo-dist/src/build/cargo.rs | 2 +- cargo-dist/src/cli.rs | 20 ++++++------- cargo-dist/src/config/mod.rs | 4 +-- cargo-dist/src/config/v0.rs | 28 +++++++++---------- cargo-dist/src/config/v1/builds/cargo.rs | 14 +++++----- cargo-dist/src/config/v1/ci/mod.rs | 6 ++-- cargo-dist/src/config/v1/hosts/github.rs | 4 +-- cargo-dist/src/config/v1/hosts/mod.rs | 2 +- cargo-dist/src/config/v1/mod.rs | 24 ++++++++-------- cargo-dist/src/errors.rs | 26 +++++++---------- cargo-dist/src/host.rs | 2 +- cargo-dist/src/init.rs | 22 +++++++-------- cargo-dist/src/lib.rs | 4 +-- cargo-dist/src/main.rs | 8 +++--- cargo-dist/src/platform.rs | 6 ++-- cargo-dist/src/tasks.rs | 14 +++++----- cargo-dist/src/tests/config.rs | 10 +++---- cargo-dist/templates/ci/github/release.yml.j2 | 2 +- .../templates/installer/installer.ps1.j2 | 2 +- cargo-dist/tests/gallery/dist.rs | 4 +-- cargo-dist/tests/gallery/dist/tools.rs | 8 ++---- .../tests/snapshots/akaikatana_basic.snap | 4 +-- .../tests/snapshots/akaikatana_musl.snap | 2 +- ...ikatana_one_alias_among_many_binaries.snap | 4 +-- .../snapshots/akaikatana_two_bin_aliases.snap | 4 +-- .../tests/snapshots/akaikatana_updaters.snap | 4 +-- .../tests/snapshots/axolotlsay_abyss.snap | 4 +-- .../snapshots/axolotlsay_abyss_only.snap | 4 +-- .../tests/snapshots/axolotlsay_alias.snap | 4 +-- ...axolotlsay_alias_ignores_missing_bins.snap | 4 +-- .../tests/snapshots/axolotlsay_basic.snap | 4 +-- .../snapshots/axolotlsay_basic_lies.snap | 4 +-- .../axolotlsay_build_setup_steps.snap | 4 +-- .../axolotlsay_checksum_blake2b.snap | 2 +- .../axolotlsay_checksum_blake2s.snap | 2 +- .../axolotlsay_checksum_sha3_256.snap | 2 +- .../axolotlsay_checksum_sha3_512.snap | 2 +- .../snapshots/axolotlsay_custom_formula.snap | 2 +- .../axolotlsay_custom_github_runners.snap | 2 +- .../axolotlsay_disable_source_tarball.snap | 4 +-- .../tests/snapshots/axolotlsay_dispatch.snap | 2 +- .../snapshots/axolotlsay_dispatch_abyss.snap | 2 +- .../axolotlsay_dispatch_abyss_only.snap | 2 +- .../snapshots/axolotlsay_edit_existing.snap | 4 +-- .../axolotlsay_generic_workspace_basic.snap | 6 ++-- .../axolotlsay_homebrew_packages.snap | 4 +-- .../tests/snapshots/axolotlsay_musl.snap | 2 +- .../snapshots/axolotlsay_musl_no_gnu.snap | 2 +- .../axolotlsay_no_homebrew_publish.snap | 4 +-- .../tests/snapshots/axolotlsay_no_locals.snap | 2 +- .../axolotlsay_no_locals_but_custom.snap | 2 +- .../snapshots/axolotlsay_several_aliases.snap | 4 +-- .../axolotlsay_ssldotcom_windows_sign.snap | 4 +-- ...xolotlsay_ssldotcom_windows_sign_prod.snap | 4 +-- .../snapshots/axolotlsay_tag_namespace.snap | 2 +- .../tests/snapshots/axolotlsay_updaters.snap | 4 +-- .../axolotlsay_user_global_build_job.snap | 4 +-- .../snapshots/axolotlsay_user_host_job.snap | 4 +-- .../axolotlsay_user_local_build_job.snap | 4 +-- .../snapshots/axolotlsay_user_plan_job.snap | 4 +-- .../axolotlsay_user_publish_job.snap | 4 +-- .../tests/snapshots/error_manifest.snap | 4 +-- .../snapshots/install_path_cargo_home.snap | 2 +- .../snapshots/install_path_env_no_subdir.snap | 2 +- .../snapshots/install_path_env_subdir.snap | 2 +- .../install_path_env_subdir_space.snap | 2 +- .../install_path_env_subdir_space_deeper.snap | 2 +- .../install_path_fallback_no_env_var_set.snap | 2 +- .../install_path_home_subdir_deeper.snap | 2 +- .../install_path_home_subdir_min.snap | 2 +- .../install_path_home_subdir_space.snap | 2 +- ...install_path_home_subdir_space_deeper.snap | 2 +- .../install_path_no_fallback_taken.snap | 2 +- cargo-dist/tests/snapshots/long-help.snap | 4 +-- cargo-dist/tests/snapshots/markdown-help.snap | 20 ++++++------- cargo-dist/tests/snapshots/short-help.snap | 4 +-- 90 files changed, 256 insertions(+), 264 deletions(-) diff --git a/.github/workflows/publish-crates.yml b/.github/workflows/publish-crates.yml index 49f5e524a..00efbecbe 100644 --- a/.github/workflows/publish-crates.yml +++ b/.github/workflows/publish-crates.yml @@ -1,6 +1,6 @@ # Publishes our workspace's crates to crates.io # -# This is triggered automatically by cargo-dist during the publish step +# This is triggered automatically by dist during the publish step # (this is a custom publish job: https://opensource.axo.dev/cargo-dist/book/ci/customizing.html#custom-jobs) # # It is assumed that all crates are versioned and released in lockstep, diff --git a/.github/workflows/web.yml b/.github/workflows/web.yml index 6d1b24321..817b0ed5e 100644 --- a/.github/workflows/web.yml +++ b/.github/workflows/web.yml @@ -20,12 +20,12 @@ on: # Whenever something gets pushed to main, update the docs! # This is great for getting docs changes live without cutting a full release. # - # Note that if you're using cargo-dist, this will "race" the Release workflow + # Note that if you're using dist, this will "race" the Release workflow # that actually builds the Github Release that oranda tries to read (and # this will almost certainly complete first). As a result you will publish # docs for the latest commit but the oranda landing page won't know about # the latest release. The workflow_run trigger below will properly wait for - # cargo-dist, and so this half-published state will only last for ~10 minutes. + # dist, and so this half-published state will only last for ~10 minutes. # # If you only want docs to update with releases, disable this one. push: @@ -34,7 +34,7 @@ on: # Whenever a workflow called "Release" completes, update the docs! # - # If you're using cargo-dist, this is recommended, as it will ensure that + # If you're using dist, this is recommended, as it will ensure that # oranda always sees the latest release right when it's available. Note # however that Github's UI is wonky when you use workflow_run, and won't # show this workflow as part of any commit. You have to go to the "actions" diff --git a/README.md b/README.md index 8bae6815b..3ba059a80 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@
-# `cargo-dist` +# `dist`
@@ -8,9 +8,9 @@ [![docs](https://docs.rs/cargo-dist/badge.svg)](https://docs.rs/cargo-dist) [![Rust CI](https://github.com/axodotdev/cargo-dist/workflows/Rust%20CI/badge.svg?branch=main)](https://github.com/axodotdev/cargo-dist/actions/workflows/ci.yml) -*cargo-dist distributes your binaries* +*dist distributes your binaries* -The TL;DR is that with cargo-dist set up, just doing this: +The TL;DR is that with dist set up, just doing this: ```sh git commit -am "release: 0.2.0" @@ -28,7 +28,7 @@ Or if you're using [oranda](https://opensource.axo.dev/oranda/), you'll get [thi Cutting releases of your apps and distributing binaries for them has a lot of steps, and cargo-dist is quickly growing to try to cover them all! -To accomplish this, cargo-dist functionality can be broken up into two parts: +To accomplish this, dist functionality can be broken up into two parts: * building (**planning** the release; **building** binaries and installers) * distributing (**hosting** artifacts; **publishing** packages; **announcing** releases) @@ -38,7 +38,7 @@ The build functionality can be used on its own if you just want some tarballs an ## Building -As a build tool, cargo-dist can do the following: +As a build tool, dist can do the following: * Pick good build flags for "shippable binaries" * Make [tarballs][] and [installers][] for the resulting binaries @@ -49,7 +49,7 @@ That's a short list because "we make [installers][]" is doing a lot of heavy lif ## Distributing -As a distribution tool, cargo-dist gets to flex its biggest superpower: **it generates [its own CI scripts][ci-providers]**. For instance, enabling [GitHub CI][ci-providers] with `cargo dist init` will generate release.yml, which implements the full pipeline of plan, build, host, publish, announce: +As a distribution tool, dist gets to flex its biggest superpower: **it generates [its own CI scripts][ci-providers]**. For instance, enabling [GitHub CI][ci-providers] with `cargo dist init` will generate release.yml, which implements the full pipeline of plan, build, host, publish, announce: * Plan * Waits for you to push a git tag for a new version (v1.0.0, my-app-v1.0.0, my-app/1.0.0, ...) @@ -73,7 +73,7 @@ As a distribution tool, cargo-dist gets to flex its biggest superpower: **it gen # Read The Book! -We've got all the docs you need over at the [cargo-dist book](https://axodotdev.github.io/cargo-dist/book/)! +We've got all the docs you need over at the [dist book](https://axodotdev.github.io/cargo-dist/book/)! * [Introduction](https://opensource.axo.dev/cargo-dist/book/introduction.html) * [Install](https://opensource.axo.dev/cargo-dist/book/install.html) @@ -87,7 +87,7 @@ We've got all the docs you need over at the [cargo-dist book](https://axodotdev. ## Updating Snapshots -cargo-dist's tests rely on [cargo-insta](https://crates.io/crates/cargo-insta) for snapshot testing various +dist's tests rely on [cargo-insta](https://crates.io/crates/cargo-insta) for snapshot testing various outputs. This allows us to both catch regressions and also more easily review UI/output changes. If a snapshot test fails, you will need to use the `cargo insta` CLI tool to update them: @@ -109,7 +109,7 @@ If you know you like the changes, just use `cargo insta accept` to auto-apply al ## Cutting Releases -cargo-dist is self-hosting, so you just need to push a git-tag with the right format to "do" a release. Of course there's lots of other tedious tasks that come with updating a release, and we use cargo-release to handle all those mechanical details of updating versions/headings/tags. See [these sections of the docs for the release workflow we use](https://opensource.axo.dev/cargo-dist/book/workspaces/cargo-release-guide.html#using-cargo-release-with-pull-requests). +dist is self-hosting, so you just need to push a git-tag with the right format to "do" a release. Of course there's lots of other tedious tasks that come with updating a release, and we use cargo-release to handle all those mechanical details of updating versions/headings/tags. See [these sections of the docs for the release workflow we use](https://opensource.axo.dev/cargo-dist/book/workspaces/cargo-release-guide.html#using-cargo-release-with-pull-requests). TL;DR: @@ -117,15 +117,15 @@ TL;DR: * run cargo-release as described in the docs * ..you're done! -Note that we've wired up cargo-dist and cargo-release to understand the "Unreleased" heading so you +Note that we've wired up dist and cargo-release to understand the "Unreleased" heading so you should never edit that name, the tools will update it as needed. -If that releases succeeds, we recommend updating the bootstrap version of cargo-dist as a follow up: +If that releases succeeds, we recommend updating the bootstrap version of dist as a follow up: -* install the version of cargo-dist you just released on your system +* install the version of dist you just released on your system * run `cargo dist init --yes` * commit "chore: update bootstrap dist to ..." -Note that as a consequence of the way we self-host, cargo-dist's published artifacts will always be built/generated by a previous version of itself. This can be problematic if you make breaking changes to cargo-dist-schema's format... so don't! Many things in the schema are intentionally optional to enable forward and backward compatibility, so this should hopefully work well! +Note that as a consequence of the way we self-host, dist's published artifacts will always be built/generated by a previous version of itself. This can be problematic if you make breaking changes to cargo-dist-schema's format... so don't! Many things in the schema are intentionally optional to enable forward and backward compatibility, so this should hopefully work well! diff --git a/axoproject/README.md b/axoproject/README.md index cdac6d685..b7c70e5b8 100644 --- a/axoproject/README.md +++ b/axoproject/README.md @@ -5,7 +5,7 @@ [![Rust CI](https://github.com/axodotdev/axoproject/workflows/Rust%20CI/badge.svg?branch=main)](https://github.com/axodotdev/axoproject/actions/workflows/ci.yml) A tool that handles the details of detecting a cargo/npm workspace/project at a given directory, -and making sense of the structure. This should be used by cargo-dist and oranda to share that logic. +and making sense of the structure. This should be used by dist and oranda to share that logic. ## License diff --git a/axoproject/src/generic.rs b/axoproject/src/generic.rs index 1c4696b1e..ea517c6a4 100644 --- a/axoproject/src/generic.rs +++ b/axoproject/src/generic.rs @@ -1,4 +1,4 @@ -//! Support for generic projects with cargo-dist build instructions +//! Support for generic projects with dist build instructions use axoasset::{AxoassetError, SourceFile}; use camino::{Utf8Path, Utf8PathBuf}; diff --git a/axoproject/src/lib.rs b/axoproject/src/lib.rs index 1c914983a..3e3d83f6a 100644 --- a/axoproject/src/lib.rs +++ b/axoproject/src/lib.rs @@ -1,5 +1,5 @@ //! Shared code for gathering up information about a workspace, used by various axo.dev tools -//! like cargo-dist and oranda. +//! like dist and oranda. //! //! The main entry point is [`WorkspaceGraph::find`][]. @@ -279,7 +279,7 @@ impl WorkspaceSearch { /// Kind of workspace #[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)] pub enum WorkspaceKind { - /// generic cargo-dist compatible workspace + /// generic dist compatible workspace #[cfg(feature = "generic-projects")] Generic, /// cargo/rust workspace diff --git a/cargo-dist-schema/README.md b/cargo-dist-schema/README.md index 2280189f7..f37d3dd00 100644 --- a/cargo-dist-schema/README.md +++ b/cargo-dist-schema/README.md @@ -3,13 +3,13 @@ [![crates.io](https://img.shields.io/crates/v/cargo-dist-schema.svg)](https://crates.io/crates/cargo-dist) [![docs](https://docs.rs/cargo-dist-schema/badge.svg)](https://docs.rs/cargo-dist-schema) ![Rust CI](https://github.com/axodotdev/cargo-dist/workflows/Rust%20CI/badge.svg?branch=main) -Schema reporting/parsing for cargo-dist's `dist-manifest.json`, which is the result you get from `--output-format=json` when running `cargo dist build` or `cargo dist plan`. +Schema reporting/parsing for dist's `dist-manifest.json`, which is the result you get from `--output-format=json` when running `cargo dist build` or `cargo dist plan`. [Read our documentation here!](https://opensource.axo.dev/cargo-dist/book/) -This can be used to parse the machine-readable manifests produced by cargo-dist. Ideally it should be forward and backward compatible with newer and older versions of the manifests. +This can be used to parse the machine-readable manifests produced by dist. Ideally it should be forward and backward compatible with newer and older versions of the manifests. -This compatibility is fairly important as one tool may need to look at releases spread over *years*. Also cargo-dist is self-hosting from previous releases, so when looking at cargo-dist's own releases there will always be (at least) an off-by-one in the manifest and the tool that manifest describes. +This compatibility is fairly important as one tool may need to look at releases spread over *years*. Also dist is self-hosting from previous releases, so when looking at dist's own releases there will always be (at least) an off-by-one in the manifest and the tool that manifest describes. There are currently 3 epochs to dist-manifest.json: @@ -19,13 +19,13 @@ There are currently 3 epochs to dist-manifest.json: Epoch 1 was initial experimentation, and is no longer supported. -Epoch 2 made some breaking changes once we had a better sense for the constraints of the design. Most notable artifacts were pull into a top-level Object that Releases simply refer to by key. This makes it possible for different releases to share an Artifact (such as debuginfo/symbol files for shared binaries). The version gap between Epoch 1 and 2 is a fuzzy zone with inadvisable-to-use prerelease copies of cargo-dist. We believe 0.0.3-prerelease9 is where things got solidified and should be the same as 0.0.3 proper. +Epoch 2 made some breaking changes once we had a better sense for the constraints of the design. Most notable artifacts were pull into a top-level Object that Releases simply refer to by key. This makes it possible for different releases to share an Artifact (such as debuginfo/symbol files for shared binaries). The version gap between Epoch 1 and 2 is a fuzzy zone with inadvisable-to-use prerelease copies of dist. We believe 0.0.3-prerelease9 is where things got solidified and should be the same as 0.0.3 proper. -Epoch 3 has the exact same format but we removed versions from artifact id names, changing the format of URLs. This largely only affects cargo-dist's ability to fetch itself, and created a single transitory release (0.0.6-prerelease.7) which is unable to fetch itself, because it was built with an epoch2 version (0.0.5). This version is intentionally not published on crates.io. The CI was manually updated to use the right URLs to bootstrap 0.0.6-prerelease.8, which is fully in epoch3. +Epoch 3 has the exact same format but we removed versions from artifact id names, changing the format of URLs. This largely only affects dist's ability to fetch itself, and created a single transitory release (0.0.6-prerelease.7) which is unable to fetch itself, because it was built with an epoch2 version (0.0.5). This version is intentionally not published on crates.io. The CI was manually updated to use the right URLs to bootstrap 0.0.6-prerelease.8, which is fully in epoch3. ## A Brief Aside On Self-Hosting/Bootstrapping -cargo-dist's CI is self-hosting using previous releases of itself. Ostensibly there's a coherent bootstrapping chain of releases, but around the Epoch boundary things get a bit wonky. You can always build from source with just `cargo build` so it's not exactly a big deal. +dist's CI is self-hosting using previous releases of itself. Ostensibly there's a coherent bootstrapping chain of releases, but around the Epoch boundary things get a bit wonky. You can always build from source with just `cargo build` so it's not exactly a big deal. But for my own edification: @@ -33,4 +33,4 @@ But for my own edification: * [v0.0.1-prerelease2](https://github.com/axodotdev/cargo-dist/releases/tag/v0.0.1-prerelease2) will be the first **published** version, built with 0.0.1-prerelease1 * [v0.0.1](https://github.com/axodotdev/cargo-dist/releases/tag/v0.0.1) will be the first version built from another published version -The awkward thing is that if we want the release for cargo-dist to include a feature new to itself, we need intermediate prereleases for the feature to "catch up". As such stable releases are basically never built from the previous stable release.https://github.com/axodotdev/cargo-dist/commit/8a417f239ef8f8e3ab66c46cf7c3d26afaba1c87 +The awkward thing is that if we want the release for dist to include a feature new to itself, we need intermediate prereleases for the feature to "catch up". As such stable releases are basically never built from the previous stable release.https://github.com/axodotdev/cargo-dist/commit/8a417f239ef8f8e3ab66c46cf7c3d26afaba1c87 diff --git a/cargo-dist-schema/src/lib.rs b/cargo-dist-schema/src/lib.rs index 3cc64e782..bccd2201a 100644 --- a/cargo-dist-schema/src/lib.rs +++ b/cargo-dist-schema/src/lib.rs @@ -3,7 +3,7 @@ //! # cargo-dist-schema //! //! This crate exists to serialize and deserialize the dist-manifest.json produced -//! by cargo-dist. Ideally it should be reasonably forward and backward compatible +//! by dist. Ideally it should be reasonably forward and backward compatible //! with different versions of this format. //! //! The root type of the schema is [`DistManifest`][]. @@ -83,7 +83,7 @@ impl GithubRunnerRef { } } -/// A local system path on the machine cargo-dist was run. +/// A local system path on the machine dist was run. /// /// This is a String because when deserializing this may be a path format from a different OS! pub type LocalPath = String; @@ -102,10 +102,10 @@ pub type AssetId = String; /// A sorted set of values pub type SortedSet = std::collections::BTreeSet; -/// A report of the releases and artifacts that cargo-dist generated +/// A report of the releases and artifacts that dist generated #[derive(Debug, Clone, Serialize, Deserialize, JsonSchema)] pub struct DistManifest { - /// The version of cargo-dist that generated this + /// The version of dist that generated this #[serde(default)] #[serde(skip_serializing_if = "Option::is_none")] pub dist_version: Option, @@ -113,7 +113,7 @@ pub struct DistManifest { #[serde(default)] #[serde(skip_serializing_if = "Option::is_none")] pub announcement_tag: Option, - /// True if --tag wasn't explicitly passed to cargo-dist. This usually indicates + /// True if --tag wasn't explicitly passed to dist. This usually indicates /// some kind of dry-run state like pr-run-mode=upload. Some third-party tools /// may use this as a proxy for "is dry run" #[serde(default)] @@ -301,10 +301,10 @@ pub struct GithubMatrixEntry { /// Github Runner to user #[serde(skip_serializing_if = "Option::is_none")] pub runner: Option, - /// Expression to execute to install cargo-dist + /// Expression to execute to install dist #[serde(skip_serializing_if = "Option::is_none")] pub install_dist: Option, - /// Arguments to pass to cargo-dist + /// Arguments to pass to dist #[serde(skip_serializing_if = "Option::is_none")] pub dist_args: Option, /// Command to run to install dependencies @@ -935,7 +935,7 @@ impl std::fmt::Display for Library { fn dist_version(input: &str) -> Option { #[derive(Debug, Clone, Serialize, Deserialize, JsonSchema)] struct PartialDistManifest { - /// The version of cargo-dist that generated this + /// The version of dist that generated this #[serde(default)] #[serde(skip_serializing_if = "Option::is_none")] pub dist_version: Option, diff --git a/cargo-dist-schema/src/snapshots/cargo_dist_schema__emit.snap b/cargo-dist-schema/src/snapshots/cargo_dist_schema__emit.snap index fddc249fc..555fe18d3 100644 --- a/cargo-dist-schema/src/snapshots/cargo_dist_schema__emit.snap +++ b/cargo-dist-schema/src/snapshots/cargo_dist_schema__emit.snap @@ -5,7 +5,7 @@ expression: json_schema { "$schema": "http://json-schema.org/draft-07/schema#", "title": "DistManifest", - "description": "A report of the releases and artifacts that cargo-dist generated", + "description": "A report of the releases and artifacts that dist generated", "type": "object", "properties": { "announcement_changelog": { @@ -35,7 +35,7 @@ expression: json_schema ] }, "announcement_tag_is_implicit": { - "description": "True if --tag wasn't explicitly passed to cargo-dist. This usually indicates some kind of dry-run state like pr-run-mode=upload. Some third-party tools may use this as a proxy for \"is dry run\"", + "description": "True if --tag wasn't explicitly passed to dist. This usually indicates some kind of dry-run state like pr-run-mode=upload. Some third-party tools may use this as a proxy for \"is dry run\"", "default": false, "type": "boolean" }, @@ -72,7 +72,7 @@ expression: json_schema ] }, "dist_version": { - "description": "The version of cargo-dist that generated this", + "description": "The version of dist that generated this", "type": [ "string", "null" @@ -766,14 +766,14 @@ expression: json_schema ] }, "dist_args": { - "description": "Arguments to pass to cargo-dist", + "description": "Arguments to pass to dist", "type": [ "string", "null" ] }, "install_dist": { - "description": "Expression to execute to install cargo-dist", + "description": "Expression to execute to install dist", "type": [ "string", "null" diff --git a/cargo-dist/src/announce.rs b/cargo-dist/src/announce.rs index 6245c9b60..20e8f23ca 100644 --- a/cargo-dist/src/announce.rs +++ b/cargo-dist/src/announce.rs @@ -6,8 +6,8 @@ //! //! # The Tag (Selection) //! -//! The "tag" is cargo-dist slang for "what are we actually announcing", in reference -//! to the fact that the original/primary mode of operation in cargo-dist was to +//! The "tag" is dist slang for "what are we actually announcing", in reference +//! to the fact that the original/primary mode of operation in dist was to //! push a commit to your repo with a git tag, which we would use as a selector //! for the packages we're publishing. //! @@ -24,11 +24,11 @@ //! * Whether it's a prerelease //! * What packages are we releasing //! -//! Note that version is *singular* here. It is assumed by cargo-dist that every +//! Note that version is *singular* here. It is assumed by dist that every //! announcement is for a single "version", and all packages that are part of that //! announcement should therefore have that single version. //! -//! This tag is used to ensure every invocation of cargo-dist in the graph +//! This tag is used to ensure every invocation of dist in the graph //! of CI jobs we kick off agrees on what's being done, with each one being passed the //! value via --tag. //! @@ -74,7 +74,7 @@ //! Also, even though the *main* thing we do is publish apps and make installers for them, //! people want to tag pure-source library releases, and they wanted GitHub Releases to still get //! made. This introduced probably the nastiest wrench in the system, the "Library Mode", -//! where cargo-dist knows it's kinda doing nothing but has to go through some of the motions, +//! where dist knows it's kinda doing nothing but has to go through some of the motions, //! and the CI needs to skip over huge chunks. //! //! Library Mode is triggered by a single-package tag. **IT BYPASSES DISTABILITY**, @@ -787,9 +787,9 @@ fn tag_help( .first_key_value() .and_then(|(_, packages)| packages.first()) else { - return r#"It appears that you have no packages in your workspace with distable binaries. You can rerun with "--verbose=info" to see what cargo-dist thinks is in your workspace. Here are some typical issues: + return r#"It appears that you have no packages in your workspace with distable binaries. You can rerun with "--verbose=info" to see what dist thinks is in your workspace. Here are some typical issues: - If you're trying to use cargo-dist to announce libraries, we require you explicitly select the library with e.g. "--tag=my-library-v1.0.0", as this mode is experimental. + If you're trying to use dist to announce libraries, we require you explicitly select the library with e.g. "--tag=my-library-v1.0.0", as this mode is experimental. If you have binaries in your workspace, `publish = false` could be hiding them and adding "dist = true" to [package.metadata.dist] in your Cargo.toml may help."#.to_owned(); }; diff --git a/cargo-dist/src/backend/ci/github.rs b/cargo-dist/src/backend/ci/github.rs index 1434b9c8e..d82f8ef41 100644 --- a/cargo-dist/src/backend/ci/github.rs +++ b/cargo-dist/src/backend/ci/github.rs @@ -30,7 +30,7 @@ const GITHUB_CI_DIR: &str = ".github/workflows/"; const GITHUB_CI_DIR: &str = r".github\workflows\"; const GITHUB_CI_FILE: &str = "release.yml"; -/// Info about running cargo-dist in Github CI +/// Info about running dist in Github CI #[derive(Debug, Serialize)] pub struct GithubCiInfo { /// Cached path to github CI workflows dir @@ -38,9 +38,9 @@ pub struct GithubCiInfo { pub github_ci_workflow_dir: Utf8PathBuf, /// Version of rust toolchain to install (deprecated) pub rust_version: Option, - /// expression to use for installing cargo-dist via shell script + /// expression to use for installing dist via shell script pub install_dist_sh: String, - /// expression to use for installing cargo-dist via powershell script + /// expression to use for installing dist via powershell script pub install_dist_ps1: String, /// Whether to fail-fast pub fail_fast: bool, @@ -182,7 +182,7 @@ impl GithubCiInfo { // Legacy deprecated support let rust_version = dist.config.builds.cargo.rust_toolchain_version.clone(); - // If they don't specify a cargo-dist version, use this one + // If they don't specify a dist version, use this one let self_dist_version = super::SELF_DIST_VERSION.parse().unwrap(); let dist_version = dist .config @@ -618,7 +618,7 @@ fn github_runner_for_target( } } -/// Select the cargo-dist installer approach for a given Github Runner +/// Select the dist installer approach for a given Github Runner fn install_dist_for_targets<'a>( targets: &'a [&'a TargetTripleRef], install_sh: &'a str, diff --git a/cargo-dist/src/backend/ci/mod.rs b/cargo-dist/src/backend/ci/mod.rs index bc375e77e..ecc93c22d 100644 --- a/cargo-dist/src/backend/ci/mod.rs +++ b/cargo-dist/src/backend/ci/mod.rs @@ -1,4 +1,4 @@ -//! Support for generating CI scripts for running cargo-dist +//! Support for generating CI scripts for running dist use semver::Version; @@ -6,7 +6,7 @@ use self::github::GithubCiInfo; pub mod github; -/// The current version of cargo-dist +/// The current version of dist const SELF_DIST_VERSION: &str = env!("CARGO_PKG_VERSION"); const BASE_DIST_FETCH_URL: &str = "https://github.com/axodotdev/cargo-dist/releases/download"; @@ -17,7 +17,7 @@ pub struct CiInfo { pub github: Option, } -/// Get the command to invoke to install cargo-dist via sh script +/// Get the command to invoke to install dist via sh script fn install_dist_sh_for_version(version: &Version) -> String { if let Some(git) = install_dist_git(version) { return git; @@ -25,7 +25,7 @@ fn install_dist_sh_for_version(version: &Version) -> String { let format = cargo_dist_schema::format_of_version(version); let installer_name = if format.unsupported() { // FIXME: we should probably do this check way higher up and produce a proper err... - panic!("requested cargo-dist v{version}, which is not supported by the this copy of cargo-dist ({SELF_DIST_VERSION})"); + panic!("requested dist v{version}, which is not supported by the this copy of dist ({SELF_DIST_VERSION})"); } else if format.artifact_names_contain_versions() { format!("cargo-dist-v{version}-installer.sh") } else { @@ -38,7 +38,7 @@ fn install_dist_sh_for_version(version: &Version) -> String { format!("curl --proto '=https' --tlsv1.2 -LsSf {installer_url} | sh") } -/// Get the command to invoke to install cargo-dist via ps1 script +/// Get the command to invoke to install dist via ps1 script fn install_dist_ps1_for_version(version: &Version) -> String { if let Some(git) = install_dist_git(version) { return git; @@ -46,7 +46,7 @@ fn install_dist_ps1_for_version(version: &Version) -> String { let format = cargo_dist_schema::format_of_version(version); let installer_name = if format.unsupported() { // FIXME: we should probably do this check way higher up and produce a proper err... - panic!("requested cargo-dist v{version}, which is not supported by the this copy of cargo-dist ({SELF_DIST_VERSION})"); + panic!("requested dist v{version}, which is not supported by the this copy of dist ({SELF_DIST_VERSION})"); } else if format.artifact_names_contain_versions() { format!("cargo-dist-v{version}-installer.ps1") } else { diff --git a/cargo-dist/src/backend/installer/msi.rs b/cargo-dist/src/backend/installer/msi.rs index ba3a6c0b2..9bef9ce8f 100644 --- a/cargo-dist/src/backend/installer/msi.rs +++ b/cargo-dist/src/backend/installer/msi.rs @@ -40,7 +40,7 @@ impl MsiInstallerInfo { let mut b = wix::create::Builder::new(); // Build this specific package b.package(Some(&self.pkg_spec)); - // cargo-dist already did the build for us + // dist already did the build for us b.no_build(true); // It built with the `dist` profile b.profile(Some("dist")); diff --git a/cargo-dist/src/backend/mod.rs b/cargo-dist/src/backend/mod.rs index 3c19de493..9e93cf01a 100644 --- a/cargo-dist/src/backend/mod.rs +++ b/cargo-dist/src/backend/mod.rs @@ -1,4 +1,4 @@ -//! The backend of cargo-dist -- things it outputs +//! The backend of dist -- things it outputs use std::time::Duration; diff --git a/cargo-dist/src/build/cargo.rs b/cargo-dist/src/build/cargo.rs index 3f6a4efc0..ecae5366b 100644 --- a/cargo-dist/src/build/cargo.rs +++ b/cargo-dist/src/build/cargo.rs @@ -268,7 +268,7 @@ pub fn rustup_toolchain(dist_graph: &DistGraph, cmd: &RustupStep) -> DistResult< } /// Similar to the above, we read Homebrew's recursive dependency tree and -/// then append link flags to cargo-dist's rustflags. +/// then append link flags to dist's rustflags. /// These ensure that Rust can find C libraries that may exist within /// each package's prefix. fn determine_brew_rustflags(base_rustflags: &str, environment: &SortedMap<&str, &str>) -> String { diff --git a/cargo-dist/src/cli.rs b/cargo-dist/src/cli.rs index 8b44e150e..26367bba6 100644 --- a/cargo-dist/src/cli.rs +++ b/cargo-dist/src/cli.rs @@ -67,7 +67,7 @@ pub struct Cli { #[clap(help_heading = "GLOBAL OPTIONS", global = true)] pub ci: Vec, - /// The (git) tag to use for the Announcement that each invocation of cargo-dist is performing. + /// The (git) tag to use for the Announcement that each invocation of dist is performing. /// /// This tag serves two purposes: defining which apps we are Announcing new Releases for /// (and therefore building binaries and installers for); and picking an id to use for @@ -111,17 +111,17 @@ pub enum Commands { /// Build artifacts #[clap(disable_version_flag = true)] Build(BuildArgs), - /// Setup or update cargo-dist + /// Setup or update dist /// /// This will interactively guide you through the process of selecting configuration options - /// and will also automatically run 'cargo dist generate' afterwards as necessary. It will - /// also handle updating your project to a new version of cargo-dist if you're running one. + /// and will also automatically run 'dist generate' afterwards as necessary. It will + /// also handle updating your project to a new version of dist if you're running one. #[clap(disable_version_flag = true)] Init(InitArgs), /// Generate one or more pieces of configuration #[clap(disable_version_flag = true)] Generate(GenerateArgs), - /// Generate CI scripts for orchestrating cargo-dist (deprecated in favour of generate) + /// Generate CI scripts for orchestrating dist (deprecated in favour of generate) #[clap(disable_version_flag = true)] #[clap(hide = true)] GenerateCi(GenerateCiArgs), @@ -131,9 +131,9 @@ pub enum Commands { /// Generate the final build manifest without running any builds. /// /// This command is designed to match the exact behaviour of - /// 'cargo dist build' when passed the same flags, which is nice + /// 'dist build' when passed the same flags, which is nice /// for consistency but annoying for anyone who doesn't understand - /// cargo-dist's design really well. + /// dist's design really well. /// /// Notably it will default to only talking about artifacts /// for the host system, and will produce paths to the build dir @@ -155,7 +155,7 @@ pub enum Commands { ManifestSchema(ManifestSchemaArgs), /// Get a plan of what to build (and check project status) /// - /// If you want to know what running your cargo-dist CI will produce, + /// If you want to know what running your dist CI will produce, /// this is the command for you! This is the exact command that CI will /// run to make its build plan and generate dist-manifest.json /// (although it adds --output-format=json so that it's machine-readable). @@ -185,7 +185,7 @@ pub struct BuildArgs { /// made for each target system (archives, symbols, msi installers...); and "global" ones, /// which are made once per app (curl-sh installers, npm package, metadata...). /// - /// Having this distinction lets us run cargo-dist independently on + /// Having this distinction lets us run dist independently on /// multiple machines without collisions between the outputs. /// /// If let unspecified, we will pick a fuzzier "host" mode that builds "as much as possible" @@ -272,7 +272,7 @@ pub struct InitArgs { /// Which style(s) of configuration to generate #[derive(ValueEnum, Copy, Clone, Debug)] pub enum GenerateMode { - /// Generate CI scripts for orchestrating cargo-dist + /// Generate CI scripts for orchestrating dist Ci, /// Generate .wxs tempaltes for msi installers Msi, diff --git a/cargo-dist/src/config/mod.rs b/cargo-dist/src/config/mod.rs index f5543fd51..472ba0158 100644 --- a/cargo-dist/src/config/mod.rs +++ b/cargo-dist/src/config/mod.rs @@ -72,7 +72,7 @@ pub enum ArtifactMode { Global, /// Fuzzily build "as much as possible" for the host system Host, - /// Build all the artifacts; only really appropriate for `cargo-dist manifest` + /// Build all the artifacts; only really appropriate for `dist manifest` All, /// Fake all the artifacts; useful for testing/mocking/staging Lies, @@ -678,7 +678,7 @@ impl ChecksumStyle { /// Which style(s) of configuration to generate #[derive(Copy, Clone, Debug, PartialEq, Eq, PartialOrd, Ord, Serialize, Deserialize)] pub enum GenerateMode { - /// Generate CI scripts for orchestrating cargo-dist + /// Generate CI scripts for orchestrating dist #[serde(rename = "ci")] Ci, /// Generate wsx (WiX) templates for msi installers diff --git a/cargo-dist/src/config/v0.rs b/cargo-dist/src/config/v0.rs index 07b8075d9..284a6c749 100644 --- a/cargo-dist/src/config/v0.rs +++ b/cargo-dist/src/config/v0.rs @@ -20,14 +20,14 @@ pub struct GenericConfig { #[derive(Serialize, Deserialize, Debug, Default, Clone)] #[serde(rename_all = "kebab-case")] pub struct DistMetadata { - /// The intended version of cargo-dist to build with. (normal Cargo SemVer syntax) + /// The intended version of dist to build with. (normal Cargo SemVer syntax) /// /// When generating full tasks graphs (such as CI scripts) we will pick this version. /// /// FIXME: Should we produce a warning if running locally with a different version? In theory /// it shouldn't be a problem and newer versions should just be Better... probably you /// Really want to have the exact version when running generate to avoid generating - /// things other cargo-dist versions can't handle! + /// things other dist versions can't handle! #[serde(skip_serializing_if = "Option::is_none")] pub cargo_dist_version: Option, @@ -37,9 +37,9 @@ pub struct DistMetadata { #[serde(skip_serializing_if = "Option::is_none")] pub rust_toolchain_version: Option, - /// Whether the package should be distributed/built by cargo-dist + /// Whether the package should be distributed/built by dist /// - /// This mainly exists to be set to `false` to make cargo-dist ignore the existence of this + /// This mainly exists to be set to `false` to make dist ignore the existence of this /// package. Note that we may still build the package as a side-effect of building the /// workspace -- we just won't bundle it up and report it. /// @@ -65,7 +65,7 @@ pub struct DistMetadata { #[serde(skip_serializing_if = "Option::is_none")] pub pr_run_mode: Option, - /// Generate targets whose cargo-dist should avoid checking for up-to-dateness. + /// Generate targets whose dist should avoid checking for up-to-dateness. #[serde(skip_serializing_if = "Option::is_none")] pub allow_dirty: Option>, @@ -166,7 +166,7 @@ pub struct DistMetadata { /// Build only the required packages, and individually (since 0.1.0) (default: false) /// /// By default when we need to build anything in your workspace, we build your entire workspace - /// with --workspace. This setting tells cargo-dist to instead build each app individually. + /// with --workspace. This setting tells dist to instead build each app individually. /// /// On balance, the Rust experts we've consulted with find building with --workspace to /// be a safer/better default, as it provides some of the benefits of a more manual @@ -208,7 +208,7 @@ pub struct DistMetadata { /// When this happens you have two options: give up on the release entirely (`fail-fast = true`), /// or keep trying to build all the other platforms anyway (`fail-fast = false`). /// - /// cargo-dist was designed around the "keep trying" approach, as we create a draft Release + /// dist was designed around the "keep trying" approach, as we create a draft Release /// and upload results to it over time, undrafting the release only if all tasks succeeded. /// The idea is that even if a platform fails to build, you can decide that's acceptable /// and manually undraft the release with some missing platforms. @@ -261,17 +261,17 @@ pub struct DistMetadata { #[serde(skip_serializing_if = "Option::is_none")] #[serde(default, with = "opt_string_or_vec")] pub install_path: Option>, - /// A list of features to enable when building a package with cargo-dist + /// A list of features to enable when building a package with dist /// /// (defaults to none) #[serde(skip_serializing_if = "Option::is_none")] pub features: Option>, - /// Whether to enable when building a package with cargo-dist + /// Whether to enable when building a package with dist /// /// (defaults to true) #[serde(skip_serializing_if = "Option::is_none")] pub default_features: Option, - /// Whether to enable all features building a package with cargo-dist + /// Whether to enable all features building a package with dist /// /// (defaults to false) #[serde(skip_serializing_if = "Option::is_none")] @@ -334,7 +334,7 @@ pub struct DistMetadata { /// /// (defaults to false) /// - /// Ordinarily, cargo-dist tries to detect if your release + /// Ordinarily, dist tries to detect if your release /// is a prerelease based on its version number using /// semver standards. If it's a prerelease, it will be /// marked as a prerelease in hosting services such as @@ -344,10 +344,10 @@ pub struct DistMetadata { /// Whether we should create the Github Release for you when you push a tag. /// - /// If true (default), cargo-dist will create a new Github Release and generate + /// If true (default), dist will create a new Github Release and generate /// a title/body for it based on your changelog. /// - /// If false, cargo-dist will assume a draft Github Release already exists + /// If false, dist will assume a draft Github Release already exists /// with the title/body you want. At the end of a successful publish it will /// undraft the Github Release. #[serde(skip_serializing_if = "Option::is_none")] @@ -402,7 +402,7 @@ pub struct DistMetadata { pub bin_aliases: Option>>, /// a prefix to add to the release.yml and tag pattern so that - /// cargo-dist can co-exist with other release workflows in complex workspaces + /// dist can co-exist with other release workflows in complex workspaces #[serde(skip_serializing_if = "Option::is_none")] pub tag_namespace: Option, diff --git a/cargo-dist/src/config/v1/builds/cargo.rs b/cargo-dist/src/config/v1/builds/cargo.rs index 502b2d949..42c0f9bb4 100644 --- a/cargo-dist/src/config/v1/builds/cargo.rs +++ b/cargo-dist/src/config/v1/builds/cargo.rs @@ -23,13 +23,13 @@ pub struct AppCargoBuildConfig { /// common build config pub common: CommonBuildConfig, - /// A list of features to enable when building a package with cargo-dist + /// A list of features to enable when building a package with dist pub features: Vec, - /// Whether to enable when building a package with cargo-dist + /// Whether to enable when building a package with dist /// /// (defaults to true) pub default_features: bool, - /// Whether to enable all features building a package with cargo-dist + /// Whether to enable all features building a package with dist /// /// (defaults to false) pub all_features: bool, @@ -58,7 +58,7 @@ pub struct CargoBuildLayer { /// Build only the required packages, and individually (since 0.1.0) (default: false) /// /// By default when we need to build anything in your workspace, we build your entire workspace - /// with --workspace. This setting tells cargo-dist to instead build each app individually. + /// with --workspace. This setting tells dist to instead build each app individually. /// /// On balance, the Rust experts we've consulted with find building with --workspace to /// be a safer/better default, as it provides some of the benefits of a more manual @@ -80,17 +80,17 @@ pub struct CargoBuildLayer { #[serde(skip_serializing_if = "Option::is_none")] pub precise_builds: Option, - /// A list of features to enable when building a package with cargo-dist + /// A list of features to enable when building a package with dist /// /// (defaults to none) #[serde(skip_serializing_if = "Option::is_none")] pub features: Option>, - /// Whether to enable when building a package with cargo-dist + /// Whether to enable when building a package with dist /// /// (defaults to true) #[serde(skip_serializing_if = "Option::is_none")] pub default_features: Option, - /// Whether to enable all features building a package with cargo-dist + /// Whether to enable all features building a package with dist /// /// (defaults to false) #[serde(skip_serializing_if = "Option::is_none")] diff --git a/cargo-dist/src/config/v1/ci/mod.rs b/cargo-dist/src/config/v1/ci/mod.rs index 26d2ad372..462790f3c 100644 --- a/cargo-dist/src/config/v1/ci/mod.rs +++ b/cargo-dist/src/config/v1/ci/mod.rs @@ -83,7 +83,7 @@ pub struct CommonCiLayer { /// When this happens you have two options: give up on the release entirely (`fail-fast = true`), /// or keep trying to build all the other platforms anyway (`fail-fast = false`). /// - /// cargo-dist was designed around the "keep trying" approach, as we create a draft Release + /// dist was designed around the "keep trying" approach, as we create a draft Release /// and upload results to it over time, undrafting the release only if all tasks succeeded. /// The idea is that even if a platform fails to build, you can decide that's acceptable /// and manually undraft the release with some missing platforms. @@ -133,7 +133,7 @@ pub struct CommonCiLayer { pub pr_run_mode: Option, /// a prefix to add to the release.yml and tag pattern so that - /// cargo-dist can co-exist with other release workflows in complex workspaces + /// dist can co-exist with other release workflows in complex workspaces #[serde(skip_serializing_if = "Option::is_none")] pub tag_namespace: Option, @@ -206,7 +206,7 @@ pub struct CommonCiConfig { pub pr_run_mode: cargo_dist_schema::PrRunMode, /// a prefix to add to the release.yml and tag pattern so that - /// cargo-dist can co-exist with other release workflows in complex workspaces + /// dist can co-exist with other release workflows in complex workspaces pub tag_namespace: Option, /// Plan jobs to run in CI diff --git a/cargo-dist/src/config/v1/hosts/github.rs b/cargo-dist/src/config/v1/hosts/github.rs index 804e9271a..d89023dad 100644 --- a/cargo-dist/src/config/v1/hosts/github.rs +++ b/cargo-dist/src/config/v1/hosts/github.rs @@ -12,10 +12,10 @@ pub struct GithubHostLayer { /// Whether we should create the Github Release for you when you push a tag. /// - /// If true (default), cargo-dist will create a new Github Release and generate + /// If true (default), dist will create a new Github Release and generate /// a title/body for it based on your changelog. /// - /// If false, cargo-dist will assume a draft Github Release already exists + /// If false, dist will assume a draft Github Release already exists /// with the title/body you want. At the end of a successful publish it will /// undraft the Github Release. #[serde(skip_serializing_if = "Option::is_none")] diff --git a/cargo-dist/src/config/v1/hosts/mod.rs b/cargo-dist/src/config/v1/hosts/mod.rs index 13627551d..862cd724b 100644 --- a/cargo-dist/src/config/v1/hosts/mod.rs +++ b/cargo-dist/src/config/v1/hosts/mod.rs @@ -56,7 +56,7 @@ pub struct HostLayer { /// /// (defaults to false) /// - /// Ordinarily, cargo-dist tries to detect if your release + /// Ordinarily, dist tries to detect if your release /// is a prerelease based on its version number using /// semver standards. If it's a prerelease, it will be /// marked as a prerelease in hosting services such as diff --git a/cargo-dist/src/config/v1/mod.rs b/cargo-dist/src/config/v1/mod.rs index 34260e276..5a450d2fc 100644 --- a/cargo-dist/src/config/v1/mod.rs +++ b/cargo-dist/src/config/v1/mod.rs @@ -1,4 +1,4 @@ -//! The cargo-dist 1.0 config format (as opposed to the old v0 format) +//! The dist 1.0 config format (as opposed to the old v0 format) //! //! This is the config subsystem! //! @@ -159,9 +159,9 @@ pub fn app_config( /// config that is global to the entire workspace #[derive(Debug, Clone)] pub struct WorkspaceConfig { - /// The intended version of cargo-dist to build with. (normal Cargo SemVer syntax) + /// The intended version of dist to build with. (normal Cargo SemVer syntax) pub dist_version: Option, - /// Generate targets whose cargo-dist should avoid checking for up-to-dateness. + /// Generate targets whose dist should avoid checking for up-to-dateness. pub allow_dirty: Vec, /// ci config pub ci: CiConfig, @@ -179,9 +179,9 @@ pub struct WorkspaceConfig { /// but inheritance relationships haven't been folded in yet. #[derive(Debug, Clone)] pub struct WorkspaceConfigInheritable { - /// The intended version of cargo-dist to build with. (normal Cargo SemVer syntax) + /// The intended version of dist to build with. (normal Cargo SemVer syntax) pub dist_version: Option, - /// Generate targets whose cargo-dist should avoid checking for up-to-dateness. + /// Generate targets whose dist should avoid checking for up-to-dateness. pub allow_dirty: Vec, /// artifact config pub artifacts: WorkspaceArtifactConfig, @@ -270,7 +270,7 @@ pub struct AppConfig { pub installers: AppInstallerConfig, /// publisher config pub publishers: PublisherConfig, - /// Whether the package should be distributed/built by cargo-dist + /// Whether the package should be distributed/built by dist pub dist: Option, /// The full set of target triples to build for. pub targets: Vec, @@ -290,7 +290,7 @@ pub struct AppConfigInheritable { pub installers: InstallerConfigInheritable, /// publisher config pub publishers: PublisherConfigInheritable, - /// Whether the package should be distributed/built by cargo-dist + /// Whether the package should be distributed/built by dist pub dist: Option, /// The full set of target triples to build for. pub targets: Vec, @@ -366,20 +366,20 @@ impl ApplyLayer for AppConfigInheritable { #[derive(Debug, Clone, Serialize, Deserialize)] #[serde(rename_all = "kebab-case")] pub struct TomlLayer { - /// The intended version of cargo-dist to build with. (normal Cargo SemVer syntax) + /// The intended version of dist to build with. (normal Cargo SemVer syntax) /// /// When generating full tasks graphs (such as CI scripts) we will pick this version. /// /// FIXME: Should we produce a warning if running locally with a different version? In theory /// it shouldn't be a problem and newer versions should just be Better... probably you /// Really want to have the exact version when running generate to avoid generating - /// things other cargo-dist versions can't handle! + /// things other dist versions can't handle! #[serde(skip_serializing_if = "Option::is_none")] pub dist_version: Option, - /// Whether the package should be distributed/built by cargo-dist + /// Whether the package should be distributed/built by dist /// - /// This mainly exists to be set to `false` to make cargo-dist ignore the existence of this + /// This mainly exists to be set to `false` to make dist ignore the existence of this /// package. Note that we may still build the package as a side-effect of building the /// workspace -- we just won't bundle it up and report it. /// @@ -387,7 +387,7 @@ pub struct TomlLayer { #[serde(skip_serializing_if = "Option::is_none")] pub dist: Option, - /// Generate targets whose cargo-dist should avoid checking for up-to-dateness. + /// Generate targets whose dist should avoid checking for up-to-dateness. #[serde(skip_serializing_if = "Option::is_none")] pub allow_dirty: Option>, diff --git a/cargo-dist/src/errors.rs b/cargo-dist/src/errors.rs index 632cdccc7..c2f7a5840 100644 --- a/cargo-dist/src/errors.rs +++ b/cargo-dist/src/errors.rs @@ -15,7 +15,7 @@ use thiserror::Error; /// An alias for the common Result type for this crate pub type DistResult = std::result::Result; -/// Errors cargo-dist can have +/// Errors dist can have #[derive(Debug, Error, Diagnostic)] pub enum DistError { /// random i/o error @@ -71,9 +71,9 @@ pub enum DistError { #[error(transparent)] ParseIntError(#[from] std::num::ParseIntError), - /// A problem with a jinja template, which is always a cargo-dist bug + /// A problem with a jinja template, which is always a dist bug #[error("Failed to render template")] - #[diagnostic(help("this is a bug in cargo-dist, let us know and we'll fix it: https://github.com/axodotdev/cargo-dist/issues/new"))] + #[diagnostic(help("this is a bug in dist, let us know and we'll fix it: https://github.com/axodotdev/cargo-dist/issues/new"))] Jinja { /// The SourceFile we were try to parse #[source_code] @@ -117,10 +117,8 @@ pub enum DistError { cause: serde_json::Error, }, - /// User declined to update cargo-dist, refuse to make progress - #[error( - "to update your cargo-dist config you must use the version your project is configured for" - )] + /// User declined to update dist, refuse to make progress + #[error("to update your dist config you must use the version your project is configured for")] #[diagnostic(help( "you're running {running_version} but the project is configured for {project_version}" ))] @@ -223,7 +221,7 @@ pub enum DistError { MismatchedPrereleases, /// parse_tag concluded there was nothing to release - #[error("This workspace doesn't have anything for cargo-dist to Release!")] + #[error("This workspace doesn't have anything for dist to Release!")] NothingToRelease { /// full help printout (very dynamic) #[help] @@ -250,9 +248,7 @@ pub enum DistError { /// `cargo dist generate` was passed an explicit GenerateMode but the config in their Cargo.toml /// has that mode set to allow-dirty, a contradiction! - #[error( - "'{generate_mode}' is marked as allow-dirty in your cargo-dist config, refusing to run" - )] + #[error("'{generate_mode}' is marked as allow-dirty in your dist config, refusing to run")] ContradictoryGenerateModes { /// The problematic mode generate_mode: crate::config::GenerateMode, @@ -290,7 +286,7 @@ pub enum DistError { /// unrecognized job style #[error("{style} is not a recognized job value")] - #[diagnostic(help("Jobs that do not come with cargo-dist should be prefixed with ./"))] + #[diagnostic(help("Jobs that do not come with dist should be prefixed with ./"))] UnrecognizedJobStyle { /// value provided style: String, @@ -392,9 +388,7 @@ pub enum DistError { /// Trying to run cargo dist selfupdate in a random dir #[error("`cargo dist selfupdate` needs to be run in a project")] - #[diagnostic(help( - "If you just want to update cargo-dist and not your project, pass --skip-init" - ))] + #[diagnostic(help("If you just want to update dist and not your project, pass --skip-init"))] UpdateNotInWorkspace { /// The report about the missing workspace #[diagnostic_source] @@ -419,7 +413,7 @@ pub enum DistError { NeedsInit, /// Running different version from config - #[error("You're running cargo-dist {running_version}, but 'cargo-dist-version = {config_version}' is set in your Cargo.toml")] + #[error("You're running dist {running_version}, but 'cargo-dist-version = {config_version}' is set in your Cargo.toml")] #[diagnostic(help("Rerun 'cargo dist init' to update to this version."))] MismatchedDistVersion { /// config version diff --git a/cargo-dist/src/host.rs b/cargo-dist/src/host.rs index 36e9d39b3..9e2f71271 100644 --- a/cargo-dist/src/host.rs +++ b/cargo-dist/src/host.rs @@ -319,7 +319,7 @@ pub(crate) fn select_hosting( // This is the one case where we'll tolerate hosting not existing: // * they don't have one set explicitly // * and they haven't turned on a CI provider - // This implies early setup or using cargo-dist very "manually" + // This implies early setup or using dist very "manually" return Ok(None); }; diff --git a/cargo-dist/src/init.rs b/cargo-dist/src/init.rs index 0b92f4d11..6a91ba7b6 100644 --- a/cargo-dist/src/init.rs +++ b/cargo-dist/src/init.rs @@ -79,7 +79,7 @@ pub fn do_init(cfg: &Config, args: &InitArgs) -> DistResult<()> { let root_workspace = workspaces.root_workspace(); let check = console::style("✔".to_string()).for_stderr().green(); - eprintln!("let's setup your cargo-dist config..."); + eprintln!("let's setup your dist config..."); eprintln!(); // For each [workspace] Cargo.toml in the workspaces, initialize [profile] @@ -114,8 +114,8 @@ pub fn do_init(cfg: &Config, args: &InitArgs) -> DistResult<()> { // Already-initted users should be asked whether to migrate. } else if root_workspace.kind == WorkspaceKind::Rust { let prompt = r#"Would you like to opt in to the new configuration format? - Future versions of cargo-dist will feature major changes to the - configuration format, including a new cargo-dist-specific configuration file."#; + Future versions of dist will feature major changes to the + configuration format, including a new dist-specific configuration file."#; let res = if args.yes { false } else { @@ -257,7 +257,7 @@ pub fn do_init(cfg: &Config, args: &InitArgs) -> DistResult<()> { } } - eprintln!("{check} cargo-dist is setup!"); + eprintln!("{check} dist is setup!"); eprintln!(); // regenerate anything that needs to be @@ -299,7 +299,7 @@ fn init_dist_profile( // that enormous applications like chromium can become unbuildable), but definitely // eeks out a bit more from your binaries. // - // In principle cargo-dist is targeting True Shippable Binaries and so it's + // In principle dist is targeting True Shippable Binaries and so it's // worth it to go nuts getting every last drop out of your binaries... but a lot // of people are going to build binaries that might never even be used, so really // we're just burning a bunch of CI time for nothing. @@ -443,7 +443,7 @@ fn get_new_dist_metadata( if desired_version != ¤t_version && !desired_version.pre.starts_with("github-") { let default = true; let prompt = format!( - r#"update your project to this version of cargo-dist? + r#"update your project to this version of dist? {} => {}"#, desired_version, current_version ); @@ -677,7 +677,7 @@ fn get_new_dist_metadata( .contains(&InstallerStyle::Homebrew); if homebrew_is_new { - let prompt = r#"you've enabled Homebrew support; if you want cargo-dist + let prompt = r#"you've enabled Homebrew support; if you want dist to automatically push package updates to a tap (repository) for you, please enter the tap name (in GitHub owner/name format)"#; let default = "".to_string(); @@ -920,7 +920,7 @@ fn apply_dist_to_metadata(metadata: &mut toml_edit::Item, meta: &DistMetadata) { apply_optional_value( table, "cargo-dist-version", - "# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax)\n", + "# The preferred dist version to use in CI (Cargo.toml SemVer syntax)\n", cargo_dist_version.as_ref().map(|v| v.to_string()), ); @@ -1083,14 +1083,14 @@ fn apply_dist_to_metadata(metadata: &mut toml_edit::Item, meta: &DistMetadata) { apply_optional_value( table, "create-release", - "# Whether cargo-dist should create a Github Release or use an existing draft\n", + "# Whether dist should create a Github Release or use an existing draft\n", *create_release, ); apply_optional_value( table, "github-release", - "# Which phase cargo-dist should use to create the GitHub release\n", + "# Which phase dist should use to create the GitHub release\n", github_release.as_ref().map(|a| a.to_string()), ); @@ -1253,7 +1253,7 @@ fn apply_dist_to_metadata(metadata: &mut toml_edit::Item, meta: &DistMetadata) { apply_optional_value( table, "tag-namespace", - "# A prefix git tags must include for cargo-dist to care about them\n", + "# A prefix git tags must include for dist to care about them\n", tag_namespace.as_ref(), ); diff --git a/cargo-dist/src/lib.rs b/cargo-dist/src/lib.rs index b9afb5c4e..d71649c93 100644 --- a/cargo-dist/src/lib.rs +++ b/cargo-dist/src/lib.rs @@ -1,9 +1,9 @@ #![deny(missing_docs)] #![allow(clippy::single_match, clippy::result_large_err)] -//! # cargo-dist +//! # dist //! -//! This is the library at the core of the 'cargo dist' CLI. It currently mostly exists +//! This is the library at the core of the 'dist' CLI. It currently mostly exists //! for the sake of internal documentation/testing, and isn't intended to be used by anyone else. //! That said, if you have a reason to use it, let us know! //! diff --git a/cargo-dist/src/main.rs b/cargo-dist/src/main.rs index 20f0e2c7c..848e5aa6b 100644 --- a/cargo-dist/src/main.rs +++ b/cargo-dist/src/main.rs @@ -1,6 +1,6 @@ #![deny(missing_docs)] -//! CLI binary interface for cargo-dist +//! CLI binary interface for dist use std::{ffi::OsString, io::Write}; @@ -545,7 +545,7 @@ fn this_cargo_dist_provided_by_brew() -> bool { } if let Ok(path) = std::env::current_exe() { - // The cargo-dist being a symlink that points to a copy that + // The dist being a symlink that points to a copy that // lives in Homebrew's "Cellar", *or* that file directly, // suggests that this file is from Homebrew. let realpath; @@ -590,7 +590,7 @@ async fn cmd_update(_config: &Cli, args: &cli::UpdateArgs) -> Result<(), miette: } if this_cargo_dist_provided_by_brew() { - eprintln!("Your copy of `cargo-dist` seems to have been installed via Homebrew."); + eprintln!("Your copy of `dist` seems to have been installed via Homebrew."); eprintln!("Please run `brew upgrade cargo-dist` to update this copy."); return Ok(()); } @@ -680,7 +680,7 @@ async fn cmd_update(_config: &Cli, args: &cli::UpdateArgs) -> Result<(), miette: // is appropriate. if !args.skip_init { let my_path = Utf8PathBuf::from_path_buf(std::env::current_exe().into_diagnostic()?) - .map_err(|_| miette!("Unable to decode the path to cargo-dist itself"))?; + .map_err(|_| miette!("Unable to decode the path to dist itself"))?; perform_init(&my_path, args)?; return Ok(()); diff --git a/cargo-dist/src/platform.rs b/cargo-dist/src/platform.rs index 7523ff186..10af4d57c 100644 --- a/cargo-dist/src/platform.rs +++ b/cargo-dist/src/platform.rs @@ -76,11 +76,11 @@ //! //! In particular, only once we have info from building and linkage-checking //! the binaries will we have all the [`RuntimeConditions`][]. In a typical -//! CI run of cargo-dist this is fine, because the main use of this info +//! CI run of dist this is fine, because the main use of this info //! is for installers, which are built with a fresh invocation on a machine //! with all binaries/platform info prefetched. //! -//! However, if you were to run cargo-dist locally and try to build binaries +//! However, if you were to run dist locally and try to build binaries //! and installers all at once, we currently fail to regenerate the platform //! info and update the installers. Doing this would necessitate some refactors //! to make the installers compute more of their archive/platform info "latebound" @@ -203,7 +203,7 @@ //! //! # targets vs target //! -//! Ok so a lot of cargo-dist's code is *vaguely* trying to allow for a single archive +//! Ok so a lot of dist's code is *vaguely* trying to allow for a single archive //! to *natively* be built for multiple architectures. This would for instance be the //! case for any apple Universal Binary, which is just several binaries built for different //! architectures all stapled together. diff --git a/cargo-dist/src/tasks.rs b/cargo-dist/src/tasks.rs index 6ad7fa3ed..fa758c246 100644 --- a/cargo-dist/src/tasks.rs +++ b/cargo-dist/src/tasks.rs @@ -1,6 +1,6 @@ -//! Code to compute the tasks cargo-dist should do +//! Code to compute the tasks dist should do //! -//! This is the heart and soul of cargo-dist, and ideally the [`gather_work`][] function +//! This is the heart and soul of dist, and ideally the [`gather_work`][] function //! should compute every minute detail dist will perform ahead of time. This is done with //! the DistGraphBuilder, which roughly builds up the work to do as follows: //! @@ -177,7 +177,7 @@ impl BinaryAliases { } } -/// The graph of all work that cargo-dist needs to do on this invocation. +/// The graph of all work that dist needs to do on this invocation. /// /// All work is precomputed at the start of execution because only discovering /// what you need to do in the middle of building/packing things is a mess. @@ -186,8 +186,8 @@ impl BinaryAliases { pub struct DistGraph { /// Unique id for the system we're building on. /// - /// Since the whole premise of cargo-dist is to invoke it once on each machine, and no - /// two machines have any reason to have the exact same CLI args for cargo-dist, we + /// Since the whole premise of dist is to invoke it once on each machine, and no + /// two machines have any reason to have the exact same CLI args for dist, we /// just use a mangled form of the CLI arguments here. pub system_id: SystemId, /// Whether it looks like `cargo dist init` has been run @@ -214,7 +214,7 @@ pub struct DistGraph { pub repo_dir: Utf8PathBuf, /// The root directory of the current cargo workspace. pub workspace_dir: Utf8PathBuf, - /// cargo-dist's target dir (generally nested under `target_dir`). + /// dist's target dir (generally nested under `target_dir`). pub dist_dir: Utf8PathBuf, /// misc workspace-global config pub config: WorkspaceConfig, @@ -342,7 +342,7 @@ pub struct Binary { pub kind: BinaryKind, } -/// Different kinds of binaries cargo-dist knows about +/// Different kinds of binaries dist knows about #[derive(Clone, Copy, Debug, PartialEq)] pub enum BinaryKind { /// Standard executable diff --git a/cargo-dist/src/tests/config.rs b/cargo-dist/src/tests/config.rs index 2f7c4e3dc..f9577eec5 100644 --- a/cargo-dist/src/tests/config.rs +++ b/cargo-dist/src/tests/config.rs @@ -60,7 +60,7 @@ version = "1.0.0" # Config for 'cargo dist' [workspace.metadata.dist] -# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) +# The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" # CI backends to support ci = "github" @@ -116,7 +116,7 @@ version = "1.0.0" # Config for 'cargo dist' [workspace.metadata.dist] -# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) +# The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" # CI backends to support ci = ["github"] @@ -135,7 +135,7 @@ version = "1.0.0" # Config for 'cargo dist' [workspace.metadata.dist] -# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) +# The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" # CI backends to support ci = "github" @@ -168,7 +168,7 @@ version = "1.0.0" # Config for 'cargo dist' [workspace.metadata.dist] -# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) +# The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" # CI backends to support ci = ["github", "github"] @@ -187,7 +187,7 @@ version = "1.0.0" # Config for 'cargo dist' [workspace.metadata.dist] -# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) +# The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" # CI backends to support ci = ["github", "github"] diff --git a/cargo-dist/templates/ci/github/release.yml.j2 b/cargo-dist/templates/ci/github/release.yml.j2 index 0433b78e5..1fd9c0640 100644 --- a/cargo-dist/templates/ci/github/release.yml.j2 +++ b/cargo-dist/templates/ci/github/release.yml.j2 @@ -1,4 +1,4 @@ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/templates/installer/installer.ps1.j2 b/cargo-dist/templates/installer/installer.ps1.j2 index 1c7c38f9a..75358e3d4 100644 --- a/cargo-dist/templates/installer/installer.ps1.j2 +++ b/cargo-dist/templates/installer/installer.ps1.j2 @@ -84,7 +84,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ {%- for artifact in artifacts %} "{{ artifact.target_triple }}" = @{ diff --git a/cargo-dist/tests/gallery/dist.rs b/cargo-dist/tests/gallery/dist.rs index d6d23cc13..4531a5a32 100644 --- a/cargo-dist/tests/gallery/dist.rs +++ b/cargo-dist/tests/gallery/dist.rs @@ -126,7 +126,7 @@ pub struct BuildAndPlanResult { impl<'a> TestContext<'a, Tools> { /// Run 'cargo dist build -alies --no-local-paths --output-format=json' and return paths to various files that were generated pub fn cargo_dist_build_lies(&self, test_name: &str) -> Result { - // If the cargo-dist target dir exists, delete it to avoid cross-contamination + // If the dist target dir exists, delete it to avoid cross-contamination let out_path = Utf8Path::new("target/distrib/"); if out_path.exists() { LocalAsset::remove_dir_all(out_path)?; @@ -176,7 +176,7 @@ impl<'a> TestContext<'a, Tools> { } /// Run 'cargo dist build -aglobal' and return paths to various files that were generated pub fn cargo_dist_build_global(&self, test_name: &str) -> Result { - // If the cargo-dist target dir exists, delete it to avoid cross-contamination + // If the dist target dir exists, delete it to avoid cross-contamination let out_path = Utf8Path::new("target/distrib/"); if out_path.exists() { LocalAsset::remove_dir_all(out_path)?; diff --git a/cargo-dist/tests/gallery/dist/tools.rs b/cargo-dist/tests/gallery/dist/tools.rs index 34ed34565..e8bec0423 100644 --- a/cargo-dist/tests/gallery/dist/tools.rs +++ b/cargo-dist/tests/gallery/dist/tools.rs @@ -24,11 +24,9 @@ impl Tools { // this lets us test our shippable builds. let cargo_dist_path = std::env::var(ENV_RUNTIME_CARGO_DIST_BIN) .unwrap_or_else(|_| STATIC_CARGO_DIST_BIN.to_owned()); - let cargo_dist = CommandInfo::new("cargo-dist", Some(&cargo_dist_path)) - .expect("cargo-dist isn't built!?"); - cargo_dist - .version() - .expect("couldn't parse cargo-dist version!?"); + let cargo_dist = + CommandInfo::new("cargo-dist", Some(&cargo_dist_path)).expect("dist isn't built!?"); + cargo_dist.version().expect("couldn't parse dist version!?"); let shellcheck = CommandInfo::new("shellcheck", None); let psanalyzer = CommandInfo::new_powershell_command("Invoke-ScriptAnalyzer"); let homebrew = CommandInfo::new("brew", None); diff --git a/cargo-dist/tests/snapshots/akaikatana_basic.snap b/cargo-dist/tests/snapshots/akaikatana_basic.snap index c20d148fa..519902260 100644 --- a/cargo-dist/tests/snapshots/akaikatana_basic.snap +++ b/cargo-dist/tests/snapshots/akaikatana_basic.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "akaikatana-repack-x86_64-pc-windows-msvc.zip" @@ -2113,7 +2113,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/akaikatana_musl.snap b/cargo-dist/tests/snapshots/akaikatana_musl.snap index 3e22c6a9c..8881106e4 100644 --- a/cargo-dist/tests/snapshots/akaikatana_musl.snap +++ b/cargo-dist/tests/snapshots/akaikatana_musl.snap @@ -1527,7 +1527,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/akaikatana_one_alias_among_many_binaries.snap b/cargo-dist/tests/snapshots/akaikatana_one_alias_among_many_binaries.snap index 67cf4d4fe..eb3c1f21b 100644 --- a/cargo-dist/tests/snapshots/akaikatana_one_alias_among_many_binaries.snap +++ b/cargo-dist/tests/snapshots/akaikatana_one_alias_among_many_binaries.snap @@ -1376,7 +1376,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "akaikatana-repack-x86_64-pc-windows-msvc.zip" @@ -2143,7 +2143,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/akaikatana_two_bin_aliases.snap b/cargo-dist/tests/snapshots/akaikatana_two_bin_aliases.snap index 4597965fc..227558ffa 100644 --- a/cargo-dist/tests/snapshots/akaikatana_two_bin_aliases.snap +++ b/cargo-dist/tests/snapshots/akaikatana_two_bin_aliases.snap @@ -1400,7 +1400,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "akaikatana-repack-x86_64-pc-windows-msvc.zip" @@ -2169,7 +2169,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/akaikatana_updaters.snap b/cargo-dist/tests/snapshots/akaikatana_updaters.snap index 8a59a18a4..52a00aa8f 100644 --- a/cargo-dist/tests/snapshots/akaikatana_updaters.snap +++ b/cargo-dist/tests/snapshots/akaikatana_updaters.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "akaikatana-repack-x86_64-pc-windows-msvc.zip" @@ -2153,7 +2153,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_abyss.snap b/cargo-dist/tests/snapshots/axolotlsay_abyss.snap index bb2ade6b2..85dcc73ec 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_abyss.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_abyss.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3703,7 +3703,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_abyss_only.snap b/cargo-dist/tests/snapshots/axolotlsay_abyss_only.snap index 3539166cc..8699b74ff 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_abyss_only.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_abyss_only.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3696,7 +3696,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_alias.snap b/cargo-dist/tests/snapshots/axolotlsay_alias.snap index a811d4c89..b34977532 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_alias.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_alias.snap @@ -1376,7 +1376,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3726,7 +3726,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_alias_ignores_missing_bins.snap b/cargo-dist/tests/snapshots/axolotlsay_alias_ignores_missing_bins.snap index 2c5886fb3..df367581a 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_alias_ignores_missing_bins.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_alias_ignores_missing_bins.snap @@ -1380,7 +1380,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3728,7 +3728,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_basic.snap b/cargo-dist/tests/snapshots/axolotlsay_basic.snap index 9b6df9500..89732e9aa 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_basic.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_basic.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3694,7 +3694,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_basic_lies.snap b/cargo-dist/tests/snapshots/axolotlsay_basic_lies.snap index c08c6da10..293abc3f5 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_basic_lies.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_basic_lies.snap @@ -1351,7 +1351,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3797,7 +3797,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_build_setup_steps.snap b/cargo-dist/tests/snapshots/axolotlsay_build_setup_steps.snap index 136e8891e..e1f7977dd 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_build_setup_steps.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_build_setup_steps.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3694,7 +3694,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2b.snap b/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2b.snap index 13949265a..0afa82a7c 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2b.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2b.snap @@ -1507,7 +1507,7 @@ download_binary_and_run_installer "$@" || exit 1 } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2s.snap b/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2s.snap index 6b597c6c0..f269265e6 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2s.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_checksum_blake2s.snap @@ -1507,7 +1507,7 @@ download_binary_and_run_installer "$@" || exit 1 } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_256.snap b/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_256.snap index d05c7b40b..e5611b408 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_256.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_256.snap @@ -1507,7 +1507,7 @@ download_binary_and_run_installer "$@" || exit 1 } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_512.snap b/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_512.snap index d22257bb7..4fd444ed5 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_512.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_checksum_sha3_512.snap @@ -1507,7 +1507,7 @@ download_binary_and_run_installer "$@" || exit 1 } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_custom_formula.snap b/cargo-dist/tests/snapshots/axolotlsay_custom_formula.snap index 7bcade56a..6e913918d 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_custom_formula.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_custom_formula.snap @@ -372,7 +372,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_custom_github_runners.snap b/cargo-dist/tests/snapshots/axolotlsay_custom_github_runners.snap index 3329be416..a568e6010 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_custom_github_runners.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_custom_github_runners.snap @@ -296,7 +296,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_disable_source_tarball.snap b/cargo-dist/tests/snapshots/axolotlsay_disable_source_tarball.snap index 7bcbe24b0..4a0ff5521 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_disable_source_tarball.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_disable_source_tarball.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3682,7 +3682,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_dispatch.snap b/cargo-dist/tests/snapshots/axolotlsay_dispatch.snap index 43debd78d..607c5155a 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_dispatch.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_dispatch.snap @@ -294,7 +294,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss.snap b/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss.snap index 0bc0f60f4..1ac19e362 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss.snap @@ -302,7 +302,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss_only.snap b/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss_only.snap index c548cffe9..c34ce92af 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss_only.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_dispatch_abyss_only.snap @@ -296,7 +296,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_edit_existing.snap b/cargo-dist/tests/snapshots/axolotlsay_edit_existing.snap index fd983bc0d..5871e80d4 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_edit_existing.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_edit_existing.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3616,7 +3616,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_generic_workspace_basic.snap b/cargo-dist/tests/snapshots/axolotlsay_generic_workspace_basic.snap index 485161f7c..f43c87597 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_generic_workspace_basic.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_generic_workspace_basic.snap @@ -1347,7 +1347,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-js-x86_64-pc-windows-msvc.zip" @@ -3125,7 +3125,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.zip" @@ -4103,7 +4103,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_homebrew_packages.snap b/cargo-dist/tests/snapshots/axolotlsay_homebrew_packages.snap index d0682dc2a..4ef357681 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_homebrew_packages.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_homebrew_packages.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3696,7 +3696,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_musl.snap b/cargo-dist/tests/snapshots/axolotlsay_musl.snap index d3a564c8e..231a73823 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_musl.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_musl.snap @@ -3022,7 +3022,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_musl_no_gnu.snap b/cargo-dist/tests/snapshots/axolotlsay_musl_no_gnu.snap index 7a8d29caa..b07b088b5 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_musl_no_gnu.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_musl_no_gnu.snap @@ -2948,7 +2948,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_no_homebrew_publish.snap b/cargo-dist/tests/snapshots/axolotlsay_no_homebrew_publish.snap index 3575a682c..26685043c 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_no_homebrew_publish.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_no_homebrew_publish.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3616,7 +3616,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_no_locals.snap b/cargo-dist/tests/snapshots/axolotlsay_no_locals.snap index 0daedb87b..4edf0dbcd 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_no_locals.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_no_locals.snap @@ -294,7 +294,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_no_locals_but_custom.snap b/cargo-dist/tests/snapshots/axolotlsay_no_locals_but_custom.snap index 67e62084f..3bed4ee36 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_no_locals_but_custom.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_no_locals_but_custom.snap @@ -294,7 +294,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_several_aliases.snap b/cargo-dist/tests/snapshots/axolotlsay_several_aliases.snap index 52ff4b256..ea2298b93 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_several_aliases.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_several_aliases.snap @@ -1380,7 +1380,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3732,7 +3732,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign.snap b/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign.snap index abc88848b..c501fd80b 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign.snap @@ -1283,7 +1283,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -2106,7 +2106,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign_prod.snap b/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign_prod.snap index abc88848b..c501fd80b 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign_prod.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_ssldotcom_windows_sign_prod.snap @@ -1283,7 +1283,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -2106,7 +2106,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_tag_namespace.snap b/cargo-dist/tests/snapshots/axolotlsay_tag_namespace.snap index 194b66355..a259cc6e4 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_tag_namespace.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_tag_namespace.snap @@ -294,7 +294,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ owo-release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_updaters.snap b/cargo-dist/tests/snapshots/axolotlsay_updaters.snap index d22bf0c60..f12600b14 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_updaters.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_updaters.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3734,7 +3734,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_global_build_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_global_build_job.snap index e011e82dd..51fd2486b 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_global_build_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_global_build_job.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3616,7 +3616,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_host_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_host_job.snap index 347470d91..1dfe280d1 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_host_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_host_job.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3616,7 +3616,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_local_build_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_local_build_job.snap index be5530167..a353a2c3f 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_local_build_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_local_build_job.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3616,7 +3616,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_plan_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_plan_job.snap index e81ce0254..4d3607d97 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_plan_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_plan_job.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3616,7 +3616,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/axolotlsay_user_publish_job.snap b/cargo-dist/tests/snapshots/axolotlsay_user_publish_job.snap index 6782a5a21..dd592e26c 100644 --- a/cargo-dist/tests/snapshots/axolotlsay_user_publish_job.snap +++ b/cargo-dist/tests/snapshots/axolotlsay_user_publish_job.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" @@ -3616,7 +3616,7 @@ CENSORED (see https://github.com/axodotdev/cargo-dist/issues/1477) CENSORED.tar. } ================ release.yml ================ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 diff --git a/cargo-dist/tests/snapshots/error_manifest.snap b/cargo-dist/tests/snapshots/error_manifest.snap index 88424f7a1..65768d5db 100644 --- a/cargo-dist/tests/snapshots/error_manifest.snap +++ b/cargo-dist/tests/snapshots/error_manifest.snap @@ -3,14 +3,14 @@ source: cargo-dist/tests/cli-tests.rs expression: format_outputs(&output) --- stdout: -{"diagnostic": {"message": "This workspace doesn't have anything for cargo-dist to Release!","severity": "error","causes": [],"help": "You may need to pass the current version as --tag, or need to give all your packages the same version\n\nHere are some options:\n\n--tag=v1.0.0-FAKEVERSION will Announce: cargo-dist\n\nyou can also request any single package with --tag=cargo-dist-v1.0.0-FAKEVERSION\n","labels": [],"related": []}} +{"diagnostic": {"message": "This workspace doesn't have anything for dist to Release!","severity": "error","causes": [],"help": "You may need to pass the current version as --tag, or need to give all your packages the same version\n\nHere are some options:\n\n--tag=v1.0.0-FAKEVERSION will Announce: cargo-dist\n\nyou can also request any single package with --tag=cargo-dist-v1.0.0-FAKEVERSION\n","labels": [],"related": []}} stderr: INFO: You've enabled Axo Releases, which is currently in Closed Beta. If you haven't yet signed up, please join our discord (https://discord.gg/ECnWuUUXQk) or message hello@axo.dev to get started! - × This workspace doesn't have anything for cargo-dist to Release! + × This workspace doesn't have anything for dist to Release! help: You may need to pass the current version as --tag, or need to give all your packages the same version Here are some options: diff --git a/cargo-dist/tests/snapshots/install_path_cargo_home.snap b/cargo-dist/tests/snapshots/install_path_cargo_home.snap index e3b3d894a..59969057f 100644 --- a/cargo-dist/tests/snapshots/install_path_cargo_home.snap +++ b/cargo-dist/tests/snapshots/install_path_cargo_home.snap @@ -1348,7 +1348,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_env_no_subdir.snap b/cargo-dist/tests/snapshots/install_path_env_no_subdir.snap index 0fc0d36ef..fcf3569cf 100644 --- a/cargo-dist/tests/snapshots/install_path_env_no_subdir.snap +++ b/cargo-dist/tests/snapshots/install_path_env_no_subdir.snap @@ -1331,7 +1331,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_env_subdir.snap b/cargo-dist/tests/snapshots/install_path_env_subdir.snap index 4137190f7..bf563131a 100644 --- a/cargo-dist/tests/snapshots/install_path_env_subdir.snap +++ b/cargo-dist/tests/snapshots/install_path_env_subdir.snap @@ -1331,7 +1331,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_env_subdir_space.snap b/cargo-dist/tests/snapshots/install_path_env_subdir_space.snap index b83429e6a..d9fb4b31b 100644 --- a/cargo-dist/tests/snapshots/install_path_env_subdir_space.snap +++ b/cargo-dist/tests/snapshots/install_path_env_subdir_space.snap @@ -1331,7 +1331,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_env_subdir_space_deeper.snap b/cargo-dist/tests/snapshots/install_path_env_subdir_space_deeper.snap index 8089adaa5..05f19fa7c 100644 --- a/cargo-dist/tests/snapshots/install_path_env_subdir_space_deeper.snap +++ b/cargo-dist/tests/snapshots/install_path_env_subdir_space_deeper.snap @@ -1331,7 +1331,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_fallback_no_env_var_set.snap b/cargo-dist/tests/snapshots/install_path_fallback_no_env_var_set.snap index f3fa4af43..516b894ff 100644 --- a/cargo-dist/tests/snapshots/install_path_fallback_no_env_var_set.snap +++ b/cargo-dist/tests/snapshots/install_path_fallback_no_env_var_set.snap @@ -1345,7 +1345,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_home_subdir_deeper.snap b/cargo-dist/tests/snapshots/install_path_home_subdir_deeper.snap index d85e2088e..5dee258d7 100644 --- a/cargo-dist/tests/snapshots/install_path_home_subdir_deeper.snap +++ b/cargo-dist/tests/snapshots/install_path_home_subdir_deeper.snap @@ -1331,7 +1331,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_home_subdir_min.snap b/cargo-dist/tests/snapshots/install_path_home_subdir_min.snap index 56b2223a6..97df59315 100644 --- a/cargo-dist/tests/snapshots/install_path_home_subdir_min.snap +++ b/cargo-dist/tests/snapshots/install_path_home_subdir_min.snap @@ -1331,7 +1331,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_home_subdir_space.snap b/cargo-dist/tests/snapshots/install_path_home_subdir_space.snap index 7a58c8eee..b88f8ad36 100644 --- a/cargo-dist/tests/snapshots/install_path_home_subdir_space.snap +++ b/cargo-dist/tests/snapshots/install_path_home_subdir_space.snap @@ -1331,7 +1331,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_home_subdir_space_deeper.snap b/cargo-dist/tests/snapshots/install_path_home_subdir_space_deeper.snap index a362a1424..73fa9496c 100644 --- a/cargo-dist/tests/snapshots/install_path_home_subdir_space_deeper.snap +++ b/cargo-dist/tests/snapshots/install_path_home_subdir_space_deeper.snap @@ -1331,7 +1331,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/install_path_no_fallback_taken.snap b/cargo-dist/tests/snapshots/install_path_no_fallback_taken.snap index 62b88e0d5..722c66bc3 100644 --- a/cargo-dist/tests/snapshots/install_path_no_fallback_taken.snap +++ b/cargo-dist/tests/snapshots/install_path_no_fallback_taken.snap @@ -1345,7 +1345,7 @@ function Install-Binary($install_args) { Initialize-Environment - # Platform info injected by cargo-dist + # Platform info injected by dist $platforms = @{ "aarch64-pc-windows-msvc" = @{ "artifact_name" = "axolotlsay-x86_64-pc-windows-msvc.tar.gz" diff --git a/cargo-dist/tests/snapshots/long-help.snap b/cargo-dist/tests/snapshots/long-help.snap index 12bae8a19..63d08dd98 100644 --- a/cargo-dist/tests/snapshots/long-help.snap +++ b/cargo-dist/tests/snapshots/long-help.snap @@ -12,7 +12,7 @@ Usage: dist [OPTIONS] Commands: build Build artifacts - init Setup or update cargo-dist + init Setup or update dist generate Generate one or more pieces of configuration linkage Report on the dynamic libraries used by the built artifacts manifest Generate the final build manifest without running any builds @@ -74,7 +74,7 @@ GLOBAL OPTIONS: - github: Generate github CI that uploads to github releases --tag - The (git) tag to use for the Announcement that each invocation of cargo-dist is performing. + The (git) tag to use for the Announcement that each invocation of dist is performing. This tag serves two purposes: defining which apps we are Announcing new Releases for (and therefore building binaries and installers for); and picking an id to use for certain URLs. For instance the git tag associated with a Github Release is part of the URL to fetch artifacts from that release, which needs to be known by some installers! diff --git a/cargo-dist/tests/snapshots/markdown-help.snap b/cargo-dist/tests/snapshots/markdown-help.snap index ab4dc3739..7487087cd 100644 --- a/cargo-dist/tests/snapshots/markdown-help.snap +++ b/cargo-dist/tests/snapshots/markdown-help.snap @@ -20,7 +20,7 @@ dist ### Commands * [build](#cargo-dist-build): Build artifacts -* [init](#cargo-dist-init): Setup or update cargo-dist +* [init](#cargo-dist-init): Setup or update dist * [generate](#cargo-dist-generate): Generate one or more pieces of configuration * [linkage](#cargo-dist-linkage): Report on the dynamic libraries used by the built artifacts * [manifest](#cargo-dist-manifest): Generate the final build manifest without running any builds @@ -76,7 +76,7 @@ Possible values: - github: Generate github CI that uploads to github releases #### `--tag ` -The (git) tag to use for the Announcement that each invocation of cargo-dist is performing. +The (git) tag to use for the Announcement that each invocation of dist is performing. This tag serves two purposes: defining which apps we are Announcing new Releases for (and therefore building binaries and installers for); and picking an id to use for certain URLs. For instance the git tag associated with a Github Release is part of the URL to fetch artifacts from that release, which needs to be known by some installers! @@ -114,7 +114,7 @@ Which subset of the Artifacts to build Artifacts can be broken up into two major classes: "local" ones, which are made for each target system (archives, symbols, msi installers...); and "global" ones, which are made once per app (curl-sh installers, npm package, metadata...). -Having this distinction lets us run cargo-dist independently on multiple machines without collisions between the outputs. +Having this distinction lets us run dist independently on multiple machines without collisions between the outputs. If let unspecified, we will pick a fuzzier "host" mode that builds "as much as possible" for the local system. This mode is appropriate for local testing/debugging/demoing. If no --target flags are passed on the CLI then "host" mode will try to intelligently guess which targets to build for, which may include building targets that aren't defined in your metadata.dist config (since that config may exclude the current machine!). @@ -142,9 +142,9 @@ This subcommand accepts all the [global options](#global-options)


## cargo dist init -Setup or update cargo-dist +Setup or update dist -This will interactively guide you through the process of selecting configuration options and will also automatically run 'cargo dist generate' afterwards as necessary. It will also handle updating your project to a new version of cargo-dist if you're running one. +This will interactively guide you through the process of selecting configuration options and will also automatically run 'dist generate' afterwards as necessary. It will also handle updating your project to a new version of dist if you're running one. ### Usage @@ -196,7 +196,7 @@ dist generate [OPTIONS] Which type of configuration to generate Possible values: -- ci: Generate CI scripts for orchestrating cargo-dist +- ci: Generate CI scripts for orchestrating dist - msi: Generate .wxs tempaltes for msi installers #### `--check` @@ -238,7 +238,7 @@ This subcommand accepts all the [global options](#global-options) ## cargo dist manifest Generate the final build manifest without running any builds. -This command is designed to match the exact behaviour of 'cargo dist build' when passed the same flags, which is nice for consistency but annoying for anyone who doesn't understand cargo-dist's design really well. +This command is designed to match the exact behaviour of 'dist build' when passed the same flags, which is nice for consistency but annoying for anyone who doesn't understand dist's design really well. Notably it will default to only talking about artifacts for the host system, and will produce paths to the build dir that may not exist (since the build wasn't run). @@ -256,7 +256,7 @@ Which subset of the Artifacts to build Artifacts can be broken up into two major classes: "local" ones, which are made for each target system (archives, symbols, msi installers...); and "global" ones, which are made once per app (curl-sh installers, npm package, metadata...). -Having this distinction lets us run cargo-dist independently on multiple machines without collisions between the outputs. +Having this distinction lets us run dist independently on multiple machines without collisions between the outputs. If let unspecified, we will pick a fuzzier "host" mode that builds "as much as possible" for the local system. This mode is appropriate for local testing/debugging/demoing. If no --target flags are passed on the CLI then "host" mode will try to intelligently guess which targets to build for, which may include building targets that aren't defined in your metadata.dist config (since that config may exclude the current machine!). @@ -286,7 +286,7 @@ This subcommand accepts all the [global options](#global-options) ## cargo dist plan Get a plan of what to build (and check project status) -If you want to know what running your cargo-dist CI will produce, this is the command for you! This is the exact command that CI will run to make its build plan and generate dist-manifest.json (although it adds --output-format=json so that it's machine-readable). +If you want to know what running your dist CI will produce, this is the command for you! This is the exact command that CI will run to make its build plan and generate dist-manifest.json (although it adds --output-format=json so that it's machine-readable). This is an alias for the lower-level 'manifest' command with the appropriate flags forced for asking for "everything" @@ -392,7 +392,7 @@ dist help [COMMAND] ### Commands * [build](#cargo-dist-build): Build artifacts -* [init](#cargo-dist-init): Setup or update cargo-dist +* [init](#cargo-dist-init): Setup or update dist * [generate](#cargo-dist-generate): Generate one or more pieces of configuration * [linkage](#cargo-dist-linkage): Report on the dynamic libraries used by the built artifacts * [manifest](#cargo-dist-manifest): Generate the final build manifest without running any builds diff --git a/cargo-dist/tests/snapshots/short-help.snap b/cargo-dist/tests/snapshots/short-help.snap index f2c0f5719..a066662db 100644 --- a/cargo-dist/tests/snapshots/short-help.snap +++ b/cargo-dist/tests/snapshots/short-help.snap @@ -10,7 +10,7 @@ Usage: dist [OPTIONS] Commands: build Build artifacts - init Setup or update cargo-dist + init Setup or update dist generate Generate one or more pieces of configuration linkage Report on the dynamic libraries used by the built artifacts manifest Generate the final build manifest without running any builds @@ -30,7 +30,7 @@ GLOBAL OPTIONS: -t, --target Target triples we want to build -i, --installer Installers we want to build [possible values: shell, powershell, npm, homebrew, msi] -c, --ci CI we want to support [possible values: github] - --tag The (git) tag to use for the Announcement that each invocation of cargo-dist is performing + --tag The (git) tag to use for the Announcement that each invocation of dist is performing --force-tag Force package versions to match the tag --allow-dirty Allow generated files like CI scripts to be out of date From 11fd9a62e8b47d85c443da3902c6b0a12ed8bfa2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Wed, 23 Oct 2024 11:50:09 -0700 Subject: [PATCH 09/15] chore: replace cargo dist with dist --- README.md | 4 +-- axoproject/src/lib.rs | 2 +- cargo-dist/src/backend/installer/msi.rs | 8 +++--- cargo-dist/src/cli.rs | 24 ++++++++--------- cargo-dist/src/config/mod.rs | 2 +- cargo-dist/src/errors.rs | 20 +++++++------- cargo-dist/src/host.rs | 2 +- cargo-dist/src/init.rs | 12 ++++----- cargo-dist/src/lib.rs | 10 +++---- cargo-dist/src/linkage.rs | 6 ++--- cargo-dist/src/main.rs | 8 +++--- cargo-dist/src/tasks.rs | 8 +++--- cargo-dist/src/tests/config.rs | 10 +++---- cargo-dist/tests/gallery/dist.rs | 16 ++++++------ cargo-dist/tests/snapshots/long-help.snap | 8 +++--- cargo-dist/tests/snapshots/markdown-help.snap | 26 +++++++++---------- 16 files changed, 82 insertions(+), 84 deletions(-) diff --git a/README.md b/README.md index 3ba059a80..48c24e398 100644 --- a/README.md +++ b/README.md @@ -49,7 +49,7 @@ That's a short list because "we make [installers][]" is doing a lot of heavy lif ## Distributing -As a distribution tool, dist gets to flex its biggest superpower: **it generates [its own CI scripts][ci-providers]**. For instance, enabling [GitHub CI][ci-providers] with `cargo dist init` will generate release.yml, which implements the full pipeline of plan, build, host, publish, announce: +As a distribution tool, dist gets to flex its biggest superpower: **it generates [its own CI scripts][ci-providers]**. For instance, enabling [GitHub CI][ci-providers] with `dist init` will generate release.yml, which implements the full pipeline of plan, build, host, publish, announce: * Plan * Waits for you to push a git tag for a new version (v1.0.0, my-app-v1.0.0, my-app/1.0.0, ...) @@ -123,7 +123,7 @@ should never edit that name, the tools will update it as needed. If that releases succeeds, we recommend updating the bootstrap version of dist as a follow up: * install the version of dist you just released on your system -* run `cargo dist init --yes` +* run `dist init --yes` * commit "chore: update bootstrap dist to ..." Note that as a consequence of the way we self-host, dist's published artifacts will always be built/generated by a previous version of itself. This can be problematic if you make breaking changes to cargo-dist-schema's format... so don't! Many things in the schema are intentionally optional to enable forward and backward compatibility, so this should hopefully work well! diff --git a/axoproject/src/lib.rs b/axoproject/src/lib.rs index 3e3d83f6a..ed1763faf 100644 --- a/axoproject/src/lib.rs +++ b/axoproject/src/lib.rs @@ -460,7 +460,7 @@ pub struct PackageInfo { /// might also use it for auto-detecting "hey you're using github, here's the /// recommended github setup". /// - /// i.e. `cargo dist init --installer=shell` uses this as the base URL for fetching from + /// i.e. `dist init --installer=shell` uses this as the base URL for fetching from /// a Github Release™️. pub repository_url: Option, /// URL to the homepage for this package. diff --git a/cargo-dist/src/backend/installer/msi.rs b/cargo-dist/src/backend/installer/msi.rs index 9bef9ce8f..67ae374e8 100644 --- a/cargo-dist/src/backend/installer/msi.rs +++ b/cargo-dist/src/backend/installer/msi.rs @@ -32,8 +32,8 @@ pub struct MsiInstallerInfo { impl MsiInstallerInfo { /// Build the msi installer /// - /// Note that this assumes `write_wsx_to_disk` was run beforehand (via `cargo dist generate`), - /// which should be enforced by `check_wsx` (via `cargo dist generate --check`). + /// Note that this assumes `write_wsx_to_disk` was run beforehand (via `dist generate`), + /// which should be enforced by `check_wsx` (via `dist generate --check`). pub fn build(&self, dist: &DistGraph) -> DistResult<()> { info!("building an msi: {}", self.file_path); @@ -86,13 +86,13 @@ impl MsiInstallerInfo { Ok(renders) } - /// msi's impl of `cargo dist genenerate --check` + /// msi's impl of `dist genenerate --check` pub fn check_config(&self) -> DistResult<()> { self.check_wix_guids()?; self.check_wxs()?; Ok(()) } - /// msi's impl of `cargo dist genenerate` + /// msi's impl of `dist genenerate` pub fn write_config_to_disk(&self) -> DistResult<()> { self.write_wix_guids_to_disk()?; self.write_wxs_to_disk()?; diff --git a/cargo-dist/src/cli.rs b/cargo-dist/src/cli.rs index 26367bba6..1c600aa08 100644 --- a/cargo-dist/src/cli.rs +++ b/cargo-dist/src/cli.rs @@ -38,7 +38,7 @@ pub struct Cli { /// /// This is useful for generating a clean "full" manifest as follows: /// - /// `cargo dist manifest --artifacts=all --output-format=json --no-local-paths` + /// `dist manifest --artifacts=all --output-format=json --no-local-paths` #[clap(long)] #[clap(help_heading = "GLOBAL OPTIONS", global = true)] pub no_local_paths: bool, @@ -46,7 +46,7 @@ pub struct Cli { /// Target triples we want to build /// /// If left unspecified we will use the values in [workspace.metadata.dist], - /// except for `cargo dist init` which will select some "good defaults" for you. + /// except for `dist init` which will select some "good defaults" for you. #[clap(long, short, value_delimiter(','))] #[clap(help_heading = "GLOBAL OPTIONS", global = true)] pub target: Vec, @@ -54,7 +54,7 @@ pub struct Cli { /// Installers we want to build /// /// If left unspecified we will use the values in [workspace.metadata.dist]. - /// `cargo dist init` will persist the values you pass to that location. + /// `dist init` will persist the values you pass to that location. #[clap(long, short, value_delimiter(','))] #[clap(help_heading = "GLOBAL OPTIONS", global = true)] pub installer: Vec, @@ -62,7 +62,7 @@ pub struct Cli { /// CI we want to support /// /// If left unspecified we will use the value in [workspace.metadata.dist]. - /// `cargo dist init` will persist the values you pass to that location. + /// `dist init` will persist the values you pass to that location. #[clap(long, short, value_delimiter(','))] #[clap(help_heading = "GLOBAL OPTIONS", global = true)] pub ci: Vec, @@ -139,7 +139,7 @@ pub enum Commands { /// for the host system, and will produce paths to the build dir /// that may not exist (since the build wasn't run). /// - /// 'cargo dist plan' is an alias for this command that picks nicer defaults + /// 'dist plan' is an alias for this command that picks nicer defaults /// by forcing a couple flags to have specific values. You probably want that. #[clap(disable_version_flag = true)] Manifest(ManifestArgs), @@ -163,7 +163,7 @@ pub enum Commands { /// This is an alias for the lower-level 'manifest' command with the /// appropriate flags forced for asking for "everything" /// - /// cargo dist manifest --artifacts=all --no-local-paths + /// dist manifest --artifacts=all --no-local-paths /// #[clap(disable_version_flag = true)] Plan(PlanArgs), @@ -217,7 +217,7 @@ pub enum ArtifactMode { Global, /// Fuzzily build "as much as possible" for the host system Host, - /// Build all the artifacts; useful for `cargo dist manifest` + /// Build all the artifacts; useful for `dist manifest` All, /// Fake all the artifacts; useful for testing/mocking/staging Lies, @@ -248,7 +248,7 @@ pub struct InitArgs { /// during the interactive prompts. #[clap(long, short)] pub yes: bool, - /// Skip running 'cargo dist generate' at the end + /// Skip running 'dist generate' at the end #[clap(long, alias = "no-generate-ci", alias = "no-generate")] pub skip_generate: bool, /// A path to a json file containing values to set in workspace.metadata.dist @@ -264,7 +264,7 @@ pub struct InitArgs { /// /// If left unspecified we will use the value in [workspace.metadata.dist]. /// (If no such value exists we will use the one "native" to your CI provider) - /// `cargo dist init` will persist the values you pass to that location. + /// `dist init` will persist the values you pass to that location. #[clap(long, value_delimiter(','))] pub hosting: Vec, } @@ -347,10 +347,10 @@ pub struct UpdateArgs { /// during the interactive prompts. #[clap(long, short)] pub yes: bool, - /// Skip running 'cargo dist init' after performing an upgrade + /// Skip running 'dist init' after performing an upgrade #[clap(long)] pub skip_init: bool, - /// Skip running 'cargo dist generate' at the end + /// Skip running 'dist generate' at the end #[clap(long, alias = "no-generate-ci", alias = "no-generate")] pub skip_generate: bool, /// A path to a json file containing values to set in workspace.metadata.dist @@ -366,7 +366,7 @@ pub struct UpdateArgs { /// /// If left unspecified we will use the value in [workspace.metadata.dist]. /// (If no such value exists we will use the one "native" to your CI provider) - /// `cargo dist init` will persist the values you pass to that location. + /// `dist init` will persist the values you pass to that location. #[clap(long, value_delimiter(','))] pub hosting: Vec, } diff --git a/cargo-dist/src/config/mod.rs b/cargo-dist/src/config/mod.rs index 472ba0158..d6baa13d0 100644 --- a/cargo-dist/src/config/mod.rs +++ b/cargo-dist/src/config/mod.rs @@ -695,7 +695,7 @@ impl std::fmt::Display for GenerateMode { } } -/// Arguments to `cargo dist host` +/// Arguments to `dist host` #[derive(Clone, Debug)] pub struct HostArgs { /// Which hosting steps to run diff --git a/cargo-dist/src/errors.rs b/cargo-dist/src/errors.rs index c2f7a5840..8dc2127d0 100644 --- a/cargo-dist/src/errors.rs +++ b/cargo-dist/src/errors.rs @@ -238,7 +238,7 @@ pub enum DistError { /// Not an error; indicates that a file's contents differ via --check #[error("{} has out of date contents and needs to be regenerated:\n{diff}", file.origin_path())] - #[diagnostic(help("run 'cargo dist init' to update the file\n('allow-dirty' in Cargo.toml to ignore out of date contents)"))] + #[diagnostic(help("run 'dist init' to update the file\n('allow-dirty' in Cargo.toml to ignore out of date contents)"))] CheckFileMismatch { /// The file whose contents differ file: axoasset::SourceFile, @@ -246,7 +246,7 @@ pub enum DistError { diff: String, }, - /// `cargo dist generate` was passed an explicit GenerateMode but the config in their Cargo.toml + /// `dist generate` was passed an explicit GenerateMode but the config in their Cargo.toml /// has that mode set to allow-dirty, a contradiction! #[error("'{generate_mode}' is marked as allow-dirty in your dist config, refusing to run")] ContradictoryGenerateModes { @@ -274,9 +274,9 @@ pub enum DistError { artifact_name: String, }, - /// These GUIDs for msi's are required and enforced by `cargo dist generate --check` + /// These GUIDs for msi's are required and enforced by `dist generate --check` #[error("missing WiX GUIDs in {manifest_path}: {keys:?}")] - #[diagnostic(help("run 'cargo dist init' to generate them"))] + #[diagnostic(help("run 'dist init' to generate them"))] MissingWixGuids { /// The Cargo.toml missing them manifest_path: Utf8PathBuf, @@ -381,13 +381,13 @@ pub enum DistError { bin_name: String, }, - /// Error during `cargo dist selfupdate` - #[error("`cargo dist selfupdate` failed; the new version isn't in the place we expected")] + /// Error during `dist selfupdate` + #[error("`dist selfupdate` failed; the new version isn't in the place we expected")] #[diagnostic(help("This is probably not your fault, please file an issue!"))] UpdateFailed {}, - /// Trying to run cargo dist selfupdate in a random dir - #[error("`cargo dist selfupdate` needs to be run in a project")] + /// Trying to run dist selfupdate in a random dir + #[error("`dist selfupdate` needs to be run in a project")] #[diagnostic(help("If you just want to update dist and not your project, pass --skip-init"))] UpdateNotInWorkspace { /// The report about the missing workspace @@ -409,12 +409,12 @@ pub enum DistError { }, /// Workspace isn't init - #[error("please run 'cargo dist init' before running any other commands!")] + #[error("please run 'dist init' before running any other commands!")] NeedsInit, /// Running different version from config #[error("You're running dist {running_version}, but 'cargo-dist-version = {config_version}' is set in your Cargo.toml")] - #[diagnostic(help("Rerun 'cargo dist init' to update to this version."))] + #[diagnostic(help("Rerun 'dist init' to update to this version."))] MismatchedDistVersion { /// config version config_version: String, diff --git a/cargo-dist/src/host.rs b/cargo-dist/src/host.rs index 9e2f71271..ef888cf23 100644 --- a/cargo-dist/src/host.rs +++ b/cargo-dist/src/host.rs @@ -129,7 +129,7 @@ impl<'a> DistGraphBuilder<'a> { let name = package.name.clone(); // Only update them if they don't already have hosting // if create_hosting is set, then consider all entries out of date - // and needing refreshing (this is only set by `cargo dist host create`) + // and needing refreshing (this is only set by `dist host create`) let needs_hosting = create_hosting || self .manifest diff --git a/cargo-dist/src/init.rs b/cargo-dist/src/init.rs index 6a91ba7b6..1b3d535c0 100644 --- a/cargo-dist/src/init.rs +++ b/cargo-dist/src/init.rs @@ -16,7 +16,7 @@ use crate::{ GenerateArgs, SortedMap, METADATA_DIST, PROFILE_DIST, }; -/// Arguments for `cargo dist init` ([`do_init`][]) +/// Arguments for `dist init` ([`do_init`][]) #[derive(Debug)] pub struct InitArgs { /// Whether to auto-accept the default values for interactive prompts @@ -52,7 +52,7 @@ fn theme() -> dialoguer::theme::ColorfulTheme { } } -/// Run 'cargo dist init' +/// Run 'dist init' pub fn do_init(cfg: &Config, args: &InitArgs) -> DistResult<()> { // on ctrl-c, dialoguer/console will clean up the rest of its // formatting, but the cursor will remain hidden unless we @@ -262,7 +262,7 @@ pub fn do_init(cfg: &Config, args: &InitArgs) -> DistResult<()> { // regenerate anything that needs to be if !args.no_generate { - eprintln!("running 'cargo dist generate' to apply any changes"); + eprintln!("running 'dist generate' to apply any changes"); eprintln!(); let ci_args = GenerateArgs { @@ -310,7 +310,7 @@ fn init_dist_profile( new_profile.insert("lto", toml_edit::value("thin")); new_profile .decor_mut() - .set_prefix("\n# The profile that 'cargo dist' will build with\n") + .set_prefix("\n# The profile that 'dist' will build with\n") } dist_profile.or_insert(new_profile); @@ -1293,9 +1293,7 @@ fn apply_dist_to_metadata(metadata: &mut toml_edit::Item, meta: &DistMetadata) { ); // Finalize the table - table - .decor_mut() - .set_prefix("\n# Config for 'cargo dist'\n"); + table.decor_mut().set_prefix("\n# Config for 'dist'\n"); } /// Update the toml table to add/remove this value diff --git a/cargo-dist/src/lib.rs b/cargo-dist/src/lib.rs index d71649c93..15ceee366 100644 --- a/cargo-dist/src/lib.rs +++ b/cargo-dist/src/lib.rs @@ -55,7 +55,7 @@ pub mod tasks; #[cfg(test)] mod tests; -/// cargo dist build -- actually build binaries and installers! +/// dist build -- actually build binaries and installers! pub fn do_build(cfg: &Config) -> DistResult { check_integrity(cfg)?; @@ -100,7 +100,7 @@ pub fn do_build(cfg: &Config) -> DistResult { Ok(manifest) } -/// Just generate the manifest produced by `cargo dist build` without building +/// Just generate the manifest produced by `dist build` without building pub fn do_manifest(cfg: &Config) -> DistResult { check_integrity(cfg)?; let (_dist, manifest) = gather_work(cfg)?; @@ -616,7 +616,7 @@ fn zip_dir( Ok(()) } -/// Arguments for `cargo dist generate` ([`do_generate`][]) +/// Arguments for `dist generate` ([`do_generate`][]) #[derive(Debug)] pub struct GenerateArgs { /// Check whether the output differs without writing to disk @@ -652,7 +652,7 @@ fn do_generate_preflight_checks(dist: &DistGraph) -> DistResult<()> { Ok(()) } -/// Generate any scripts which are relevant (impl of `cargo dist generate`) +/// Generate any scripts which are relevant (impl of `dist generate`) pub fn do_generate(cfg: &Config, args: &GenerateArgs) -> DistResult<()> { let (dist, _manifest) = gather_work(cfg)?; @@ -720,7 +720,7 @@ pub fn run_generate(dist: &DistGraph, args: &GenerateArgs) -> DistResult<()> { /// Run any necessary integrity checks for "primary" commands like build/plan /// -/// (This is currently equivalent to `cargo dist generate --check`) +/// (This is currently equivalent to `dist generate --check`) pub fn check_integrity(cfg: &Config) -> DistResult<()> { // We need to avoid overwriting any parts of configuration from CLI here, // so construct a clean copy of config to run the check generate diff --git a/cargo-dist/src/linkage.rs b/cargo-dist/src/linkage.rs index aa7c715a9..9ac357a08 100644 --- a/cargo-dist/src/linkage.rs +++ b/cargo-dist/src/linkage.rs @@ -21,7 +21,7 @@ use crate::{ config::Config, errors::*, gather_work, platform::targets::TARGET_HOST, Artifact, DistGraph, }; -/// Arguments for `cargo dist linkage` ([`do_linkage][]) +/// Arguments for `dist linkage` ([`do_linkage][]) #[derive(Debug)] pub struct LinkageArgs { /// Print human-readable output @@ -32,7 +32,7 @@ pub struct LinkageArgs { pub from_json: Option, } -/// Determinage dynamic linkage of built artifacts (impl of `cargo dist linkage`) +/// Determinage dynamic linkage of built artifacts (impl of `dist linkage`) pub fn do_linkage(cfg: &Config, args: &LinkageArgs) -> DistResult<()> { let manifest = if let Some(target) = args.from_json.clone() { let file = SourceFile::load_local(target)?; @@ -53,7 +53,7 @@ pub fn do_linkage(cfg: &Config, args: &LinkageArgs) -> DistResult<()> { Ok(()) } -/// Assuming someone just ran `cargo dist build` on the current machine, +/// Assuming someone just ran `dist build` on the current machine, /// compute the linkage by checking binaries in the temp to-be-zipped dirs. fn compute_linkage_assuming_local_build( dist: &DistGraph, diff --git a/cargo-dist/src/main.rs b/cargo-dist/src/main.rs index 848e5aa6b..13609ed52 100644 --- a/cargo-dist/src/main.rs +++ b/cargo-dist/src/main.rs @@ -24,7 +24,7 @@ use crate::cli::{BuildArgs, GenerateArgs, GenerateCiArgs, InitArgs, LinkageArgs} mod cli; fn main() { - // Pop extraneous "dist" argument that `cargo dist` passes to us + // Pop extraneous "dist" argument that `dist` passes to us let mut args: Vec = std::env::args_os().collect(); if args.get(1).map(|arg| arg == "dist").unwrap_or(false) { args.remove(1); @@ -75,7 +75,7 @@ fn print( // Add some context if we're printing predicted paths if let Some(name) = warn_cmd { if !cli.no_local_paths { - let message = format!("\nNOTE: 'cargo dist {name}' does not perform builds, these paths may not exist yet!"); + let message = format!("\nNOTE: 'dist {name}' does not perform builds, these paths may not exist yet!"); writeln!(out, "{}", out.style().yellow().apply_to(message)) .into_diagnostic()?; } @@ -561,7 +561,7 @@ fn this_cargo_dist_provided_by_brew() -> bool { } fn perform_init(path: &Utf8PathBuf, args: &cli::UpdateArgs) -> Result<(), miette::ErrReport> { - let mut cmd = Cmd::new(path, "cargo dist init"); + let mut cmd = Cmd::new(path, "dist init"); cmd.arg("dist").arg("init"); // Forward shared arguments as necessary if args.yes { @@ -634,7 +634,7 @@ async fn cmd_update(_config: &Cli, args: &cli::UpdateArgs) -> Result<(), miette: } if !updater.check_receipt_is_for_this_executable()? { - eprintln!("This installation of cargo-dist wasn't installed via a method that `cargo dist selfupdate` supports."); + eprintln!("This installation of dist wasn't installed via a method that `dist selfupdate` supports."); eprintln!("Please update manually."); return Ok(()); } diff --git a/cargo-dist/src/tasks.rs b/cargo-dist/src/tasks.rs index fa758c246..21024cbf6 100644 --- a/cargo-dist/src/tasks.rs +++ b/cargo-dist/src/tasks.rs @@ -190,7 +190,7 @@ pub struct DistGraph { /// two machines have any reason to have the exact same CLI args for dist, we /// just use a mangled form of the CLI arguments here. pub system_id: SystemId, - /// Whether it looks like `cargo dist init` has been run + /// Whether it looks like `dist init` has been run pub is_init: bool, /// What to allow to be dirty pub allow_dirty: DirtyMode, @@ -906,7 +906,7 @@ impl<'pkg_graph> DistGraphBuilder<'pkg_graph> { }; // check homebrew taps for global publish jobs - // FIXME: when we add `cargo dist publish` we can drop this, + // FIXME: when we add `dist publish` we can drop this, // as we can support granular publish settings let mut global_homebrew_tap = None; let mut packages_with_mismatched_taps = vec![]; @@ -944,7 +944,7 @@ impl<'pkg_graph> DistGraphBuilder<'pkg_graph> { } // check publish jobs for global publish jobs - // FIXME: when we add `cargo dist publish` we can drop this, + // FIXME: when we add `dist publish` we can drop this, // as we can support granular publish settings let mut global_publishers = None; let mut packages_with_mismatched_publishers = vec![]; @@ -979,7 +979,7 @@ impl<'pkg_graph> DistGraphBuilder<'pkg_graph> { let global_publish_prereleases = global_publishers .as_ref() .map(|p| { - // until we have `cargo dist publish` we need to enforce everyone agreeing on `prereleases` + // until we have `dist publish` we need to enforce everyone agreeing on `prereleases` let PublisherConfig { homebrew, npm } = p; let h_pre = homebrew.as_ref().map(|p| p.prereleases); let npm_pre = npm.as_ref().map(|p| p.prereleases); diff --git a/cargo-dist/src/tests/config.rs b/cargo-dist/src/tests/config.rs index f9577eec5..b4b5a5025 100644 --- a/cargo-dist/src/tests/config.rs +++ b/cargo-dist/src/tests/config.rs @@ -58,7 +58,7 @@ fn basic_cargo_toml_no_change() { name = "whatever" version = "1.0.0" -# Config for 'cargo dist' +# Config for 'dist' [workspace.metadata.dist] # The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" @@ -114,7 +114,7 @@ fn basic_cargo_toml_one_item_arrays() { name = "whatever" version = "1.0.0" -# Config for 'cargo dist' +# Config for 'dist' [workspace.metadata.dist] # The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" @@ -133,7 +133,7 @@ targets = ["aarch64-apple-darwin"] name = "whatever" version = "1.0.0" -# Config for 'cargo dist' +# Config for 'dist' [workspace.metadata.dist] # The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" @@ -166,7 +166,7 @@ fn basic_cargo_toml_multi_item_arrays() { name = "whatever" version = "1.0.0" -# Config for 'cargo dist' +# Config for 'dist' [workspace.metadata.dist] # The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" @@ -185,7 +185,7 @@ targets = ["aarch64-apple-darwin", "x86_64-apple-darwin"] name = "whatever" version = "1.0.0" -# Config for 'cargo dist' +# Config for 'dist' [workspace.metadata.dist] # The preferred dist version to use in CI (Cargo.toml SemVer syntax) cargo-dist-version = "0.13.1-prerelease.1" diff --git a/cargo-dist/tests/gallery/dist.rs b/cargo-dist/tests/gallery/dist.rs index 4531a5a32..874d7687c 100644 --- a/cargo-dist/tests/gallery/dist.rs +++ b/cargo-dist/tests/gallery/dist.rs @@ -124,7 +124,7 @@ pub struct BuildAndPlanResult { } impl<'a> TestContext<'a, Tools> { - /// Run 'cargo dist build -alies --no-local-paths --output-format=json' and return paths to various files that were generated + /// Run 'dist build -alies --no-local-paths --output-format=json' and return paths to various files that were generated pub fn cargo_dist_build_lies(&self, test_name: &str) -> Result { // If the dist target dir exists, delete it to avoid cross-contamination let out_path = Utf8Path::new("target/distrib/"); @@ -133,7 +133,7 @@ impl<'a> TestContext<'a, Tools> { } // build installers - eprintln!("running cargo dist build -aglobal..."); + eprintln!("running dist build -aglobal..."); let output = self.tools.cargo_dist.output_checked(|cmd| { cmd.arg("dist") .arg("build") @@ -161,7 +161,7 @@ impl<'a> TestContext<'a, Tools> { Ok(BuildAndPlanResult { build, plan }) } - /// Run 'cargo dist plan --output-format=json' and return dist-manifest.json + /// Run 'dist plan --output-format=json' and return dist-manifest.json pub fn cargo_dist_plan(&self, test_name: &str) -> Result { let output = self .tools @@ -174,7 +174,7 @@ impl<'a> TestContext<'a, Tools> { raw_json, }) } - /// Run 'cargo dist build -aglobal' and return paths to various files that were generated + /// Run 'dist build -aglobal' and return paths to various files that were generated pub fn cargo_dist_build_global(&self, test_name: &str) -> Result { // If the dist target dir exists, delete it to avoid cross-contamination let out_path = Utf8Path::new("target/distrib/"); @@ -183,7 +183,7 @@ impl<'a> TestContext<'a, Tools> { } // build installers - eprintln!("running cargo dist build -aglobal..."); + eprintln!("running dist build -aglobal..."); self.tools .cargo_dist .output_checked(|cmd| cmd.arg("dist").arg("build").arg("-aglobal"))?; @@ -191,11 +191,11 @@ impl<'a> TestContext<'a, Tools> { self.load_dist_results(test_name, true) } - /// Run 'cargo dist generate' and return paths to various files that were generated + /// Run 'dist generate' and return paths to various files that were generated pub fn cargo_dist_generate(&self, test_name: &str) -> Result { self.cargo_dist_generate_prefixed(test_name, "") } - /// Run 'cargo dist generate' and return paths to various files that were generated + /// Run 'dist generate' and return paths to various files that were generated /// (also apply a prefix to the github filename) pub fn cargo_dist_generate_prefixed( &self, @@ -214,7 +214,7 @@ impl<'a> TestContext<'a, Tools> { } // run generate - eprintln!("running cargo dist generate..."); + eprintln!("running dist generate..."); self.tools .cargo_dist .output_checked(|cmd| cmd.arg("dist").arg("generate"))?; diff --git a/cargo-dist/tests/snapshots/long-help.snap b/cargo-dist/tests/snapshots/long-help.snap index 63d08dd98..342230bed 100644 --- a/cargo-dist/tests/snapshots/long-help.snap +++ b/cargo-dist/tests/snapshots/long-help.snap @@ -46,17 +46,17 @@ GLOBAL OPTIONS: This is useful for generating a clean "full" manifest as follows: - `cargo dist manifest --artifacts=all --output-format=json --no-local-paths` + `dist manifest --artifacts=all --output-format=json --no-local-paths` -t, --target Target triples we want to build - If left unspecified we will use the values in [workspace.metadata.dist], except for `cargo dist init` which will select some "good defaults" for you. + If left unspecified we will use the values in [workspace.metadata.dist], except for `dist init` which will select some "good defaults" for you. -i, --installer Installers we want to build - If left unspecified we will use the values in [workspace.metadata.dist]. `cargo dist init` will persist the values you pass to that location. + If left unspecified we will use the values in [workspace.metadata.dist]. `dist init` will persist the values you pass to that location. Possible values: - shell: Generates a shell script that fetches/installs the right build @@ -68,7 +68,7 @@ GLOBAL OPTIONS: -c, --ci CI we want to support - If left unspecified we will use the value in [workspace.metadata.dist]. `cargo dist init` will persist the values you pass to that location. + If left unspecified we will use the value in [workspace.metadata.dist]. `dist init` will persist the values you pass to that location. Possible values: - github: Generate github CI that uploads to github releases diff --git a/cargo-dist/tests/snapshots/markdown-help.snap b/cargo-dist/tests/snapshots/markdown-help.snap index 7487087cd..da31de933 100644 --- a/cargo-dist/tests/snapshots/markdown-help.snap +++ b/cargo-dist/tests/snapshots/markdown-help.snap @@ -48,17 +48,17 @@ Strip local paths from output (e.g. in the dist manifest json) This is useful for generating a clean "full" manifest as follows: -`cargo dist manifest --artifacts=all --output-format=json --no-local-paths` +`dist manifest --artifacts=all --output-format=json --no-local-paths` #### `-t, --target ` Target triples we want to build -If left unspecified we will use the values in [workspace.metadata.dist], except for `cargo dist init` which will select some "good defaults" for you. +If left unspecified we will use the values in [workspace.metadata.dist], except for `dist init` which will select some "good defaults" for you. #### `-i, --installer ` Installers we want to build -If left unspecified we will use the values in [workspace.metadata.dist]. `cargo dist init` will persist the values you pass to that location. +If left unspecified we will use the values in [workspace.metadata.dist]. `dist init` will persist the values you pass to that location. Possible values: - shell: Generates a shell script that fetches/installs the right build @@ -70,7 +70,7 @@ Possible values: #### `-c, --ci ` CI we want to support -If left unspecified we will use the value in [workspace.metadata.dist]. `cargo dist init` will persist the values you pass to that location. +If left unspecified we will use the value in [workspace.metadata.dist]. `dist init` will persist the values you pass to that location. Possible values: - github: Generate github CI that uploads to github releases @@ -126,7 +126,7 @@ Possible values: - local: Build target-specific artifacts like archives and msi installers - global: Build unique artifacts like curl-sh installers and npm packages - host: Fuzzily build "as much as possible" for the host system -- all: Build all the artifacts; useful for `cargo dist manifest` +- all: Build all the artifacts; useful for `dist manifest` - lies: Fake all the artifacts; useful for testing/mocking/staging #### `-p, --print ` @@ -159,7 +159,7 @@ Automatically accept all recommended/default values This is equivalent to just mashing ENTER over and over during the interactive prompts. #### `--skip-generate` -Skip running 'cargo dist generate' at the end +Skip running 'dist generate' at the end #### `--with-json-config ` A path to a json file containing values to set in workspace.metadata.dist and package.metadata.dist, for building tools that edit these configs. @@ -169,7 +169,7 @@ This is the same toml => json format that `cargo metadata` produces when reporti #### `--hosting ` releases hosting backends we want to support -If left unspecified we will use the value in [workspace.metadata.dist]. (If no such value exists we will use the one "native" to your CI provider) `cargo dist init` will persist the values you pass to that location. +If left unspecified we will use the value in [workspace.metadata.dist]. (If no such value exists we will use the one "native" to your CI provider) `dist init` will persist the values you pass to that location. Possible values: - github: Host on Github Releases @@ -242,7 +242,7 @@ This command is designed to match the exact behaviour of 'dist build' when passe Notably it will default to only talking about artifacts for the host system, and will produce paths to the build dir that may not exist (since the build wasn't run). -'cargo dist plan' is an alias for this command that picks nicer defaults by forcing a couple flags to have specific values. You probably want that. +'dist plan' is an alias for this command that picks nicer defaults by forcing a couple flags to have specific values. You probably want that. ### Usage @@ -268,7 +268,7 @@ Possible values: - local: Build target-specific artifacts like archives and msi installers - global: Build unique artifacts like curl-sh installers and npm packages - host: Fuzzily build "as much as possible" for the host system -- all: Build all the artifacts; useful for `cargo dist manifest` +- all: Build all the artifacts; useful for `dist manifest` - lies: Fake all the artifacts; useful for testing/mocking/staging #### `-p, --print ` @@ -290,7 +290,7 @@ If you want to know what running your dist CI will produce, this is the command This is an alias for the lower-level 'manifest' command with the appropriate flags forced for asking for "everything" -cargo dist manifest --artifacts=all --no-local-paths +dist manifest --artifacts=all --no-local-paths ### Usage @@ -355,10 +355,10 @@ Automatically accept all recommended/default values This is equivalent to just mashing ENTER over and over during the interactive prompts. #### `--skip-init` -Skip running 'cargo dist init' after performing an upgrade +Skip running 'dist init' after performing an upgrade #### `--skip-generate` -Skip running 'cargo dist generate' at the end +Skip running 'dist generate' at the end #### `--with-json-config ` A path to a json file containing values to set in workspace.metadata.dist and package.metadata.dist, for building tools that edit these configs. @@ -368,7 +368,7 @@ This is the same toml => json format that `cargo metadata` produces when reporti #### `--hosting ` releases hosting backends we want to support -If left unspecified we will use the value in [workspace.metadata.dist]. (If no such value exists we will use the one "native" to your CI provider) `cargo dist init` will persist the values you pass to that location. +If left unspecified we will use the value in [workspace.metadata.dist]. (If no such value exists we will use the one "native" to your CI provider) `dist init` will persist the values you pass to that location. Possible values: - github: Host on Github Releases From 1f6e0de1390a4c3333de6c555a5b885425c80b0a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Wed, 23 Oct 2024 11:52:38 -0700 Subject: [PATCH 10/15] chore: rename CLI help --- cargo-dist/src/main.rs | 4 ++-- cargo-dist/tests/snapshots/markdown-help.snap | 22 +++++++++---------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/cargo-dist/src/main.rs b/cargo-dist/src/main.rs index 13609ed52..c93d24cd9 100644 --- a/cargo-dist/src/main.rs +++ b/cargo-dist/src/main.rs @@ -30,7 +30,7 @@ fn main() { args.remove(1); } let config = Cli::parse_from(args); - axocli::CliAppBuilder::new("cargo dist") + axocli::CliAppBuilder::new("dist") .verbose(config.verbose) .json_errors(config.output_format == OutputFormat::Json) .start(config, real_main); @@ -376,7 +376,7 @@ fn print_help_markdown(out: &mut dyn Write) -> std::io::Result<()> { use clap::CommandFactory; let app_name = "cargo-dist"; - let pretty_app_name = "cargo dist"; + let pretty_app_name = "dist"; // Make a new App to get the help message this time. writeln!(out, "# {pretty_app_name} CLI manual")?; diff --git a/cargo-dist/tests/snapshots/markdown-help.snap b/cargo-dist/tests/snapshots/markdown-help.snap index da31de933..9bd66597b 100644 --- a/cargo-dist/tests/snapshots/markdown-help.snap +++ b/cargo-dist/tests/snapshots/markdown-help.snap @@ -3,9 +3,9 @@ source: cargo-dist/tests/cli-tests.rs expression: format_outputs(&output) --- stdout: -# cargo dist CLI manual +# dist CLI manual -> This manual can be regenerated with `cargo dist help-markdown` +> This manual can be regenerated with `dist help-markdown` Shippable packaging for Rust. @@ -99,7 +99,7 @@ Force package versions to match the tag Allow generated files like CI scripts to be out of date


-## cargo dist build +## dist build Build artifacts ### Usage @@ -141,7 +141,7 @@ Print help (see a summary with '-h') This subcommand accepts all the [global options](#global-options)


-## cargo dist init +## dist init Setup or update dist This will interactively guide you through the process of selecting configuration options and will also automatically run 'dist generate' afterwards as necessary. It will also handle updating your project to a new version of dist if you're running one. @@ -182,7 +182,7 @@ Print help (see a summary with '-h') This subcommand accepts all the [global options](#global-options)


-## cargo dist generate +## dist generate Generate one or more pieces of configuration ### Usage @@ -209,7 +209,7 @@ Print help (see a summary with '-h') This subcommand accepts all the [global options](#global-options)


-## cargo dist linkage +## dist linkage Report on the dynamic libraries used by the built artifacts ### Usage @@ -235,7 +235,7 @@ Print help (see a summary with '-h') This subcommand accepts all the [global options](#global-options)


-## cargo dist manifest +## dist manifest Generate the final build manifest without running any builds. This command is designed to match the exact behaviour of 'dist build' when passed the same flags, which is nice for consistency but annoying for anyone who doesn't understand dist's design really well. @@ -283,7 +283,7 @@ Print help (see a summary with '-h') This subcommand accepts all the [global options](#global-options)


-## cargo dist plan +## dist plan Get a plan of what to build (and check project status) If you want to know what running your dist CI will produce, this is the command for you! This is the exact command that CI will run to make its build plan and generate dist-manifest.json (although it adds --output-format=json so that it's machine-readable). @@ -306,7 +306,7 @@ Print help (see a summary with '-h') This subcommand accepts all the [global options](#global-options)


-## cargo dist host +## dist host Host artifacts ### Usage @@ -333,7 +333,7 @@ Print help (see a summary with '-h') This subcommand accepts all the [global options](#global-options)


-## cargo dist selfupdate +## dist selfupdate Performs a self-update, if a new version is available, and then 'init' ### Usage @@ -381,7 +381,7 @@ Print help (see a summary with '-h') This subcommand accepts all the [global options](#global-options)


-## cargo dist help +## dist help Print this message or the help of the given subcommand(s) ### Usage From 4d80f58b67d634dd22070fc03258b2028c56f7c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Wed, 23 Oct 2024 13:22:25 -0700 Subject: [PATCH 11/15] chore: update CLI help --- cargo-dist/src/cli.rs | 2 +- cargo-dist/tests/snapshots/long-help.snap | 2 +- cargo-dist/tests/snapshots/markdown-help.snap | 2 +- cargo-dist/tests/snapshots/short-help.snap | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cargo-dist/src/cli.rs b/cargo-dist/src/cli.rs index 1c600aa08..a102efc7b 100644 --- a/cargo-dist/src/cli.rs +++ b/cargo-dist/src/cli.rs @@ -13,7 +13,7 @@ use tracing::level_filters::LevelFilter; #[clap(version)] #[clap(bin_name = "dist")] #[clap(args_conflicts_with_subcommands = true)] -/// Shippable packaging for Rust. +/// Professional packaging and distribution for ambitious developers. /// /// See 'init', 'build' and 'plan' for the 3 most important subcommands. pub struct Cli { diff --git a/cargo-dist/tests/snapshots/long-help.snap b/cargo-dist/tests/snapshots/long-help.snap index 342230bed..42bf3b6d4 100644 --- a/cargo-dist/tests/snapshots/long-help.snap +++ b/cargo-dist/tests/snapshots/long-help.snap @@ -3,7 +3,7 @@ source: cargo-dist/tests/cli-tests.rs expression: format_outputs(&output) --- stdout: -Shippable packaging for Rust. +Professional packaging and distribution for ambitious developers. See 'init', 'build' and 'plan' for the 3 most important subcommands. diff --git a/cargo-dist/tests/snapshots/markdown-help.snap b/cargo-dist/tests/snapshots/markdown-help.snap index 9bd66597b..f766de05d 100644 --- a/cargo-dist/tests/snapshots/markdown-help.snap +++ b/cargo-dist/tests/snapshots/markdown-help.snap @@ -7,7 +7,7 @@ stdout: > This manual can be regenerated with `dist help-markdown` -Shippable packaging for Rust. +Professional packaging and distribution for ambitious developers. See 'init', 'build' and 'plan' for the 3 most important subcommands. diff --git a/cargo-dist/tests/snapshots/short-help.snap b/cargo-dist/tests/snapshots/short-help.snap index a066662db..ef5b78967 100644 --- a/cargo-dist/tests/snapshots/short-help.snap +++ b/cargo-dist/tests/snapshots/short-help.snap @@ -3,7 +3,7 @@ source: cargo-dist/tests/cli-tests.rs expression: format_outputs(&output) --- stdout: -Shippable packaging for Rust +Professional packaging and distribution for ambitious developers Usage: dist [OPTIONS] dist From 1c1b34e780d262b74b6b27e0dfed6899db3993d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Wed, 23 Oct 2024 13:52:42 -0700 Subject: [PATCH 12/15] release: 0.24.0-prerelease.2 --- Cargo.lock | 6 +++--- Cargo.toml | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 981814ad1..4d23ce5ce 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -187,7 +187,7 @@ dependencies = [ [[package]] name = "axoproject" -version = "0.24.0-prerelease.1" +version = "0.24.0-prerelease.2" dependencies = [ "axoasset", "axoprocess", @@ -377,7 +377,7 @@ dependencies = [ [[package]] name = "cargo-dist" -version = "0.24.0-prerelease.1" +version = "0.24.0-prerelease.2" dependencies = [ "axoasset", "axocli", @@ -426,7 +426,7 @@ dependencies = [ [[package]] name = "cargo-dist-schema" -version = "0.24.0-prerelease.1" +version = "0.24.0-prerelease.2" dependencies = [ "camino", "gazenot", diff --git a/Cargo.toml b/Cargo.toml index 6531da3ad..1b47c2562 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -12,12 +12,12 @@ edition = "2021" license = "MIT OR Apache-2.0" repository = "https://github.com/axodotdev/cargo-dist" homepage = "https://opensource.axo.dev/cargo-dist/" -version = "0.24.0-prerelease.1" +version = "0.24.0-prerelease.2" [workspace.dependencies] # intra-workspace deps (you need to bump these versions when you cut releases too! -cargo-dist-schema = { version = "=0.24.0-prerelease.1", path = "cargo-dist-schema" } -axoproject = { version = "=0.24.0-prerelease.1", path = "axoproject", default-features = false, features = ["cargo-projects", "generic-projects", "npm-projects"] } +cargo-dist-schema = { version = "=0.24.0-prerelease.2", path = "cargo-dist-schema" } +axoproject = { version = "=0.24.0-prerelease.2", path = "axoproject", default-features = false, features = ["cargo-projects", "generic-projects", "npm-projects"] } # first-party deps axocli = { version = "0.2.0" } From fb1ec6e140a46623a8d850fb71962276fcc5fb17 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Wed, 23 Oct 2024 14:07:59 -0700 Subject: [PATCH 13/15] chore: update own dist --- .github/workflows/release.yml | 4 ++-- dist-workspace.toml | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d84b22999..81e8dd579 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,4 +1,4 @@ -# This file was autogenerated by cargo-dist: https://opensource.axo.dev/cargo-dist/ +# This file was autogenerated by dist: https://opensource.axo.dev/cargo-dist/ # # Copyright 2022-2024, axodotdev # SPDX-License-Identifier: MIT or Apache-2.0 @@ -67,7 +67,7 @@ jobs: # we specify bash to get pipefail; it guards against the `curl` command # failing. otherwise `sh` won't catch that `curl` returned non-0 shell: bash - run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.24.0-prerelease.1/cargo-dist-installer.sh | sh" + run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.24.0-prerelease.2/cargo-dist-installer.sh | sh" - name: Cache dist uses: actions/upload-artifact@v4 with: diff --git a/dist-workspace.toml b/dist-workspace.toml index 151f4527e..00cb8cc05 100644 --- a/dist-workspace.toml +++ b/dist-workspace.toml @@ -1,10 +1,10 @@ [workspace] members = ["cargo:."] -# Config for 'cargo dist' +# Config for 'dist' [dist] -# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax) -cargo-dist-version = "0.24.0-prerelease.1" +# The preferred dist version to use in CI (Cargo.toml SemVer syntax) +cargo-dist-version = "0.24.0-prerelease.2" # CI backends to support ci = "github" # The installers to generate for each app From e7aedead1ee89e813f774a7340a80bc989f45cdb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Thu, 24 Oct 2024 13:07:57 -0700 Subject: [PATCH 14/15] chore: rename two constants --- cargo-dist/tests/gallery/dist.rs | 6 +++--- cargo-dist/tests/gallery/dist/tools.rs | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cargo-dist/tests/gallery/dist.rs b/cargo-dist/tests/gallery/dist.rs index 874d7687c..7970121c0 100644 --- a/cargo-dist/tests/gallery/dist.rs +++ b/cargo-dist/tests/gallery/dist.rs @@ -26,9 +26,9 @@ mod tools; /// Otherwise MEGA DANGER in messing up your computer. #[cfg(any(target_family = "unix", target_family = "windows"))] const ENV_RUIN_ME: &str = "RUIN_MY_COMPUTER_WITH_INSTALLERS"; -/// Set this at runtime to override STATIC_CARGO_DIST_BIN -const ENV_RUNTIME_CARGO_DIST_BIN: &str = "OVERRIDE_CARGO_BIN_EXE_dist"; -const STATIC_CARGO_DIST_BIN: &str = env!("CARGO_BIN_EXE_dist"); +/// Set this at runtime to override STATIC_DIST_BIN +const ENV_RUNTIME_DIST_BIN: &str = "OVERRIDE_CARGO_BIN_EXE_dist"; +const STATIC_DIST_BIN: &str = env!("CARGO_BIN_EXE_dist"); const ROOT_DIR: &str = env!("CARGO_MANIFEST_DIR"); static TOOLS: Mutex> = Mutex::new(None); diff --git a/cargo-dist/tests/gallery/dist/tools.rs b/cargo-dist/tests/gallery/dist/tools.rs index e8bec0423..980cc6633 100644 --- a/cargo-dist/tests/gallery/dist/tools.rs +++ b/cargo-dist/tests/gallery/dist/tools.rs @@ -22,8 +22,8 @@ impl Tools { // If OVERRIDE_* is set, prefer that over the version that cargo built for us, // this lets us test our shippable builds. - let cargo_dist_path = std::env::var(ENV_RUNTIME_CARGO_DIST_BIN) - .unwrap_or_else(|_| STATIC_CARGO_DIST_BIN.to_owned()); + let cargo_dist_path = + std::env::var(ENV_RUNTIME_DIST_BIN).unwrap_or_else(|_| STATIC_DIST_BIN.to_owned()); let cargo_dist = CommandInfo::new("cargo-dist", Some(&cargo_dist_path)).expect("dist isn't built!?"); cargo_dist.version().expect("couldn't parse dist version!?"); From a4eb7bcf56c00117ce12456312140f8c929842e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Misty=20De=20M=C3=A9o?= Date: Thu, 24 Oct 2024 13:08:43 -0700 Subject: [PATCH 15/15] README: note the original name --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 48c24e398..1bcd83c0d 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@
-# `dist` +# `dist` (formerly known as `cargo-dist`)