Skip to content

Update Step Version #28

Update Step Version

Update Step Version #28

Workflow file for this run

name: Update Step Version
on:
workflow_dispatch:
schedule:
- cron: "0 2 * * 5"
jobs:
update_dependencies:
runs-on: ubuntu-latest
steps:
- name: Check out codebase
uses: actions/checkout@v4
- name: Get latest step-cli release
id: step_release
run: |
release_tag=$(curl -X GET https://api.github.com/repos/smallstep/cli/releases/latest | jq -rS '.tag_name | capture("v(?<semver>[0-9][0-9]?.[0-9][0-9]?.[0-9][0-9]?)").semver')
echo "release_tag=$release_tag" >> $GITHUB_OUTPUT
current_tag=$(<step.version)
echo "current_tag=$current_tag" >> $GITHUB_OUTPUT
- name: Update 'step.version' file
if: steps.step_release.outputs.current_tag != steps.step_release.outputs.release_tag
env:
RELEASE_TAG: ${{ steps.step_release.outputs.release_tag }}
run: |
# update 'step.version' file
echo ${{ steps.step_release.outputs.release_tag }} > step.version
- name: Create pull request
if: steps.step_release.outputs.current_tag != steps.step_release.outputs.release_tag
uses: peter-evans/create-pull-request@v7
with:
token: ${{ secrets.WORKFLOW_TOKEN }}
commit-message: update step-ca and step-cli versions to ${{ steps.step_release.outputs.release_tag }}
title: update step-ca and step-cli versions to ${{ steps.step_release.outputs.release_tag }}
body: |
Updates [step-ca][1] to ${{ steps.step_release.outputs.release_tag }}
Updates [step-cli][1] to ${{ steps.step_release.outputs.release_tag }}
Auto-generated by [create-pull-request][3]
[1]: https://github.com/smallstep/certificates
[2]: https://github.com/smallstep/cli/
[3]: https://github.com/peter-evans/create-pull-request
labels: dependencies, status/auto-created
branch: update-step-version