Skip to content

Commit 6ed6e5b

Browse files
committed
fix: install missing system deps
fix: install missing system deps fix: install missing system deps ci: run on ubuntu 20.04 fix
1 parent 2db1a25 commit 6ed6e5b

File tree

93 files changed

+919
-8683
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

93 files changed

+919
-8683
lines changed

.browserslistrc

Lines changed: 0 additions & 1 deletion
This file was deleted.

.github/workflows/ci.yml

Lines changed: 9 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -21,24 +21,18 @@ jobs:
2121
POSTGRES_DB: demo_rails5_test
2222
- name: check style + security
2323
run: |
24+
fluentci run --wasm devbox setup
25+
devbox init
26+
devbox add ruby@$RUBY_VERSION
2427
fluentci run --wasm ruby bundle_exec rubocop
25-
fluentci run --wasm ruby bundle_exec brakeman
2628
env:
2729
GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
28-
RUBY_VERSION: 2.7.3
29-
- name: RSpec - model tests
30+
RUBY_VERSION: 3.1.4
31+
- name: Run tests
3032
run: |
31-
fluentci run --wasm ruby bundle_exec rspec spec/models
32-
env:
33-
GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
34-
- name: RSpec - controller tests
35-
run: |
36-
fluentci run --wasm ruby bundle_exec rspec spec/controllers
37-
env:
38-
GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
39-
- name: RSpec - feature specs
40-
run: |
41-
fluentci run --wasm ruby bundle_exec rake db:setup
42-
fluentci run --wasm ruby bundle_exec rspec spec/features
33+
fluentci run --wasm ruby bundle_exec rails db:migrate
34+
fluentci run --wasm ruby bundle_exec rails db:seed
35+
fluentci run --wasm ruby bundle_exec rails test
36+
fluentci run --wasm ruby bundle_exec rspec spec
4337
env:
4438
GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.rspec

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1 @@
1-
--require spec_helper --format documentation
2-
--format RspecJunitFormatter
3-
--out junit.xml
1+
--require spec_helper

.rubocop.yml

Lines changed: 1 addition & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1 @@
1-
require: rubocop-rspec
2-
3-
AllCops:
4-
Exclude:
5-
- "db/schema.rb"
6-
- "db/seeds.rb"
7-
- "db/migrate/**/*"
8-
- "lib/tasks/**/*"
9-
- "bin/*"
10-
- "config/**/*"
11-
- Rakefile
12-
- Gemfile
13-
- "spec/spec_helper.rb"
14-
- "spec/rails_helper.rb"
15-
- "vendor/**/*"
16-
- "node_modules/**/*"
17-
18-
Style/Documentation:
19-
Enabled: false
20-
21-
Style/FrozenStringLiteralComment:
22-
Enabled: false
23-
24-
Style/StringLiterals:
25-
Enabled: false
26-
27-
Layout/EmptyLineAfterMagicComment:
28-
Enabled: false
29-
30-
Layout/EmptyLinesAroundBlockBody:
31-
Enabled: false
32-
33-
Layout/EmptyLinesAroundClassBody:
34-
Enabled: false
35-
36-
Capybara/FeatureMethods:
37-
Enabled: false
1+
inherit_from: .rubocop_todo.yml

.rubocop_todo.yml

