Skip to content

Commit

Permalink
Conform to linter and styleguide
Browse files Browse the repository at this point in the history
  • Loading branch information
kronn committed Mar 26, 2019
1 parent 9682e89 commit 80b5d18
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 7 deletions.
5 changes: 5 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ Style/TrailingCommaInArrayLiteral:
Style/TrailingCommaInHashLiteral:
EnforcedStyleForMultiline: consistent_comma

Layout/AlignHash:
EnforcedHashRocketStyle: table
EnforcedColonStyle: table
EnforcedLastArgumentHashStyle: always_inspect # default

Metrics/BlockLength:
Exclude:
- spec/**/*
2 changes: 2 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# frozen_string_literal: true

source 'https://rubygems.org'

# Specify your gem's dependencies in gpuzzletime.gemspec
Expand Down
8 changes: 5 additions & 3 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
require "bundler/gem_tasks"
require "rspec/core/rake_task"
# frozen_string_literal: true

require 'bundler/gem_tasks'
require 'rspec/core/rake_task'

RSpec::Core::RakeTask.new(:spec)

task :default => :spec
task default: :spec
7 changes: 4 additions & 3 deletions bin/console
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

require "bundler/setup"
require "gpuzzletime"
require 'bundler/setup'
require 'gpuzzletime'

# You can add fixtures and/or initialization code here to make experimenting
# with your gem easier. You can also use a different console, if you like.
Expand All @@ -10,5 +11,5 @@ require "gpuzzletime"
# require "pry"
# Pry.start

require "irb"
require 'irb'
IRB.start
1 change: 1 addition & 0 deletions lib/gpuzzletime/app.rb
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ def fill_entries(purpose)
# this is mixing preparation, assembly and output, but gets the job done
next unless date # guard against the machine
next unless @date == :all || @date == date # limit to one day if passed

entries[date] = []

start = nil # at the start of the day, we have no previous end
Expand Down
2 changes: 1 addition & 1 deletion spec/spec_helper.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# frozen_string_literal: true

$LOAD_PATH.unshift File.expand_path('../../lib', __FILE__)
$LOAD_PATH.unshift File.expand_path('../lib', __dir__)

require 'gpuzzletime'
require 'timecop'

0 comments on commit 80b5d18

Please sign in to comment.