0
0
mirror of https://github.com/neon-mmd/websurfx.git synced 2024-11-21 21:48:21 -05:00

ci: adding in steps to regenerate the Cargo.lock file

This commit is contained in:
Scott 2024-01-30 13:03:07 -05:00
parent 4cb656e863
commit df6378ba58

View File

@ -19,7 +19,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout code - name: Checkout code
uses: actions/checkout@v3 uses: actions/checkout@v4
with: with:
ref: ${{ github.sha }} ref: ${{ github.sha }}
fetch-depth: 0 fetch-depth: 0
@ -37,12 +37,18 @@ jobs:
branch: update-from-${{ github.sha }} branch: update-from-${{ github.sha }}
- name: update cargo.toml - name: update cargo.toml
run: | run: |
appversion=$(echo "${{ steps.version-bump.outputs.new_tag }}" | sed 's/[v]//') appversion=$(echo "${{ steps.version-bump.outputs.new_tag }}" | grep -oE '[0-9]+\.[0-9]+\.[0-9]+')
sed -i -e "s/^version = .*/version = \"$appversion\"/" Cargo.toml sed -i -e "s/^version = .*/version = \"$appversion\"/" Cargo.toml
- uses: actions/checkout@v4
- run: rustup toolchain install stable --profile minimal
- uses: actions/checkout@v4
- run: rustup update stable && rustup default stable
- name: regenerate cargo.lock
run: cargo generate-lockfile
- name: auto commit - name: auto commit
uses: stefanzweifel/git-auto-commit-action@v5 uses: stefanzweifel/git-auto-commit-action@v5
with: with:
commit_message: "[skip ci] update Cargo.toml to ${{ steps.version-bump.outputs.new_tag }}" commit_message: "[skip ci] updating app version to ${{ steps.version-bump.outputs.new_tag }}"
branch: update-from-${{ github.sha }} branch: update-from-${{ github.sha }}
# create PR using GitHub CLI # create PR using GitHub CLI
- name: create PR with update info - name: create PR with update info