-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
22 changed files
with
15,008 additions
and
18 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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
--exclude-exts=.min.css | ||
--ignore=adjoining-classes,box-model,ids,order-alphabetical,unqualified-attributes |
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,121 @@ | ||
--- | ||
glob: "app/{cells,views}/**/*.erb" | ||
exclude: | ||
- '**/vendor/**/*' | ||
- '**/node_modules/**/*' | ||
|
||
linters: | ||
ExtraNewline: | ||
enabled: true | ||
|
||
FinalNewline: | ||
enabled: true | ||
|
||
RequireInputAutocomplete: | ||
enabled: false | ||
|
||
SpaceAroundErbTag: | ||
enabled: true | ||
|
||
AllowedScriptType: | ||
enabled: true | ||
allowed_types: | ||
- text/javascript | ||
- text/template | ||
|
||
DeprecatedClasses: | ||
enabled: true | ||
addendum: "Please remove it from code." | ||
rule_set: | ||
- deprecated: ['process-content'] | ||
suggestion: "This class is deprecated. Please remove the surrounding element" | ||
- deprecated: ['xlarge-[\w]*'] | ||
suggestion: "Foundation classes are deprecated." | ||
|
||
Rubocop: | ||
enabled: true | ||
|
||
rubocop_config: | ||
inherit_from: | ||
- .rubocop.yml | ||
|
||
AllCops: | ||
DisabledByDefault: true | ||
|
||
Layout/InitialIndentation: | ||
Enabled: false | ||
|
||
Lint/SymbolConversion: | ||
Enabled: false | ||
|
||
Layout/SpaceInsideParens: | ||
Enabled: false | ||
|
||
Layout/SpaceAfterColon: | ||
Enabled: false | ||
|
||
Lint/UselessAssignment: | ||
Enabled: false | ||
|
||
Layout/ArgumentAlignment: | ||
Enabled: true | ||
|
||
Layout/SpaceAfterComma: | ||
Enabled: false | ||
|
||
Layout/TrailingWhitespace: | ||
Enabled: false | ||
|
||
Layout/LeadingEmptyLines: | ||
Enabled: false | ||
|
||
Layout/SpaceBeforeComma: | ||
Enabled: false | ||
|
||
Style/Copyright: | ||
Enabled: false | ||
|
||
Style/FrozenStringLiteralComment: | ||
Enabled: false | ||
|
||
Style/StringLiterals: | ||
EnforcedStyle: double_quotes | ||
|
||
Layout/LineLength: | ||
Enabled: false | ||
|
||
Layout/FirstArgumentIndentation: | ||
Enabled: false | ||
|
||
Layout/SpaceInsideHashLiteralBraces: | ||
Enabled: true | ||
|
||
Layout/BlockAlignment: | ||
Enabled: false | ||
|
||
Layout/MultilineMethodCallBraceLayout: | ||
Enabled: false | ||
|
||
Layout/FirstArrayElementIndentation: | ||
Enabled: false | ||
|
||
Layout/TrailingEmptyLines: | ||
Enabled: false | ||
|
||
Naming/FileName: | ||
Enabled: false | ||
|
||
Rails/LinkToBlank: | ||
Enabled: false | ||
|
||
Naming/VariableName: | ||
Enabled: false | ||
|
||
Layout/MultilineMethodCallIndentation: | ||
Enabled: true | ||
|
||
Layout/IndentationWidth: | ||
Enabled: false | ||
|
||
Layout/MultilineAssignmentLayout: | ||
Enabled: false |
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,13 @@ | ||
**/*{.,-}min.js | ||
spec/decidim_dummy_app/**/*.js | ||
development_app | ||
**/node_modules/** | ||
bundle.js | ||
karma.conf.js | ||
webpack.config.js | ||
webpack.config.babel.js | ||
entry.test.js | ||
entry.js | ||
*_manifest.js | ||
coverage | ||
vendor/bundle |
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,75 @@ | ||
name: "[CI] Lint" | ||
on: | ||
push: | ||
branches: | ||
- main | ||
- release/* | ||
- "*-stable" | ||
pull_request: | ||
branches-ignore: | ||
- "chore/l10n*" | ||
|
||
env: | ||
CI: "true" | ||
RUBY_VERSION: 3.1.1 | ||
NODE_VERSION: 18.17.1 | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
main: | ||
name: Lint | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 30 | ||
services: | ||
postgres: | ||
image: postgres:14 | ||
ports: ["5432:5432"] | ||
options: >- | ||
--health-cmd pg_isready | ||
--health-interval 10s | ||
--health-timeout 5s | ||
--health-retries 5 | ||
env: | ||
POSTGRES_PASSWORD: postgres | ||
env: | ||
DATABASE_USERNAME: postgres | ||
DATABASE_PASSWORD: postgres | ||
DATABASE_HOST: localhost | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 1 | ||
- uses: ruby/setup-ruby@v1 | ||
with: | ||
bundler-cache: true | ||
ruby-version: ${{ env.RUBY_VERSION }} | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ env.NODE_VERSION }} | ||
- name: Get npm cache directory path | ||
id: npm-cache-dir-path | ||
run: echo "dir=$(npm get cache)-ub" >> $GITHUB_OUTPUT | ||
- uses: actions/cache@v3 | ||
id: npm-cache | ||
with: | ||
path: ${{ steps.npm-cache-dir-path.outputs.dir }} | ||
key: npm-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
npm- | ||
- name: Install JS dependencies | ||
run: npm ci | ||
- run: bundle exec rubocop -P | ||
name: Lint Ruby files | ||
- run: npm run lint | ||
name: Lint JavaScript files | ||
- run: npm run stylelint | ||
name: Lint CSS files | ||
- run: npm run linthtml | ||
name: Lint HTML files | ||
- run: npm run markdownlint | ||
name: Lint Markdown files | ||
- run: npm run prettier | ||
name: Format files |
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
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 |
---|---|---|
|
@@ -6,6 +6,8 @@ | |
/pkg/ | ||
/spec/reports/ | ||
/tmp/ | ||
.DS_Store | ||
node_modules/ | ||
|
||
# rspec failure tracking | ||
.rspec-failures | ||
|
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,9 @@ | ||
default: true | ||
|
||
first-line-h1: false | ||
|
||
line-length: false | ||
|
||
no-bare-urls: false | ||
|
||
no-inline-html: false |
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,5 @@ | ||
node_modules/ | ||
decidim_dummy_app/ | ||
*/public/decidim-packs/ | ||
vendor/bundle | ||
development_app/ |
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,10 @@ | ||
spec/decidim_dummy_app/ | ||
node_modules/ | ||
development_app*/ | ||
|
||
# Decidim webpack packs | ||
public/decidim-packs | ||
# tmp folder (used by webpack to deal with cache) | ||
tmp | ||
# webpack packs output | ||
decidim-packs |
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,2 +1,26 @@ | ||
inherit_from: .rubocop_todo.yml | ||
|
||
inherit_gem: | ||
decidim-dev: rubocop-decidim.yml | ||
|
||
inherit_mode: | ||
merge: | ||
- Exclude | ||
|
||
AllCops: | ||
Include: | ||
- "**/*.rb" | ||
- "**/*.rake" | ||
- "**/*.ru" | ||
- "**/Gemfile" | ||
- "**/Rakefile" | ||
Exclude: | ||
- "spec/decidim_dummy_app/**/*" | ||
- "**/spec/decidim_dummy_app/**/*" | ||
- "bin/**/*" | ||
- "node_modules/**/*" | ||
- "**/node_modules/**/*" | ||
- "db/schema.rb" | ||
- "db/migrate/*" | ||
- "vendor/**/*" | ||
- "**/vendor/**/*" |
Empty file.
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,16 @@ | ||
# frozen_string_literal: true | ||
|
||
SimpleCov.start do | ||
root ENV.fetch("ENGINE_ROOT", nil) | ||
|
||
track_files "{app,lib}/**/*.rb" | ||
|
||
add_filter "lib/generators" | ||
add_filter "lib/decidim/superspace/version.rb" | ||
add_filter "lib/omniauth/superspace.rb" | ||
add_filter "/spec" | ||
end | ||
|
||
SimpleCov.command_name ENV.fetch("COMMAND_NAME", File.basename(Dir.pwd)) | ||
|
||
SimpleCov.merge_timeout 1800 |
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,2 @@ | ||
app/packs/stylesheets/vendor/* | ||
vendor/* |
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.