From a7f62fe8f0c9201c56f46af4e585d324662e57db Mon Sep 17 00:00:00 2001 From: Daniel Silva Date: Wed, 6 Dec 2023 17:41:49 -0500 Subject: [PATCH] Update gem-push.yml Experiment with saving the RubyGems api key locally --- .github/workflows/gem-push.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/gem-push.yml b/.github/workflows/gem-push.yml index f238038..c25cad7 100644 --- a/.github/workflows/gem-push.yml +++ b/.github/workflows/gem-push.yml @@ -24,4 +24,11 @@ jobs: git config user.email "<>" - name: Create release - run: GEM_HOST_API_KEY ${{secrets.RUBYGEMS_API_KEY}} bundle exec rake release + run: | + mkdir -p $HOME/.gem + touch $HOME/.gem/credentials + chmod 0600 $HOME/.gem/credentials + printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials + bundle exec rake release + env: + GEM_HOST_API_KEY: ${{secrets.RUBYGEMS_API_KEY}}