-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #327 from nimblehq/release/5.0.0
Release/5.0.0
- Loading branch information
Showing
169 changed files
with
1,367 additions
and
1,146 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 @@ | ||
--- | ||
BUNDLE_GEMFILE: ".template/Gemfile" |
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,9 +6,9 @@ env: | |
APP_NAME: rails_templates | ||
DOCKER_IMAGE: ${{ github.repository }} | ||
DOCKER_REGISTRY_HOST: ${{ secrets.DOCKER_REGISTRY_HOST }} | ||
RUBY_VERSION: 2.7.2 | ||
NODE_VERSION: 14 | ||
RAILS_VERSION: 6.1.1 | ||
RUBY_VERSION: 3.0.1 | ||
NODE_VERSION: 16 | ||
RAILS_VERSION: 7.0.1 | ||
|
||
jobs: | ||
build_production: | ||
|
@@ -29,7 +29,7 @@ jobs: | |
uses: nimblehq/[email protected] | ||
|
||
- name: Setup Ruby | ||
uses: ruby/setup-ruby@v1.61.1 | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ env.RUBY_VERSION }} | ||
bundler-cache: true | ||
|
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,42 @@ | ||
name: Test Template | ||
|
||
on: push | ||
|
||
env: | ||
RUBY_VERSION: 3.0.1 | ||
|
||
jobs: | ||
test: | ||
name: Test template | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Cancel previous runs | ||
uses: styfle/[email protected] | ||
with: | ||
access_token: ${{ github.token }} | ||
|
||
- name: Checkout Repository | ||
uses: actions/[email protected] | ||
|
||
- name: Setup Ruby | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ env.RUBY_VERSION }} | ||
bundler-cache: true | ||
|
||
- name: Cache gems | ||
uses: actions/cache@v2 | ||
with: | ||
path: vendor/bundle | ||
key: ${{ runner.os }}-template-${{ env.RUBY_VERSION }}-${{ hashFiles('**/Gemfile.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-template-${{ env.RUBY_VERSION }}- | ||
- name: Install gems | ||
run: | | ||
bundle config path vendor/bundle | ||
bundle install --jobs 4 --retry 3 | ||
- name: Run RuboCop | ||
run: bundle exec rubocop --config .template/.rubocop.yml --parallel |
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 |
---|---|---|
|
@@ -9,9 +9,9 @@ env: | |
DOCKER_REGISTRY_HOST: ${{ secrets.DOCKER_REGISTRY_HOST }} | ||
DOCKER_REGISTRY_USERNAME: ${{ github.repository_owner }} | ||
DOCKER_REGISTRY_TOKEN: ${{ secrets.DOCKER_REGISTRY_TOKEN }} | ||
RUBY_VERSION: 2.7.2 | ||
NODE_VERSION: 14 | ||
RAILS_VERSION: 6.1.1 | ||
RUBY_VERSION: 3.0.1 | ||
NODE_VERSION: 16 | ||
RAILS_VERSION: 7.0.1 | ||
|
||
jobs: | ||
test: | ||
|
@@ -32,7 +32,7 @@ jobs: | |
uses: nimblehq/[email protected] | ||
|
||
- name: Setup Ruby | ||
uses: ruby/setup-ruby@v1.61.1 | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: ${{ env.RUBY_VERSION }} | ||
bundler-cache: true | ||
|
@@ -87,7 +87,7 @@ jobs: | |
run: | | ||
export BRANCH_TAG=${{ env.BRANCH_TAG }}-${{ matrix.variant }} | ||
cd $APP_NAME | ||
docker-compose pull test || true | ||
docker compose pull test || true | ||
- name: Build docker image | ||
run: | | ||
|
@@ -98,7 +98,7 @@ jobs: | |
run: | | ||
export BRANCH_TAG=${{ env.BRANCH_TAG }}-${{ matrix.variant }} | ||
cd $APP_NAME | ||
docker-compose push test | ||
docker compose push test | ||
- name: Test template | ||
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,13 @@ | ||
append_to_file '.gitignore' do | ||
<<~EOT | ||
# frozen_string_literal: true | ||
|
||
# Ignore i18n.js generated files | ||
# If deploy to heroku with git, please remove this as it prevents the files to be committed | ||
/app/javascript/translations/translations.js | ||
append_to_file '.gitignore' do | ||
<<~IGNORE | ||
# Ignore folder information and IDE-specific files | ||
.DS_Store | ||
.idea/* | ||
# Ignore folder information and IDE-specific files | ||
.DS_Store | ||
.idea/* | ||
# Ignore the test coverage results from SimpleCov | ||
/coverage | ||
EOT | ||
# Ignore the test coverage results from SimpleCov | ||
/coverage | ||
IGNORE | ||
end |
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 |
---|---|---|
@@ -0,0 +1,46 @@ | ||
AllCops: | ||
NewCops: enable | ||
TargetRubyVersion: 3 | ||
Exclude: | ||
- 'vendor/**/*' | ||
|
||
Lint/NonDeterministicRequireOrder: | ||
Exclude: | ||
- '../spec/rails_helper.rb' | ||
|
||
Metrics/MethodLength: | ||
Exclude: | ||
- '../template.rb' | ||
- '**/template.rb' | ||
- 'hooks/**/*' | ||
|
||
Metrics/AbcSize: | ||
Enabled: false | ||
|
||
Metrics/BlockLength: | ||
Enabled: false | ||
|
||
Metrics/CyclomaticComplexity: | ||
Exclude: | ||
- '../template.rb' | ||
- '**/template.rb' | ||
|
||
Metrics/PerceivedComplexity: | ||
Exclude: | ||
- '../template.rb' | ||
- '**/template.rb' | ||
|
||
Naming/FileName: | ||
Exclude: | ||
- '**/.tool-versions.rb' | ||
- '**/Dangerfile.rb' | ||
- '**/Gemfile.rb' | ||
- '**/Procfile.dev.rb' | ||
|
||
Style/Documentation: | ||
Enabled: false | ||
|
||
Style/TrivialAccessors: | ||
Exclude: | ||
- '../template.rb' | ||
- '**/template.rb' |
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,6 +1,9 @@ | ||
# frozen_string_literal: true | ||
|
||
source 'https://rubygems.org' | ||
|
||
gem 'docker-api' # A lightweight Ruby client for the Docker Remote API | ||
gem 'rspec' # BDD for Ruby | ||
gem 'rspec-wait' # Wait for conditions in RSpec | ||
gem 'rubocop', require: false # A Ruby static code analyzer and formatter, based on the community Ruby style guide. | ||
gem 'serverspec' # RSpec tests for your servers | ||
gem 'docker-api' # A lightweight Ruby client for the Docker Remote API |
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 |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# frozen_string_literal: true | ||
|
||
insert_into_file 'app/javascript/packs/application.js', before: %r{import 'translations/translations'.+\n} do | ||
insert_into_file 'app/javascript/application.js', before: %r{import './translations/translations'.+\n} do | ||
<<~JAVASCRIPT | ||
import 'vendor/bootstrap'; | ||
import './vendor/'; | ||
JAVASCRIPT | ||
end |
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,7 +1,7 @@ | ||
# frozen_string_literal: true | ||
|
||
insert_into_file 'app/assets/stylesheets/application.scss', after: /\/\/ Dependencies\n/ do | ||
insert_into_file 'app/assets/stylesheets/application.scss', after: %r{// Dependencies\n} do | ||
<<~SCSS | ||
@import 'vendor/bootstrap/bootstrap'; | ||
@import './vendor'; | ||
SCSS | ||
end |
This file was deleted.
Oops, something went wrong.
27 changes: 27 additions & 0 deletions
27
.template/addons/bootstrap/javascript/vendor/bootstrap/index.js
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,27 @@ | ||
import Alert from 'bootstrap/js/dist/alert'; | ||
import Button from 'bootstrap/js/dist/button'; | ||
import Carousel from 'bootstrap/js/dist/carousel'; | ||
import Collapse from 'bootstrap/js/dist/collapse'; | ||
import Dropdown from 'bootstrap/js/dist/dropdown'; | ||
import Modal from 'bootstrap/js/dist/modal'; | ||
import Offcanvas from 'bootstrap/js/dist/offcanvas'; | ||
import Popover from 'bootstrap/js/dist/popover'; | ||
import ScrollSpy from 'bootstrap/js/dist/scrollspy'; | ||
import Tab from 'bootstrap/js/dist/tab'; | ||
import Toast from 'bootstrap/js/dist/toast'; | ||
import Tooltip from 'bootstrap/js/dist/tooltip'; | ||
|
||
export default { | ||
Alert, | ||
Button, | ||
Carousel, | ||
Collapse, | ||
Dropdown, | ||
Modal, | ||
Offcanvas, | ||
Popover, | ||
ScrollSpy, | ||
Tab, | ||
Toast, | ||
Tooltip | ||
}; |
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 @@ | ||
import './bootstrap'; |
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,8 +1,4 @@ | ||
# frozen_string_literal: true | ||
|
||
insert_into_file 'package.json', after: /"i18n-js":.+\n/ do | ||
<<~JSON | ||
"bootstrap": "4.5.2", | ||
"bootstrap.native": "3.0.13", | ||
JSON | ||
end | ||
run 'yarn add [email protected]' | ||
run 'yarn add @popperjs/[email protected]' |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
@import './bootstrap'; |
Oops, something went wrong.