my_gems 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 971b2693915082d151a4e39236d68c6d50c9a471740ab7b40d9e9bee17c765c3
4
- data.tar.gz: 10e9db1562597d782227b51cdfcd217da6c0dee22edce250034c53d5fa16e98f
3
+ metadata.gz: 9a063369104e6de0486aee936d2d0ae4a9752e71036447b4fb8eef538ae83071
4
+ data.tar.gz: 20164765c03901929faec75a3c2eda852f869a750cbb4a4b10a9d403a76a2e1c
5
5
  SHA512:
6
- metadata.gz: 8698a332efe5c3da416e7adc6ef9b983b1ec7e3f1169081c7435b4263a40d1ec95541de3e291426415c38f706e18d7c797410205c88490e64f348429d0958e0e
7
- data.tar.gz: f7709ebcacb86337e69cc991ddb60f5dc2ee4c787b5b410411d4bad56f2fc4f54648a332b821ce648b00ad76cbcdbe2db4e435c8ad47fcf6957d220e566d60cc
6
+ metadata.gz: ad53cc08e013e328dd5de16fc0f8b43ec33abe0cacaa9a079f6cbd4956ad02008ad7ac0054cc5a200ad921ace3e64c44f86a64ec0c8103005fe469118ed4487e
7
+ data.tar.gz: 77b8d2cd14d05518bc2db4e88150e17bec81db1f4f42da43332c9fc07f55f0ed86dc50cdb9110aec55381e18b6abefa57b5aa307b016489aa83084b08d8d362d
data/Gemfile CHANGED
@@ -4,3 +4,6 @@ git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }
4
4
 
5
5
  # Specify your gem's dependencies in my_gems.gemspec
6
6
  gemspec
