Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
antonbaliasnikov committed Jan 21, 2025
1 parent 9234788 commit f4e436a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/actions/publish-crates/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ runs:
- name: Install Rust toolchain
uses: moonrepo/setup-rust@v1
with:
bins: 'cargo-workspaces,cargo-get'
bins: 'cargo-workspaces'

- name: Build the workspace before release
shell: 'bash -ex {0}'
Expand Down
25 changes: 9 additions & 16 deletions .github/workflows/release-please.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ jobs:
- name: Install Rust toolchain
uses: moonrepo/setup-rust@v1
with:
bins: 'cargo-workspaces,cargo-get'
bins: 'cargo-workspaces'

- name: Update Cargo.lock
shell: 'bash -ex {0}'
Expand All @@ -174,28 +174,22 @@ jobs:
if [[ ${BRANCH} == *components* ]]; then
COMPONENT="${BRANCH##*--}"
COMPONENT_PATH=$(jq -r --arg component ${COMPONENT} '.packages | to_entries[] | select(.value.component == $component) | .key' ${{ inputs.config }})
COMPONENT_VERSION=$(jq -r ".${COMPONENT_PATH}" ${{ inputs.manifest }})
(
cd "${COMPONENT_PATH}"
if [[ ${{ inputs.version-suffix }} != '' ]]; then
WORKSPACE_VERSION=$(cargo get workspace.package.version)
cargo workspaces version custom ${WORKSPACE_VERSION}-${{ inputs.version-suffix }} \
if [[ '${{ inputs.version-suffix }}' != '' ]]; then
cargo workspaces version custom ${COMPONENT_VERSION}-${{ inputs.version-suffix }} \
--all --no-git-commit --force "*" --yes
fi
cargo update --workspace
)
else if [[ '${{ inputs.workspace-dirs }}' != '' ]]; then
fi
if [[ '${{ inputs.workspace-dirs }}' != '' ]]; then
# In case of a one PR for multiple components
# update Cargo.lock for all components using the workspace-dirs input.
echo 123
for WORKSPACE in ${{ inputs.workspace-dirs }} ; do
(
cd "${WORKSPACE}"
if [[ ${{ inputs.version-suffix }} != '' ]]; then
WORKSPACE_VERSION=$(cargo get workspace.package.version)
cargo workspaces version custom ${WORKSPACE_VERSION}-${{ inputs.version-suffix }} \
--all --no-git-commit --force "*" --yes
fi
cargo update --workspace
)
( cd "${WORKSPACE}" && cargo update --workspace )
done
fi
# Commit changes to Cargo.lock if any
Expand Down Expand Up @@ -231,7 +225,7 @@ jobs:
max-parallel: 1 # Publish workspaces one by one to prevent possible rate limiting issues
steps:
- name: Publish crates
uses: matter-labs/zksync-ci-common/.github/actions/publish-crates@aba-custom-crates-suffix
uses: matter-labs/zksync-ci-common/.github/actions/publish-crates@v1
with:
workspace_path: ${{ matrix.path }}
org_owner: ${{ inputs.org-owner }}
Expand All @@ -240,7 +234,6 @@ jobs:
slack_webhook: ${{ secrets.slack_webhook }}
run_build: ${{ inputs.run_build }}
run_tests: ${{ inputs.run_tests }}
version-suffix: ${{ inputs.version-suffix }}


# This job upgrades the workspace dependencies across different workspaces of one repository.
Expand Down

0 comments on commit f4e436a

Please sign in to comment.