From 0f7a30f413f52a93347c32eb8cf7dd554f80e1e5 Mon Sep 17 00:00:00 2001 From: szorfein Date: Thu, 3 Oct 2024 13:04:23 +0000 Subject: [PATCH] new workflow --- .github/workflows/gem-push.yml | 48 ++++++++++++++++++++++++++++++++++ CHANGELOG.md | 5 +++- certs/szorfein.pem | 20 +++++++------- getch.gemspec | 10 ++++--- lib/getch/version.rb | 2 +- 5 files changed, 69 insertions(+), 16 deletions(-) create mode 100644 .github/workflows/gem-push.yml diff --git a/.github/workflows/gem-push.yml b/.github/workflows/gem-push.yml new file mode 100644 index 0000000..b4fbb63 --- /dev/null +++ b/.github/workflows/gem-push.yml @@ -0,0 +1,48 @@ +name: Ruby Gem + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + build: + name: Build + Publish + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + + steps: + - uses: actions/checkout@v4 + - name: Set up Ruby 2.6 + # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby, + # change this to (see https://github.com/ruby/setup-ruby#versioning): + # uses: ruby/setup-ruby@v1 + uses: ruby/setup-ruby@55283cc23133118229fd3f97f9336ee23a179fcf # v1.146.0 + with: + ruby-version: 2.6.10 + + - name: Publish to GPR + run: | + mkdir -p $HOME/.gem + touch $HOME/.gem/credentials + chmod 0600 $HOME/.gem/credentials + printf -- "---\n:github: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials + gem build *.gemspec + gem push --KEY github --host https://rubygems.pkg.github.com/${OWNER} *.gem + env: + GEM_HOST_API_KEY: "Bearer ${{secrets.GITHUB_TOKEN}}" + OWNER: ${{ github.repository_owner }} + +# - name: Publish to RubyGems +# 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 +# gem build *.gemspec +# gem push *.gem +# env: +# GEM_HOST_API_KEY: "${{secrets.RUBYGEMS_AUTH_TOKEN}}" diff --git a/CHANGELOG.md b/CHANGELOG.md index 30c5fef..33d9ea8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,9 @@ +## 0.7.3, release 2024-10 +Add a Workflow to build gem on Github + ### Fix - Voidlinux, remove 'base-container-full' instead of 'base-voidstrap'. -- Gentoo, use sys-kernel/installkernel, sys-kernel/installkernel-systemd was removed. +- Gentoo, use and configure 'sys-kernel/installkernel', sys-kernel/installkernel-systemd was removed from portage. ## 0.7.0, release 2023-12 * Add support for ssd disk `/dev/nvme*` #5 diff --git a/certs/szorfein.pem b/certs/szorfein.pem index 1c5bb69..22c8e8f 100644 --- a/certs/szorfein.pem +++ b/certs/szorfein.pem @@ -1,7 +1,7 @@ -----BEGIN CERTIFICATE----- MIIEhTCCAu2gAwIBAgIBATANBgkqhkiG9w0BAQsFADBEMREwDwYDVQQDDAhzem9y ZmVpbjEaMBgGCgmSJomT8ixkARkWCnByb3Rvbm1haWwxEzARBgoJkiaJk/IsZAEZ -FgNjb20wHhcNMjMxMDIzMTcyMTA4WhcNMjQxMDIyMTcyMTA4WjBEMREwDwYDVQQD +FgNjb20wHhcNMjQwOTEwMTI0NDE0WhcNMjUwOTEwMTI0NDE0WjBEMREwDwYDVQQD DAhzem9yZmVpbjEaMBgGCgmSJomT8ixkARkWCnByb3Rvbm1haWwxEzARBgoJkiaJ k/IsZAEZFgNjb20wggGiMA0GCSqGSIb3DQEBAQUAA4IBjwAwggGKAoIBgQCqe1yx EG2oM25jeHp08A8zkaDNmbI3MujjrRM/WPEYZX2dVwOxkIS20hQVuxcAsBBA4W/W @@ -15,13 +15,13 @@ siuX6RkNIelhtb0En7f3bizgPqlO0qPQV+wPi9TSBxdVG12C0OmjCQYMQD0CAwEA AaOBgTB/MAkGA1UdEwQCMAAwCwYDVR0PBAQDAgSwMB0GA1UdDgQWBBTlKnQ3qMUF zydvZaKwdP+dnj2uajAiBgNVHREEGzAZgRdzem9yZmVpbkBwcm90b25tYWlsL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CA3OkUCi/T2Ebbd8NDzIlnv2otiYaGR4YloFpVd +ZegX+82gyQCr -----END CERTIFICATE----- diff --git a/getch.gemspec b/getch.gemspec index 378efe1..d45a5dc 100644 --- a/getch.gemspec +++ b/getch.gemspec @@ -1,4 +1,6 @@ -require File.dirname(__FILE__) + '/lib/getch/version' +# frozen_string_literal: true + +require_relative 'lib/getch/version' Gem::Specification.new do |s| s.name = 'getch' @@ -15,7 +17,7 @@ Gem::Specification.new do |s| 'wiki_uri' => 'https://github.com/szorfein/getch' } s.license = 'MIT' - s.required_ruby_version = '>= 2.5.0' + s.required_ruby_version = '>= 2.6' s.files = Dir.glob('{assets,lib}/**/*', File::FNM_DOTMATCH).reject { |f| File.directory?(f) } @@ -26,6 +28,6 @@ Gem::Specification.new do |s| s.executables << 'getch' s.require_paths = ['lib'] - s.cert_chain = ['certs/szorfein.pem'] - s.signing_key = File.expand_path('~/.ssh/gem-private_key.pem') + #s.cert_chain = ['certs/szorfein.pem'] + #s.signing_key = File.expand_path('~/.ssh/gem-private_key.pem') end diff --git a/lib/getch/version.rb b/lib/getch/version.rb index 4837dd9..db80f9c 100644 --- a/lib/getch/version.rb +++ b/lib/getch/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module Getch - VERSION = '0.7.2' + VERSION = '0.7.3' end