Lines changed: 130 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,130 @@
1+
# This configuration was generated by
2+
# `rubocop --auto-gen-config`
3+
# on 2023-07-30 04:33:32 UTC using RuboCop version 1.55.0.
4+
# The point is for the user to remove these configuration records
5+
# one by one as the offenses are removed from the code base.
6+
# Note that changes in the inspected code, or installation of new
7+
# versions of RuboCop, may require this file to be generated again.
8+
9+
# Offense count: 6
10+
# This cop supports safe autocorrection (--autocorrect).
11+
Layout/EmptyLineAfterGuardClause:
12+
Exclude:
13+
- 'bin/bundle'
14+
15+
# Offense count: 2
16+
# This cop supports safe autocorrection (--autocorrect).
17+
# Configuration parameters: EnforcedStyle, EnforcedStyleForEmptyBrackets.
18+
# SupportedStyles: space, no_space, compact
19+
# SupportedStylesForEmptyBrackets: space, no_space
20+
Layout/SpaceInsideArrayLiteralBrackets:
21+
Exclude:
22+
- 'config/environments/production.rb'
23+
24+
# Offense count: 4
25+
# This cop supports safe autocorrection (--autocorrect).
26+
Layout/SpaceInsidePercentLiteralDelimiters:
27+
Exclude:
28+
- 'Gemfile'
29+
30+
# Offense count: 1
31+
# Configuration parameters: AllowedMethods, AllowedPatterns.
32+
Metrics/CyclomaticComplexity:
33+
Max: 9
34+
35+
# Offense count: 1
36+
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
37+
Metrics/MethodLength:
38+
Max: 13
39+
40+
# Offense count: 1
41+
# Configuration parameters: AllowedMethods, AllowedPatterns.
42+
Metrics/PerceivedComplexity:
43+
Max: 9
44+
45+
# Offense count: 1
46+
# This cop supports safe autocorrection (--autocorrect).
47+
Style/BlockComments:
48+
Exclude:
49+
- 'spec/spec_helper.rb'
50+
51+
# Offense count: 2
52+
# This cop supports unsafe autocorrection (--autocorrect-all).
53+
# Configuration parameters: EnforcedStyle.
54+
# SupportedStyles: nested, compact
55+
Style/ClassAndModuleChildren:
56+
Exclude:
57+
- 'test/channels/application_cable/connection_test.rb'
58+
- 'test/test_helper.rb'
59+
60+
# Offense count: 4
61+
# Configuration parameters: AllowedConstants.
62+
Style/Documentation:
63+
Exclude:
64+
- 'spec/**/*'
65+
- 'test/**/*'
66+
- 'app/helpers/application_helper.rb'
67+
- 'app/mailers/application_mailer.rb'
68+
- 'app/models/application_record.rb'
69+
- 'config/application.rb'
70+
71+
# Offense count: 34
72+
# This cop supports unsafe autocorrection (--autocorrect-all).
73+
# Configuration parameters: EnforcedStyle.
74+
# SupportedStyles: always, always_true, never
75+
Style/FrozenStringLiteralComment:
76+
Enabled: false
77+
78+
# Offense count: 1
79+
# This cop supports unsafe autocorrection (--autocorrect-all).
80+
Style/GlobalStdStream:
81+
Exclude:
82+
- 'config/environments/production.rb'
83+
84+
# Offense count: 2
85+
# This cop supports safe autocorrection (--autocorrect).
86+
Style/IfUnlessModifier:
87+
Exclude:
88+
- 'bin/bundle'
89+
90+
# Offense count: 1
91+
# This cop supports safe autocorrection (--autocorrect).
92+
Style/PerlBackrefs:
93+
Exclude:
94+
- 'bin/bundle'
95+
96+
# Offense count: 2
97+
# This cop supports unsafe autocorrection (--autocorrect-all).
98+
# Configuration parameters: SafeForConstants.
99+
Style/RedundantFetchBlock:
100+
Exclude:
101+
- 'config/puma.rb'
102+
103+
# Offense count: 1
104+
# This cop supports unsafe autocorrection (--autocorrect-all).
105+
# Configuration parameters: RequireEnglish.
106+
# SupportedStyles: use_perl_names, use_english_names, use_builtin_english_names
107+
Style/SpecialGlobalVars:
108+
EnforcedStyle: use_perl_names
109+
110+
# Offense count: 99
111+
# This cop supports safe autocorrection (--autocorrect).
112+
# Configuration parameters: EnforcedStyle, ConsistentQuotesInMultiline.
113+
# SupportedStyles: single_quotes, double_quotes
114+
Style/StringLiterals:
115+
Enabled: false
116+
117+
# Offense count: 1
118+
# This cop supports safe autocorrection (--autocorrect).
119+
# Configuration parameters: .
120+
# SupportedStyles: percent, brackets
121+
Style/SymbolArray:
122+
EnforcedStyle: percent
123+
MinSize: 10
124+
125+
# Offense count: 2
126+
# This cop supports safe autocorrection (--autocorrect).
127+
# Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, AllowedPatterns.
128+
# URISchemes: http, https
129+
Layout/LineLength:
130+
Max: 198

.ruby-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.7.3
1+
ruby-3.3.4

Gemfile

Lines changed: 63 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -1,64 +1,75 @@
1-
def next?
2-
File.basename(__FILE__) == "Gemfile.next"
3-
end
4-
source 'https://rubygems.org'
1+
source "https://rubygems.org"
52
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
63

