-
Notifications
You must be signed in to change notification settings - Fork 116
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add docs workflow. Make bin/update-docs parallel
- Loading branch information
1 parent
bf625ca
commit dbd170d
Showing
2 changed files
with
51 additions
and
1 deletion.
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 |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: Update Docs | ||
|
||
env: | ||
RAILS_ENV: test | ||
|
||
jobs: | ||
openapi: | ||
name: RSpec OpenAPI | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 20 | ||
|
||
services: | ||
db: | ||
image: postgres:15 | ||
env: | ||
POSTGRES_USER: postgres | ||
POSTGRES_HOST_AUTH_METHOD: trust | ||
ports: | ||
- 5432:5432 | ||
options: >- | ||
--health-cmd pg_isready | ||
--health-interval 10s | ||
--health-timeout 5s | ||
--health-retries 5 | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
- name: Setup Ruby | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
bundler-cache: true | ||
- name: Setup Database | ||
run: | | ||
bundle exec rake parallel:load_schema | ||
- name: Get CPU info | ||
id: cpu_info | ||
run: | | ||
echo "cpu_cores=$(nproc)" >> $GITHUB_ENV | ||
- name: Run tests and update docs | ||
env: | ||
PARALLEL_TESTS_CONCURRENCY: ${{ env.cpu_cores }} | ||
run: ./bin/update-docs | ||
- name: Check for untracked changes doc | ||
uses: rootstrap/check_untracked_changes@v1 | ||
with: | ||
path: "./doc" |
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