Initiate EML Assembly Line ecology metadata management tutorial #3210
Workflow file for this run
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
name: "[CI] GTN Tutorial Linting" | |
concurrency: | |
group: ci-tutsli-${{ github.head_ref }} | |
cancel-in-progress: true | |
on: | |
pull_request: | |
paths: | |
- 'Gemfile.lock' | |
- 'topics/**' | |
- '**/tutorial*.md' | |
- '**/slides.html' | |
- '**/slides/*.html' | |
- 'learning-pathways/*' | |
- 'faqs/**' | |
- 'news/**' | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 1 | |
- uses: reviewdog/action-setup@v1 | |
with: | |
reviewdog_version: latest | |
# BEGIN Dependencies | |
- uses: actions/setup-python@v2 | |
with: | |
python-version: '3.7' | |
architecture: 'x64' | |
- uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: "3.0" | |
- uses: actions/cache@v2 | |
with: | |
path: | | |
vendor/bundle | |
key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}- | |
restore-keys: | | |
${{ runner.os }}-gems- | |
- name: Install dependencies | |
run: | | |
gem install bundler rubocop | |
bundle config path vendor/bundle | |
bundle install --jobs 4 --retry 3 | |
pip install pyyaml | |
bundle pristine ffi | |
# END Dependencies | |
- name: Check Frontmatter | |
run: | | |
make check-diffs ACTIVATE_ENV=pwd | |
make check-frontmatter ACTIVATE_ENV=pwd | |
make check-contributors ACTIVATE_ENV=pwd | |
python bin/mergeyaml.py --nondocker > /dev/null | |
- name: Check Tutorial Formatting | |
run: | | |
find topics/ -name tutorial.md | xargs -n 1 python bin/check-broken-boxes.py | reviewdog -efm="%f:%l: %m" -filter-mode=file -reporter=github-pr-review | |
bundle exec ruby bin/lint.rb --format rdjson | reviewdog -filter-mode=file -reporter=github-pr-review -f=rdjsonl -fail-on-error | |
env: | |
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: rubocop | |
uses: reviewdog/action-rubocop@v2 | |
with: | |
rubocop_version: gemfile | |
reporter: github-pr-review | |
rubocop_flags: --except Layout/LineLength,Lint/RedundantCopDisableDirective | |
fail_on_error: true |