mirror of
https://github.com/zed-industries/zed.git
synced 2026-06-01 03:14:56 +07:00
extension_ci: Use more robust bash syntax for bump_extension_version (#43955)
Also does some more cleanup here and there. Release Notes: - N/A
This commit is contained in:
parent
34a2bfd6b7
commit
9c4e16088c
2 changed files with 6 additions and 12 deletions
9
.github/workflows/extension_bump.yml
vendored
9
.github/workflows/extension_bump.yml
vendored
|
|
@ -114,15 +114,12 @@ jobs:
|
|||
run: |
|
||||
OLD_VERSION="${{ needs.check_bump_needed.outputs.current_version }}"
|
||||
|
||||
if [[ -f "extension.toml" ]]; then
|
||||
EXTENSION_TOML="extension.toml"
|
||||
fi
|
||||
|
||||
BUMP_FILES=("extension.toml")
|
||||
if [[ -f "Cargo.toml" ]]; then
|
||||
CARGO_TOML="Cargo.toml"
|
||||
BUMP_FILES+=("Cargo.toml")
|
||||
fi
|
||||
|
||||
bump2version --verbose --current-version "$OLD_VERSION" --no-configured-files ${{ inputs.bump-type }} "$EXTENSION_TOML" "$CARGO_TOML"
|
||||
bump2version --verbose --current-version "$OLD_VERSION" --no-configured-files ${{ inputs.bump-type }} "${BUMP_FILES[@]}"
|
||||
|
||||
if [[ -f "Cargo.toml" ]]; then
|
||||
cargo update --workspace
|
||||
|
|
|
|||
|
|
@ -242,15 +242,12 @@ fn bump_version(current_version: &JobOutput, bump_type: &WorkflowInput) -> (Step
|
|||
indoc! {r#"
|
||||
OLD_VERSION="{}"
|
||||
|
||||
if [[ -f "extension.toml" ]]; then
|
||||
EXTENSION_TOML="extension.toml"
|
||||
fi
|
||||
|
||||
BUMP_FILES=("extension.toml")
|
||||
if [[ -f "Cargo.toml" ]]; then
|
||||
CARGO_TOML="Cargo.toml"
|
||||
BUMP_FILES+=("Cargo.toml")
|
||||
fi
|
||||
|
||||
bump2version --verbose --current-version "$OLD_VERSION" --no-configured-files {} "$EXTENSION_TOML" "$CARGO_TOML"
|
||||
bump2version --verbose --current-version "$OLD_VERSION" --no-configured-files {} "${{BUMP_FILES[@]}}"
|
||||
|
||||
if [[ -f "Cargo.toml" ]]; then
|
||||
cargo update --workspace
|
||||
|
|
|
|||
Loading…
Reference in a new issue