Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .github/workflows/danger-comment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: Danger Comment
on:
workflow_run:
workflows: [Danger]
types: [completed]
jobs:
comment:
uses: numbata/danger-pr-comment/.github/workflows/comment.yml@v0.1.0
secrets: inherit
24 changes: 9 additions & 15 deletions .github/workflows/danger.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,11 @@
name: PR Linter
on: [pull_request]
name: Danger
on:
pull_request:
types: [opened, reopened, edited, synchronize]
jobs:
danger:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: ruby/setup-ruby@v1
with:
ruby-version: 2.7
bundler-cache: true
- run: |
# Personal access token for dangerpr-bot - public, but base64 encoded to avoid tripping up GitHub
TOKEN=$(echo -n Z2hwX0xNQ3VmanBFeTBvYkZVTWh6NVNqVFFBOEUxU25abzBqRUVuaAo= | base64 --decode)
DANGER_GITHUB_API_TOKEN=$TOKEN bundle exec danger --verbose
uses: numbata/danger-pr-comment/.github/workflows/danger.yml@v0.1.0
with:
ruby-version: '3.0'
bundler-cache: true
secrets: inherit
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
### 2.0.1 (Next)

* [#49](https://github.com/mongoid/mongoid-scroll/pull/49): Migrate Danger to danger-pr-comment workflow - [@dblock](https://github.com/dblock).
* Your contribution here.

### 2.0.0 (2024/09/07)
Expand Down
6 changes: 5 additions & 1 deletion Dangerfile
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
danger.import_dangerfile(gem: 'mongoid-danger')
# frozen_string_literal: true

danger.import_plugin('danger-pr-comment')

changelog.check!
4 changes: 3 additions & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,11 @@ end
group :development, :test do
gem 'bundler'
gem 'coveralls_reborn', require: false
gem 'danger', require: false
gem 'danger-changelog', require: false
gem 'danger-pr-comment', require: false
gem 'database_cleaner', '~> 1.8.5'
gem 'faker'
gem 'mongoid-danger', '~> 0.2.0', require: false
gem 'rake'
gem 'rspec', '~> 3.0'
gem 'rspec-its'
Expand Down