From 578ded74299a65b217c17cfb2cd44db60f81a67e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Arist=C3=B3teles?= Date: Sun, 29 Sep 2024 18:50:57 -0300 Subject: [PATCH] chore: update publish.yaml --- .github/workflows/publish.yaml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index 204a870..03e9ca7 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -8,12 +8,6 @@ on: jobs: build: runs-on: ubuntu-latest - name: Ruby ${{ matrix.ruby }} - strategy: - matrix: - ruby: - - '3.2.2' - steps: - uses: actions/checkout@v4 - name: Set up Ruby @@ -21,21 +15,29 @@ jobs: with: ruby-version: 3.2 bundler-cache: true + - name: Install bundler run: gem install bundler + - name: Install dependencies run: bundle install + - name: Build gem run: gem build lennarb.gemspec + - name: Set up RubyGems credentials + env: + RUBYGEMS_API_KEY: ${{ secrets.RUBYGEMS_API_KEY }} run: | mkdir -p ~/.gem echo -e "---\n:rubygems_api_key: $RUBYGEMS_API_KEY" > ~/.gem/credentials chmod 0600 ~/.gem/credentials + - name: Push gem to RubyGems env: RUBYGEMS_HOST: "https://rubygems.org" RUBYGEMS_API_KEY: ${{ secrets.RUBYGEMS_API_KEY }} run: | - ls *.gem + cat ~/.gem/credentials | head -c 50 gem push $(ls *.gem) +