Merge pull request #1475 from Floppy/dependabot/npm_and_yarn/babel/es… #4787
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: Ruby | |
on: | |
- push | |
- pull_request | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: awalsh128/cache-apt-pkgs-action@v1 | |
with: | |
packages: libglfw3 | |
- uses: actions/checkout@v4 | |
- uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 3.2.2 | |
bundler-cache: true | |
- name: Set up Node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18.16.0 | |
- name: Install yarn packages | |
run: yarn install | |
- name: Check typescript | |
run: yarn typecheck | |
- name: Compile assets | |
run: bundle exec rails assets:precompile | |
- name: Set up database | |
run: bundle exec rails db:setup | |
- name: Migrate database | |
run: bundle exec rails db:migrate:with_data | |
- name: Run tests | |
uses: paambaati/[email protected] | |
with: | |
coverageCommand: bundle exec rake | |
env: | |
CC_TEST_REPORTER_ID: a2ff22eaab926117741bb1aeefe8b95662c954aaa01fd37a393763b197436584 | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: awalsh128/cache-apt-pkgs-action@v1 | |
with: | |
packages: libglfw3 | |
- uses: actions/checkout@v4 | |
- uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 3.2.2 | |
bundler-cache: true | |
- name: Set up Node | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18.16.0 | |
- name: Install yarn packages | |
run: yarn install | |
- name: Lint Ruby code | |
run: bundle exec rake rubocop | |
- name: Lint Typescript code | |
run: yarn run lint:ts |