Skip to content

patch(deps): bump github.com/jjliggett/jjversion from 0.5.82 to 0.5.8… #432

patch(deps): bump github.com/jjliggett/jjversion from 0.5.82 to 0.5.8…

patch(deps): bump github.com/jjliggett/jjversion from 0.5.82 to 0.5.8… #432

Workflow file for this run

name: actions
on:
push:
paths-ignore:
- README.md
- LICENSE.md
- ATTRIBUTIONS.md
- '.github/workflows/codeql-analysis.yaml'
- '.github/dependabot.yaml'
- '.gitignore'
branches:
- root
pull_request:
paths-ignore:
- README.md
- LICENSE.md
- ATTRIBUTIONS.md
- '.github/workflows/codeql-analysis.yaml'
- '.github/dependabot.yaml'
- '.gitignore'
workflow_dispatch:
permissions:
contents: write
jobs:
test:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
name: test
runs-on: ${{ matrix.os }}
defaults:
run:
shell: pwsh
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version: '1.22.6'
- run: Get-ChildItem -Force
- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
- name: Run action
uses: ./
id: jjversion
- name: Display jjversion outputs
run: |
echo "Major: ${{ steps.jjversion.outputs.major }}"
echo "Minor: ${{ steps.jjversion.outputs.minor }}"
echo "Patch: ${{ steps.jjversion.outputs.patch }}"
echo "MajorMinorPatch: ${{ steps.jjversion.outputs.majorMinorPatch }}"
echo "Sha: ${{ steps.jjversion.outputs.sha }}"
echo "ShortSha: ${{ steps.jjversion.outputs.shortSha }}"
build:
name: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version: '1.22.6'
- run: git log --oneline
- name: Run action
uses: ./
with:
skip-go-installation: true
id: jjversion
- run: echo "VERSION=$(echo ${{ steps.jjversion.outputs.majorMinorPatch }})" >> $GITHUB_ENV
- run: git reset --soft HEAD~1
- name: Run action for previous commit version
uses: ./
with:
skip-go-installation: true
id: previousversion
- run: echo "PREVIOUS_COMMIT_VERSION=$(echo ${{ steps.previousversion.outputs.majorMinorPatch }})" >> $GITHUB_ENV
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
repository: jjliggett/jjversion
ref: 8d5c529715bc9d90834e0bd1a7ec472181eaf05f
path: jjversion-core
clean: false
- run: ls -R
- run: go build -a -v -o jjversion-ghao-${{ env.VERSION }}-linux-x64/jjversion-ghao
- run: env GOOS=darwin GOARCH=amd64 go build -a -v -o jjversion-ghao-${{ env.VERSION }}-darwin-amd64/jjversion-ghao-darwin
- run: env GOOS=windows GOARCH=amd64 go build -a -v -o jjversion-ghao-${{ env.VERSION }}-windows-x64/jjversion-ghao.exe
- run: mkdir docs-and-licenses
- run: cp README.md docs-and-licenses
- run: cp LICENSE.md docs-and-licenses
- run: cp ATTRIBUTIONS.md docs-and-licenses
- run: cp jjversion-core/README.md docs-and-licenses/jjversion-core-README.md
- run: cp jjversion-core/LICENSE.md docs-and-licenses/jjversion-core-LICENSE.md
- run: cp jjversion-core/docs/ATTRIBUTIONS.md docs-and-licenses/jjversion-core-ATTRIBUTIONS.md
- run: mkdir docs-and-licenses/attributions
- run: cp -R jjversion-core/docs/attributions/. docs-and-licenses/attributions
- run: zip -r jjversion-ghao-docs-and-licenses-${{ env.VERSION }}.zip docs-and-licenses
- run: ls -R
- name: Upload jjversion-ghao
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: jjversion-ghao
path: jjversion-ghao-${{ env.VERSION }}-linux-x64/jjversion-ghao
- name: Upload jjversion-ghao-darwin
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: jjversion-ghao-darwin
path: jjversion-ghao-${{ env.VERSION }}-darwin-amd64/jjversion-ghao-darwin
- name: Upload jjversion-ghao-darwin
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: jjversion-ghao.exe
path: jjversion-ghao-${{ env.VERSION }}-windows-x64/jjversion-ghao.exe
- name: Upload docs
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: jjversion-ghao-docs-and-licenses-${{ env.VERSION }}.zip
path: jjversion-ghao-docs-and-licenses-${{ env.VERSION }}.zip
- name: Create GitHub release
uses: softprops/action-gh-release@01570a1f39cb168c169c802c3bceb9e93fb10974 # v2.1.0
if: ${{ github.ref == 'refs/heads/root' && env.VERSION != env.PREVIOUS_COMMIT_VERSION }}
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag_name: v${{ env.VERSION }}
draft: false
prerelease: false
generate_release_notes: true
make_latest: true
files: |
jjversion-ghao-${{ env.VERSION }}-linux-x64/jjversion-ghao
jjversion-ghao-${{ env.VERSION }}-darwin-amd64/jjversion-ghao-darwin
jjversion-ghao-${{ env.VERSION }}-windows-x64/jjversion-ghao.exe
README.md
LICENSE.md
jjversion-ghao-docs-and-licenses-${{ env.VERSION }}.zip