Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor set-output to GITHUB_OUTPUT #170

Merged
merged 1 commit into from
Nov 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@ jobs:
ruby-version: 3.1
bundler-cache: true
- id: published_version
run: echo ::set-output name=published_version::$(gem list yalphabetize --remote | tail -n 1 | cut -d "(" -f2 | cut -d ")" -f1)
run: echo "PUBLISHED_VERSION=$(gem list yalphabetize --remote | tail -n 1 | cut -d "(" -f2 | cut -d ")" -f1)" >> $GITHUB_OUTPUT
- id: bundled_version
run: echo ::set-output name=bundled_version::$(bundle info yalphabetize | head -n 1 | cut -d "(" -f2 | cut -d ")" -f1)
run: echo "BUNDLED_VERSION=$(bundle info yalphabetize | head -n 1 | cut -d "(" -f2 | cut -d ")" -f1)" >> $GITHUB_OUTPUT
- name: Publish release
if: ${{ steps.published_version.outputs.published_version < steps.bundled_version.outputs.bundled_version }}
if: ${{ steps.published_version.outputs.PUBLISHED_VERSION < steps.bundled_version.outputs.BUNDLED_VERSION }}
uses: softprops/action-gh-release@v2
with:
tag_name: v${{ steps.bundled_version.outputs.bundled_version }}
tag_name: v${{ steps.bundled_version.outputs.BUNDLED_VERSION }}
- name: Publish to RubyGems
if: ${{ steps.published_version.outputs.published_version < steps.bundled_version.outputs.bundled_version }}
if: ${{ steps.published_version.outputs.PUBLISHED_VERSION < steps.bundled_version.outputs.BUNDLED_VERSION }}
run: |
mkdir -p $HOME/.gem
touch $HOME/.gem/credentials
Expand Down