7
+
8
+ gem 'guard-rspec', require: false, group: %i[development test]
9
+ gem 'rubocop', require: false, group: %i[development test]
data/Gemfile.lock ADDED
@@ -0,0 +1,89 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ my_gems (0.1.0)
5
+
6
+ GEM
7
+ remote: https://rubygems.org/
8
+ specs:
9
+ ast (2.3.0)
10
+ coderay (1.1.2)
11
+ diff-lcs (1.3)
12
+ ffi (1.9.25)
13
+ formatador (0.2.5)
14
+ guard (2.14.2)
15
+ formatador (>= 0.2.4)
16
+ listen (>= 2.7, < 4.0)
17
+ lumberjack (>= 1.0.12, < 2.0)
18
+ nenv (~> 0.1)
19
+ notiffany (~> 0.0)
20
+ pry (>= 0.9.12)
21
+ shellany (~> 0.0)
22
+ thor (>= 0.18.1)
23
+ guard-compat (1.2.1)
24
+ guard-rspec (4.7.3)
25
+ guard (~> 2.1)
26
+ guard-compat (~> 1.1)
27
+ rspec (>= 2.99.0, < 4.0)
28
+ listen (3.1.5)
29
+ rb-fsevent (~> 0.9, >= 0.9.4)
30
+ rb-inotify (~> 0.9, >= 0.9.7)
31
+ ruby_dep (~> 1.2)
32
+ lumberjack (1.0.13)
33
+ method_source (0.9.0)
34
+ nenv (0.3.0)
35
+ notiffany (0.1.1)
36
+ nenv (~> 0.1)
37
+ shellany (~> 0.0)
38
+ parallel (1.12.0)
39
+ parser (2.4.0.0)
40
+ ast (~> 2.2)
41
+ powerpack (0.1.1)
42
+ pry (0.11.3)
43
+ coderay (~> 1.1.0)
44
+ method_source (~> 0.9.0)
45
+ rainbow (2.2.2)
46
+ rake
47
+ rake (10.5.0)
48
+ rb-fsevent (0.10.3)
49
+ rb-inotify (0.9.10)
50
+ ffi (>= 0.5.0, < 2)
51
+ rspec (3.8.0)
52
+ rspec-core (~> 3.8.0)
53
+ rspec-expectations (~> 3.8.0)
54
+ rspec-mocks (~> 3.8.0)
55
+ rspec-core (3.8.0)
56
+ rspec-support (~> 3.8.0)
57
+ rspec-expectations (3.8.1)
58
+ diff-lcs (>= 1.2.0, < 2.0)
59
+ rspec-support (~> 3.8.0)
60
+ rspec-mocks (3.8.0)
61
+ diff-lcs (>= 1.2.0, < 2.0)
62
+ rspec-support (~> 3.8.0)
63
+ rspec-support (3.8.0)
64
+ rubocop (0.51.0)
65
+ parallel (~> 1.10)
66
+ parser (>= 2.3.3.1, < 3.0)
67
+ powerpack (~> 0.1)
68
+ rainbow (>= 2.2.2, < 3.0)
69
+ ruby-progressbar (~> 1.7)
70
+ unicode-display_width (~> 1.0, >= 1.0.1)
71
+ ruby-progressbar (1.9.0)
72
+ ruby_dep (1.5.0)
73
+ shellany (0.0.1)
74
+ thor (0.20.0)
75
+ unicode-display_width (1.3.0)
76
+
77
+ PLATFORMS
78
+ ruby
79
+
80
+ DEPENDENCIES
81
+ bundler (~> 1.16)
82
+ guard-rspec
83
+ my_gems!
84
+ rake (~> 10.0)
85
+ rspec (~> 3.0)
86
+ rubocop
87
+
88
+ BUNDLED WITH
89
+ 1.16.4
data/Guardfile ADDED
@@ -0,0 +1,70 @@
1
+ # A sample Guardfile
2
+ # More info at https://github.com/guard/guard#readme
3
+
4
+ ## Uncomment and set this to only include directories you want to watch
5
+ # directories %w(app lib config test spec features) \
6
+ # .select{|d| Dir.exists?(d) ? d : UI.warning("Directory #{d} does not exist")}
7
+
8
+ ## Note: if you are using the `directories` clause above and you are not
9
+ ## watching the project directory ('.'), then you will want to move
10
+ ## the Guardfile to a watched dir and symlink it back, e.g.
11
+ #
12
+ # $ mkdir config
13
+ # $ mv Guardfile config/
14
+ # $ ln -s config/Guardfile .
15
+ #
16
+ # and, you'll have to watch "config/Guardfile" instead of "Guardfile"
17
+
18
+ # Note: The cmd option is now required due to the increasing number of ways
19
+ # rspec may be run, below are examples of the most common uses.
20
+ # * bundler: 'bundle exec rspec'
21
+ # * bundler binstubs: 'bin/rspec'
22
+ # * spring: 'bin/rspec' (This will use spring if running and you have
23
+ # installed the spring binstubs per the docs)
24
+ # * zeus: 'zeus rspec' (requires the server to be started separately)
25
+ # * 'just' rspec: 'rspec'
26
+
27
+ guard :rspec, cmd: "bundle exec rspec" do
28
+ require "guard/rspec/dsl"
29
+ dsl = Guard::RSpec::Dsl.new(self)
30
+
31
+ # Feel free to open issues for suggestions and improvements
32
+
33
+ # RSpec files
34
+ rspec = dsl.rspec
35
+ watch(rspec.spec_helper) { rspec.spec_dir }
36
+ watch(rspec.spec_support) { rspec.spec_dir }
37
+ watch(rspec.spec_files)
38
+
39
+ # Ruby files
40
+ ruby = dsl.ruby
41
+ dsl.watch_spec_files_for(ruby.lib_files)
42
+
43
+ # Rails files
44
+ rails = dsl.rails(view_extensions: %w(erb haml slim))
45
+ dsl.watch_spec_files_for(rails.app_files)
46
+ dsl.watch_spec_files_for(rails.views)
47
+
48
+ watch(rails.controllers) do |m|
49
+ [
50
+ rspec.spec.call("routing/#{m[1]}_routing"),
51
+ rspec.spec.call("controllers/#{m[1]}_controller"),
52
+ rspec.spec.call("acceptance/#{m[1]}")
53
+ ]
54
+ end
55
+
56
+ # Rails config changes
57
+ watch(rails.spec_helper) { rspec.spec_dir }
58
+ watch(rails.routes) { "#{rspec.spec_dir}/routing" }
59
+ watch(rails.app_controller) { "#{rspec.spec_dir}/controllers" }
60
+
61
+ # Capybara features specs
62
+ watch(rails.view_dirs) { |m| rspec.spec.call("features/#{m[1]}") }
63
+ watch(rails.layouts) { |m| rspec.spec.call("features/#{m[1]}") }
64
+
65
+ # Turnip features and steps
66
+ watch(%r{^spec/acceptance/(.+)\.feature$})
67
+ watch(%r{^spec/acceptance/steps/(.+)_steps\.rb$}) do |m|
68
+ Dir[File.join("**/#{m[1]}.feature")][0] || "spec/acceptance"
69
+ end
70
+ end
@@ -1,3 +1,3 @@
1
1
  module MyGems
2
- VERSION = "0.1.0"
2
+ VERSION = "0.2.0"
3
3
  end
data/lib/my_gems.rb CHANGED
@@ -1,5 +1,16 @@
1
1
  require "my_gems/version"
2
2
 
3
3
  module MyGems
4
- # Your code goes here...
4
+ class FizzBuzz
5
+ def initialize(number)
6
+ @number = number
7
+ end
8
+
9
+ def say
10
+ return 'FizzBuzz' if @number % 15 == 0
11
+ return 'Buzz' if @number % 5 == 0
12
+ return 'Fizz' if @number % 3 == 0
13
+ @number.to_s
14
+ end
15
+ end
5
16
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: my_gems
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - ogom
@@ -63,6 +63,8 @@ files:
63
63
  - ".rspec"
64
64
  - ".travis.yml"
65
65
  - Gemfile
66
+ - Gemfile.lock
67
+ - Guardfile
66
68
  - LICENSE.txt
67
69
  - README.md
68
70
  - Rakefile