-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'puzzle:master' into olibrian-ptime-doc
- Loading branch information
Showing
19 changed files
with
462 additions
and
223 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,59 +1,46 @@ | ||
name: 'Code Style Review' | ||
name: "Code Style Review" | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- 'master' | ||
- "master" | ||
paths-ignore: | ||
- 'doc/**' | ||
- '**.md' | ||
- "doc/**" | ||
- "**.md" | ||
|
||
jobs: | ||
lint: | ||
runs-on: 'ubuntu-latest' | ||
runs-on: "ubuntu-latest" | ||
|
||
steps: | ||
- name: 'Checkout' | ||
uses: actions/checkout@v2 | ||
|
||
- name: 'Set up Ruby' | ||
uses: actions/setup-ruby@v1 | ||
with: | ||
ruby-version: '2.6' | ||
|
||
- name: 'Set up Reviewdog' | ||
env: | ||
REVIEWDOG_INSTALLER: 'https://raw.githubusercontent.com/reviewdog/reviewdog/master/install.sh' | ||
run: | | ||
mkdir -p $HOME/bin | ||
curl -sfL ${REVIEWDOG_INSTALLER} | sh -s -- -b $HOME/bin | ||
- name: 'Set up Rubocop' | ||
run: 'gem install rubocop rubocop-minitest rubocop-performance rubocop-rails' | ||
|
||
- name: 'Run Rubocop' | ||
env: | ||
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
rubocop | | ||
$HOME/bin/reviewdog \ | ||
-f=rubocop \ | ||
-name="Rubocop" \ | ||
-reporter=github-pr-review \ | ||
-level=error \ | ||
-diff="git diff $DIFF_BRANCH" | ||
- name: 'Set up Haml-lint' | ||
run: 'gem install haml-lint' | ||
|
||
- name: 'Run Haml-lint' | ||
env: | ||
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
haml-lint | | ||
$HOME/bin/reviewdog \ | ||
-efm="%f:%l %m" \ | ||
-name="Haml-lint" \ | ||
-reporter=github-pr-review \ | ||
-level=error \ | ||
-diff="git diff $DIFF_BRANCH" | ||
- name: "Checkout" | ||
uses: actions/checkout@v4 | ||
|
||
- name: "Set up Ruby" | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: 2.7 | ||
|
||
- name: "Rubocop" | ||
uses: reviewdog/action-rubocop@v2 | ||
with: | ||
rubocop_version: gemfile | ||
rubocop_extensions: rubocop-minitest:gemfile rubocop-performance:gemfile rubocop-rails:gemfile | ||
reporter: github-pr-review | ||
level: error | ||
|
||
- name: "Install HAML-Lint" | ||
run: "gem install haml-lint" | ||
- name: "Set up reviewdog" | ||
uses: reviewdog/action-setup@v1 | ||
- name: "Run reviewdog HAML-Lint" | ||
env: | ||
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
haml-lint | | ||
reviewdog \ | ||
-efm="%f:%l %m" \ | ||
-name="Haml-lint" \ | ||
-reporter=github-pr-review \ | ||
-level=error \ | ||
-diff="git diff $DIFF_BRANCH" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,64 +1,66 @@ | ||
name: 'Rails Unit Tests' | ||
name: "Rails Unit Tests" | ||
|
||
on: | ||
push: | ||
branches: | ||
- 'master' | ||
- "master" | ||
paths-ignore: | ||
- 'doc/**' | ||
- '**.md' | ||
- "doc/**" | ||
- "**.md" | ||
pull_request: | ||
branches: | ||
- 'master' | ||
- "master" | ||
paths-ignore: | ||
- 'doc/**' | ||
- '**.md' | ||
- "doc/**" | ||
- "**.md" | ||
|
||
jobs: | ||
build: | ||
runs-on: 'ubuntu-latest' | ||
runs-on: "ubuntu-latest" | ||
|
||
timeout-minutes: 15 | ||
|
||
strategy: | ||
matrix: | ||
ruby: [ '2.6', '2.7' ] | ||
ruby: ["2.6", "2.7"] | ||
|
||
services: | ||
postgres: | ||
image: 'postgres:11' | ||
image: "postgres:11" | ||
env: | ||
POSTGRES_PASSWORD: 'postgres' | ||
ports: [ '5432:5432' ] | ||
POSTGRES_PASSWORD: "postgres" | ||
ports: ["5432:5432"] | ||
options: >- | ||
--health-cmd pg_isready | ||
--health-interval 10s | ||
--health-timeout 10s | ||
--health-retries 10 | ||
memcached: | ||
image: 'memcached' | ||
ports: [ '11211:11211' ] | ||
image: "memcached" | ||
ports: ["11211:11211"] | ||
|
||
steps: | ||
- name: 'Checkout' | ||
uses: actions/checkout@v2 | ||
- name: "Checkout" | ||
uses: actions/checkout@v4 | ||
|
||
- name: 'Set up Ruby ${{ matrix.ruby }}' | ||
uses: ruby/[email protected] | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
env: | ||
ImageOS: ubuntu18 | ||
- name: "Set up Ruby ${{ matrix.ruby }}" | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ matrix.ruby }} | ||
bundler-cache: true | ||
|
||
- name: 'Build and test with Rake' | ||
env: | ||
RAILS_TEST_DB_NAME: 'postgres' | ||
RAILS_TEST_DB_USERNAME: 'postgres' | ||
RAILS_TEST_DB_PASSWORD: 'postgres' | ||
RAILS_ENV: 'test' | ||
run: | | ||
sudo apt-get -yqq install libpq-dev | ||
gem install bundler --version '~> 2' | ||
bundle install --jobs 4 --retry 3 | ||
bundle exec rails db:create | ||
bundle exec rails db:migrate | ||
bundle exec rails test | ||
- name: "Build and test with Rake" | ||
env: | ||
RAILS_TEST_DB_NAME: "postgres" | ||
RAILS_TEST_DB_USERNAME: "postgres" | ||
RAILS_TEST_DB_PASSWORD: "postgres" | ||
RAILS_ENV: "test" | ||
CI: "true" | ||
PGDATESTYLE: German | ||
run: | | ||
sudo apt-get -yqq install libpq-dev | ||
gem install bundler --version '~> 2' | ||
bundle install --jobs 4 --retry 3 | ||
bundle exec rails db:create | ||
bundle exec rails db:migrate | ||
bundle exec rails test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.