-
Notifications
You must be signed in to change notification settings - Fork 0
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 #1 from Flipez/rubocop
improvements
- Loading branch information
Showing
10 changed files
with
353 additions
and
103 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 |
---|---|---|
|
@@ -8,3 +8,4 @@ | |
/tmp/ | ||
key.json | ||
data/ | ||
logfile.log |
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 @@ | ||
inherit_from: .rubocop_todo.yml | ||
|
||
Style/StringLiterals: | ||
Enabled: true | ||
EnforcedStyle: double_quotes | ||
|
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,36 @@ | ||
# This configuration was generated by | ||
# `rubocop --auto-gen-config` | ||
# on 2024-05-25 12:30:22 UTC using RuboCop version 1.64.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: 4 | ||
# Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes. | ||
Metrics/AbcSize: | ||
Max: 58 | ||
|
||
# Offense count: 2 | ||
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns. | ||
# AllowedMethods: refine | ||
Metrics/BlockLength: | ||
Max: 28 | ||
|
||
# Offense count: 1 | ||
# Configuration parameters: CountComments, CountAsOne. | ||
Metrics/ClassLength: | ||
Max: 188 | ||
|
||
# Offense count: 6 | ||
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns. | ||
Metrics/MethodLength: | ||
Max: 61 | ||
|
||
# Offense count: 1 | ||
# Configuration parameters: AllowedConstants. | ||
Style/Documentation: | ||
Exclude: | ||
- 'spec/**/*' | ||
- 'test/**/*' | ||
- 'lib/mvg/data_handler.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
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,8 +1,8 @@ | ||
#!/usr/bin/env ruby | ||
# frozen_string_literal: true | ||
|
||
require 'thor' | ||
require_relative '../lib/mvg/analyser' | ||
require_relative '../lib/mvg/cli' | ||
require_relative '../lib/mvg/data_handler' | ||
MVG::Cli.start(ARGV) | ||
require "thor" | ||
require_relative "../lib/mvg/analyser" | ||
require_relative "../lib/mvg/cli" | ||
require_relative "../lib/mvg/data_handler" | ||
MVG::Cli.start(ARGV) |
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,25 +1,24 @@ | ||
# frozen_string_literal: true | ||
|
||
|
||
module MVG | ||
### | ||
# Provides command line interface | ||
class Cli < Thor | ||
desc 'version', 'display the stan version' | ||
desc "version", "display the stan version" | ||
def version | ||
puts("MVG Scraper version #{MVG::Analyser::VERSION}") | ||
end | ||
|
||
desc 'export FILE', 'exports the given compressed file into sqlite' | ||
desc "export FILE", "exports the given compressed file into sqlite" | ||
def export(file) | ||
analyser = MVG::DataHandler.new | ||
analyser.export_bq(file) | ||
end | ||
desc 'full', 'download and export full upstream data' | ||
|
||
desc "full", "download and export full upstream data" | ||
def full | ||
analyser = MVG::DataHandler.new | ||
analyser.full | ||
end | ||
end | ||
end | ||
end |
Oops, something went wrong.