DEV: Remove "Remove Chromium" steps (#148) #173
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
jobs: | |
validate_version: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
with: | |
repository: ${{ inputs.repository }} | |
fetch-depth: 1 | |
- name: Validate Version | |
shell: ruby {0} | |
run: | | |
version = File.read("VERSION").strip | |
if !version.match?(/\A\d+\z/) | |
puts "VERSION file must contain a single integer" | |
exit 1 | |
end | |
puts "VERSION = v#{version}" | |
tag_version: | |
runs-on: ubuntu-latest | |
if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
needs: validate_version | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
with: | |
repository: ${{ inputs.repository }} | |
fetch-depth: 1 | |
- name: Apply Tag | |
shell: ruby {0} | |
run: | | |
version = File.read("VERSION").strip | |
tag = "v#{version}" | |
system "git", "tag", tag, "-f", exception: true | |
system "git", "push", "origin", tag, "-f", exception: true |