This repository has been archived by the owner on Oct 28, 2024. It is now read-only.
-
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.
* gitlab ci script * add rubocop * appease rubocop * cache deps
- Loading branch information
Showing
21 changed files
with
115 additions
and
47 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,21 @@ | ||
image: "ruby:2.5" | ||
|
||
# Cache gems in between builds | ||
cache: | ||
key: ${CI_COMMIT_REF_SLUG} | ||
paths: | ||
- vendor/ruby | ||
|
||
before_script: | ||
- ruby -v | ||
- which ruby | ||
- gem install bundler --no-document | ||
- bundle install --jobs $(nproc) --path vendor "${FLAGS[@]}" | ||
|
||
rspec: | ||
script: | ||
- bundle exec rspec | ||
|
||
rubocop: | ||
script: | ||
- bundle exec rubocop |
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,51 +1,82 @@ | ||
# This configuration was generated by | ||
# `rubocop --auto-gen-config` | ||
# on 2018-12-05 10:41:34 +0900 using RuboCop version 0.54.0. | ||
# on 2020-01-15 15:29:46 +0900 using RuboCop version 0.79.0. | ||
# The point is for the user to remove these configuration records | ||
# one by one as the offenses are removed from the code base. | ||
# Note that changes in the inspected code, or installation of new | ||
# versions of RuboCop, may require this file to be generated again. | ||
|
||
# Offense count: 1 | ||
# Cop supports --auto-correct. | ||
# Configuration parameters: EnforcedStyle. | ||
# SupportedStyles: auto_detection, squiggly, active_support, powerpack, unindent | ||
Layout/IndentHeredoc: | ||
Lint/AmbiguousOperator: | ||
Exclude: | ||
- 'exe/kaiser' | ||
- 'lib/kaiser/cli.rb' | ||
|
||
# Offense count: 4 | ||
# Offense count: 1 | ||
# Configuration parameters: AllowComments. | ||
Lint/SuppressedException: | ||
Exclude: | ||
- 'lib/kaiser/command_runner.rb' | ||
|
||
# Offense count: 11 | ||
Metrics/AbcSize: | ||
Max: 30 | ||
Max: 57 | ||
|
||
# Offense count: 1 | ||
# Offense count: 4 | ||
# Configuration parameters: CountComments, ExcludedMethods. | ||
# ExcludedMethods: refine | ||
Metrics/BlockLength: | ||
Max: 30 | ||
Max: 63 | ||
|
||
# Offense count: 1 | ||
# Configuration parameters: CountComments. | ||
Metrics/ClassLength: | ||
Max: 366 | ||
Max: 425 | ||
|
||
# Offense count: 4 | ||
# Configuration parameters: CountComments. | ||
# Offense count: 2 | ||
Metrics/CyclomaticComplexity: | ||
Max: 8 | ||
|
||
# Offense count: 11 | ||
# Configuration parameters: CountComments, ExcludedMethods. | ||
Metrics/MethodLength: | ||
Max: 30 | ||
Max: 44 | ||
|
||
# Offense count: 1 | ||
# Configuration parameters: CountKeywordArgs. | ||
Metrics/ParameterLists: | ||
Max: 7 | ||
|
||
# Offense count: 1 | ||
# Cop supports --auto-correct. | ||
Style/IfUnlessModifier: | ||
# Offense count: 2 | ||
Metrics/PerceivedComplexity: | ||
Max: 8 | ||
|
||
# Offense count: 14 | ||
# Configuration parameters: ForbiddenDelimiters. | ||
# ForbiddenDelimiters: (?-mix:(^|\s)(EO[A-Z]{1}|END)(\s|$)) | ||
Naming/HeredocDelimiterNaming: | ||
Exclude: | ||
- 'lib/kaiser/kaiser_cli.rb' | ||
- 'lib/kaiser/cmds/attach.rb' | ||
- 'lib/kaiser/cmds/db_load.rb' | ||
- 'lib/kaiser/cmds/db_reset.rb' | ||
- 'lib/kaiser/cmds/db_reset_hard.rb' | ||
- 'lib/kaiser/cmds/db_save.rb' | ||
- 'lib/kaiser/cmds/deinit.rb' | ||
- 'lib/kaiser/cmds/down.rb' | ||
- 'lib/kaiser/cmds/init.rb' | ||
- 'lib/kaiser/cmds/login.rb' | ||
- 'lib/kaiser/cmds/logs.rb' | ||
- 'lib/kaiser/cmds/set.rb' | ||
- 'lib/kaiser/cmds/show.rb' | ||
- 'lib/kaiser/cmds/shutdown.rb' | ||
- 'lib/kaiser/cmds/up.rb' | ||
|
||
# Offense count: 2 | ||
# Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns. | ||
# Offense count: 16 | ||
Style/Documentation: | ||
Enabled: false | ||
|
||
# Offense count: 27 | ||
# Cop supports --auto-correct. | ||
# Configuration parameters: AutoCorrect, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns. | ||
# URISchemes: http, https | ||
Metrics/LineLength: | ||
Max: 92 | ||
Layout/LineLength: | ||
Max: 143 |
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
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
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 |
---|---|---|
|
@@ -13,7 +13,7 @@ def usage | |
EOS | ||
end | ||
|
||
def execute(opts) | ||
def execute(_opts) | ||
ensure_setup | ||
attach_app | ||
start_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
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 |
---|---|---|
|
@@ -13,7 +13,7 @@ def usage | |
EOS | ||
end | ||
|
||
def execute(opts) | ||
def execute(_opts) | ||
ensure_setup | ||
load_db('.default') | ||
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
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 |
---|---|---|
|
@@ -11,7 +11,7 @@ def usage | |
EOS | ||
end | ||
|
||
def execute(opts) | ||
def execute(_opts) | ||
down | ||
end | ||
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
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
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
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,3 +1,5 @@ | ||
# frozen_string_literal: true | ||
|
||
module Kaiser | ||
# Base class for Kaiser-related errors. | ||
class Error < StandardError | ||
|