diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b5a9f0c..154e760 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,10 +5,10 @@ jobs: lint: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ruby/setup-ruby@v1 with: - ruby-version: 3.1 + ruby-version: 3.4.1 - name: Install dependencies run: bundle install - name: Run linter @@ -21,22 +21,19 @@ jobs: release_created: ${{ steps.release-please.outputs.release_created }} version: ${{ steps.release-please.outputs.version }} steps: - - uses: krystal/release-please-manifest-action@v1 + - uses: googleapis/release-please-action@v4 id: release-please - with: - app-id: ${{ vars.RELEASE_PLEASE_GITHUB_APP_ID }} - private-key: ${{ secrets.RELEASE_PLEASE_GITHUB_APP_PRIVATE_KEY }} release: runs-on: ubuntu-latest needs: [lint, release-please] - if: needs.release-please.outputs.release_created + if: ${{ needs.release-please.outputs.release_created }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Ruby - uses: actions/setup-ruby@v1 + uses: ruby/setup-ruby@v1 with: - ruby-version: 3.1 + ruby-version: 3.4.1 - name: Export version from tag name run: echo "${{ needs.release-please.outputs.version }}" > VERSION - name: Build Gem @@ -48,7 +45,7 @@ jobs: chmod 0600 $HOME/.gem/credentials printf -- "---\n:rubygems_api_key: ${RUBYGEMS_API_KEY}\n" > $HOME/.gem/credentials env: - RUBYGEMS_API_KEY: ${{secrets.KRYSTAL_RUBYGEMS_API_KEY}} + RUBYGEMS_API_KEY: ${{secrets.RUBYGEMS_API_KEY}} - name: Publish to RubyGems run: | gem push *.gem diff --git a/.github/.release-please-manifest.json b/.release-please-manifest.json similarity index 100% rename from .github/.release-please-manifest.json rename to .release-please-manifest.json diff --git a/README.md b/README.md index b77c6e5..d42b734 100644 --- a/README.md +++ b/README.md @@ -25,3 +25,13 @@ Start agent in background ``` $ deploy-agent start ``` + +## Release + +This project uses [Google's release-please](https://github.com/googleapis/release-please) action which automates CHANGELOG generation, the creation of GitHub releases, and version bumps. + +**Commit messages are important!** + +`release-please` assumes that you are following the [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) specification. +This means that your commit messages should be structured in a way that release-please can determine the type of change that has been made. +Please refer to the ["How should I write my commits"](https://github.com/googleapis/release-please?tab=readme-ov-file#how-should-i-write-my-commits) documentation. diff --git a/deploy-agent.gemspec b/deploy-agent.gemspec index e0d78b0..7d8be37 100644 --- a/deploy-agent.gemspec +++ b/deploy-agent.gemspec @@ -2,7 +2,7 @@ Gem::Specification.new do |s| s.name = 'deploy-agent' - s.version = '1.2.6' + s.version = '1.3.3' s.required_ruby_version = '>= 2.7' s.summary = 'The DeployHQ Agent' s.description = 'This gem allows you to configure a secure proxy through which DeployHQ can forward connections' @@ -15,7 +15,7 @@ Gem::Specification.new do |s| s.bindir = 'bin' s.executables << 'deploy-agent' - s.add_runtime_dependency 'nio4r', '2.1.0' - s.add_runtime_dependency 'rb-readline', '0.5.5' - s.add_runtime_dependency 'timers', '4.1.2' + s.add_dependency 'nio4r', '2.1.0' + s.add_dependency 'rb-readline', '0.5.5' + s.add_dependency 'timers', '4.1.2' end diff --git a/lib/deploy_agent/cli.rb b/lib/deploy_agent/cli.rb index 49e1f75..c55db06 100644 --- a/lib/deploy_agent/cli.rb +++ b/lib/deploy_agent/cli.rb @@ -123,7 +123,7 @@ def pid_from_file def write_pid File.open(PID_PATH, 'w') { |f| f.write Process.pid.to_s } - at_exit { File.delete(PID_PATH) if File.exists?(PID_PATH) } + at_exit { File.delete(PID_PATH) if File.exist?(PID_PATH) } end end diff --git a/.github/release-please-config.json b/release-please-config.json similarity index 100% rename from .github/release-please-config.json rename to release-please-config.json