diff --git a/.commitlintrc.json b/.commitlintrc.json new file mode 100644 index 00000000..23e26485 --- /dev/null +++ b/.commitlintrc.json @@ -0,0 +1,6 @@ +{ + "extends": ["@commitlint/config-conventional"], + "rules": { + "body-max-line-length": [0] + } +} diff --git a/.github/workflows/lint-commits.yml b/.github/workflows/lint-commits.yml new file mode 100644 index 00000000..347a84df --- /dev/null +++ b/.github/workflows/lint-commits.yml @@ -0,0 +1,8 @@ +name: Lint Commit Messages + +on: + pull_request: + +jobs: + lint-commits: + uses: appfolio/rubygems-releaser/.github/workflows/lint-commits.yml@v1 diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 00000000..fb1301d3 --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,13 @@ +name: Publish Gem + +on: + release: + types: [published] + +permissions: + contents: write + id-token: write + +jobs: + publish: + uses: appfolio/rubygems-releaser/.github/workflows/publish.yml@v1 diff --git a/.github/workflows/push_gem.yml b/.github/workflows/push_gem.yml deleted file mode 100644 index e5854200..00000000 --- a/.github/workflows/push_gem.yml +++ /dev/null @@ -1,33 +0,0 @@ -name: Push Gem - -on: - workflow_dispatch: - -permissions: - contents: read - -jobs: - push: - if: github.repository == 'appfolio/ae_page_objects' - runs-on: ubuntu-latest - - permissions: - contents: write - id-token: write - - steps: - # Set up - - name: Harden Runner - uses: step-security/harden-runner@a4aa98b93cab29d9b1101a6143fb8bce00e2eac4 # v2.7.1 - with: - egress-policy: audit - - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 - - name: Set up Ruby - uses: ruby/setup-ruby@cacc9f1c0b3f4eb8a16a6bb0ed10897b43b9de49 # v1.176.0 - with: - bundler-cache: true - ruby-version: ruby - - # Release - - uses: rubygems/release-gem@612653d273a73bdae1df8453e090060bb4db5f31 # v1 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 00000000..00135972 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,15 @@ +name: Release Gem + +on: + push: + branches: + - main + - master + +permissions: + contents: write + pull-requests: write + +jobs: + release: + uses: appfolio/rubygems-releaser/.github/workflows/release.yml@v1 diff --git a/.release-please-manifest.json b/.release-please-manifest.json new file mode 100644 index 00000000..b85605b8 --- /dev/null +++ b/.release-please-manifest.json @@ -0,0 +1,3 @@ +{ + ".": "6.5.0" +} diff --git a/Rakefile b/Rakefile index 705c4bf5..55180ac3 100644 --- a/Rakefile +++ b/Rakefile @@ -6,9 +6,9 @@ require 'fileutils' require 'rake' require 'appraisal' -require 'rake/testtask' +require 'bundler/gem_tasks' -Bundler::GemHelper.install_tasks +require 'rake/testtask' def remove_files(glob_pattern) puts "Removing '#{glob_pattern}'" diff --git a/release-please-config.json b/release-please-config.json new file mode 100644 index 00000000..57035e3e --- /dev/null +++ b/release-please-config.json @@ -0,0 +1,61 @@ +{ + "bootstrap-sha": "c890ddd77f06d458a7cd9f4a09263e4ea9e4ea54", + "packages": { + ".": { + "changelog-path": "CHANGELOG.md", + "version-file": "lib/ae_page_objects/version.rb", + "release-type": "ruby", + "bump-minor-pre-major": false, + "bump-patch-for-minor-pre-major": false, + "draft": false, + "prerelease": false + } + }, + "changelog-sections": [ + { + "type": "feat", + "section": "Features" + }, + { + "type": "fix", + "section": "Bug Fixes" + }, + { + "type": "perf", + "section": "Performance Improvements" + }, + { + "type": "revert", + "section": "Reverts" + }, + { + "type": "docs", + "section": "Documentation" + }, + { + "type": "style", + "section": "Styles" + }, + { + "type": "chore", + "section": "Miscellaneous Chores" + }, + { + "type": "refactor", + "section": "Code Refactoring" + }, + { + "type": "test", + "section": "Tests" + }, + { + "type": "build", + "section": "Build System" + }, + { + "type": "ci", + "section": "Continuous Integration" + } + ], + "$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json" +}