Skip to content

Commit

Permalink
Fix GitHub CI pipeline (#35)
Browse files Browse the repository at this point in the history
* Split pipelines and specify node version

* Fix README.md

* Upgrade decidim and fix stylesheet packs

* Run Push CI only on main branch
  • Loading branch information
fblupi authored Oct 2, 2023
1 parent 8a77ecc commit 42479d2
Show file tree
Hide file tree
Showing 8 changed files with 422 additions and 117 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: "[CI] Lint"

on:
push:
branches:
- main
pull_request:

env:
RUBY_VERSION: 3.0.2
NODE_VERSION: 16.9.1

jobs:
lint-report:
runs-on: ubuntu-20.04
steps:
- uses: actions/[email protected]
with:
fetch-depth: 1

- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ env.RUBY_VERSION }}
bundler-cache: true

- run: npm ci
name: Install JS deps

- run: bundle exec rubocop -P
name: Lint Ruby files

- run: bundle exec erblint app/{cells,views}/**/*.erb
name: Lint ERB files

- run: npm run lint
name: Lint JS files
17 changes: 3 additions & 14 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Test
name: "[CI] Test"

on:
push:
Expand All @@ -8,9 +8,10 @@ on:

env:
RUBY_VERSION: 3.0.2
NODE_VERSION: 16.9.1

jobs:
test:
test-report:
runs-on: ubuntu-20.04
services:
postgres:
Expand Down Expand Up @@ -38,18 +39,6 @@ jobs:
ruby-version: ${{ env.RUBY_VERSION }}
bundler-cache: true

- run: npm ci
name: Install JS deps

- run: bundle exec rubocop -P
name: Lint Ruby files

- run: bundle exec erblint app/{cells,views}/**/*.erb
name: Lint ERB files

- run: npm run lint
name: Lint JS files

- name: Setup Database
run: bundle exec rake test_app

Expand Down
3 changes: 1 addition & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@
source "https://rubygems.org"

ruby RUBY_VERSION
# DECIDIM_VERSION = { git: "https://github.com/decidim/decidim" }
DECIDIM_VERSION = "0.27.2"
DECIDIM_VERSION = "0.27.4"

gem "decidim", DECIDIM_VERSION

Expand Down
Loading

0 comments on commit 42479d2

Please sign in to comment.