7-
gem 'webpacker'
8-
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
9-
gem 'rails', '~> 6.0.1'
10-
# Use postgresql as the database for Active Record
11-
gem 'pg', '>= 0.18', '< 2.0'
12-
# Use Puma as the app server
13-
gem 'puma', '~> 3.12'
14-
# Use SCSS for stylesheets
15-
gem 'sass-rails', '~> 5.0'
16-
# Use Uglifier as compressor for JavaScript assets
17-
gem 'uglifier', '>= 1.3.0'
18-
# See https://github.com/rails/execjs#readme for more supported runtimes
19-
# gem 'mini_racer', platforms: :ruby
20-
21-
# Use CoffeeScript for .coffee assets and views
22-
gem 'coffee-rails', '~> 4.2'
23-
# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
24-
gem 'turbolinks', '~> 5'
25-
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
26-
gem 'jbuilder', '~> 2.5'
4+
ruby "3.1.4"
5+
6+
# Bundle edge Rails instead: gem "rails", github: "rails/rails", branch: "main"
7+
gem "rails", "~> 7.0.6"
8+
9+
# The original asset pipeline for Rails [https://github.com/rails/sprockets-rails]
10+
gem "sprockets-rails"
11+
12+
# Use sqlite3 as the database for Active Record
13+
gem "sqlite3", "~> 1.4"
14+
15+
# Use the Puma web server [https://github.com/puma/puma]
16+
gem "puma", "~> 5.0"
17+
18+
# Use JavaScript with ESM import maps [https://github.com/rails/importmap-rails]
19+
gem "importmap-rails"
20+
21+
# Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev]
22+
gem "turbo-rails"
23+
24+
# Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev]
25+
gem "stimulus-rails"
26+
27+
# Build JSON APIs with ease [https://github.com/rails/jbuilder]
28+
gem "jbuilder"
29+
2730
# Use Redis adapter to run Action Cable in production
28-
# gem 'redis', '~> 4.0'
29-
# Use ActiveModel has_secure_password
30-
# gem 'bcrypt', '~> 3.1.7'
31+
gem "redis", "~> 4.0"
3132

32-
# Use ActiveStorage variant
33-
# gem 'mini_magick', '~> 4.8'
33+
# Use Kredis to get higher-level data types in Redis [https://github.com/rails/kredis]
34+
# gem "kredis"
3435

35-
# Use Capistrano for deployment
36-
# gem 'capistrano-rails', group: :development
36+
# Use Active Model has_secure_password [https://guides.rubyonrails.org/active_model_basics.html#securepassword]
37+
# gem "bcrypt", "~> 3.1.7"
38+
39+
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
40+
gem "tzinfo-data"
41+
42+
# Reduces boot times through caching; required in config/boot.rb
43+
gem "bootsnap", require: false
44+
45+
gem 'rubocop', require: false
46+
47+
# Use Sass to process CSS
48+
# gem "sassc-rails"
49+
50+
# Use Active Storage variants [https://guides.rubyonrails.org/active_storage_overview.html#transforming-images]
51+
# gem "image_processing", "~> 1.2"
3752

3853
group :development, :test do
39-
gem 'brakeman'
40-
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
41-
gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
42-
gem 'capybara'
43-
gem 'rspec-rails'
44-
gem 'rubocop', require: false
45-
gem 'rubocop-rails', require: false
46-
gem 'rubocop-rspec'
47-
gem 'next_rails'
48-
49-
# be able to demonstrate mysql config on Semaphore
50-
gem 'mysql2', '~> 0.5.2'
51-
gem "rspec_junit_formatter"
54+
# See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem
55+
gem "debug", platforms: %i[ mri mingw x64_mingw ]
56+
gem 'rspec-rails', ">= 3.9.0"
5257
end
5358

5459
group :development do
55-
# Access an interactive console on exception pages or by calling 'console' anywhere in the code.
56-
gem 'web-console', '>= 3.3.0'
57-
gem 'listen', '>= 3.0.5', '< 3.2'
58-
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
59-
gem 'spring'
60-
gem 'spring-watcher-listen', '~> 2.0.0'
60+
# Use console on exceptions pages [https://github.com/rails/web-console]
61+
gem "web-console"
62+
63+
# Add speed badges [https://github.com/MiniProfiler/rack-mini-profiler]
64+
# gem "rack-mini-profiler"
65+
66+
# Speed up commands on slow machines / big apps [https://github.com/rails/spring]
67+
# gem "spring"
6168
end
6269

63-
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
64-
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
70+
group :test do
71+
# Use system testing [https://guides.rubyonrails.org/testing.html#system-testing]
72+
gem "capybara"
73+
gem "selenium-webdriver"
74+
gem "webdrivers"
75+
end

0 commit comments

Comments
 (0)