chimney 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 2d38593cffb80c6a8d14f332d5ccc8667a99941fbb8cbc82c014356e7d88aa3e
4
+ data.tar.gz: '09a536734478ac30c552c6ae625ea3409dac709a2f6b31f6bdcc38abcf39ec6b'
5
+ SHA512:
6
+ metadata.gz: 5c6aa04db2effd9f7f4df298c449f02d25d78540ce397eab35ac5d2573204f01c00c3c9842a3bcc56c6488f91857977bc15de3ff54bf04efe2ee4334f3ab272f
7
+ data.tar.gz: 2da2642f1deffa66be3501959d2d859a2dd22ad2ed7460659c21da47f8a15021450a6eef41ac7bdb99671a24a977af2183b5dddf149f5281448f71fdccbad7ef
data/.gitignore ADDED
@@ -0,0 +1,68 @@
1
+ # files without extensions except directories
2
+ #*
3
+ #!/**/
4
+ #!?*.*
5
+
6
+ # directories (these will ignore .keep)
7
+ /.bundle/
8
+ /_yardoc/
9
+ /coverage/
10
+ /doc/
11
+ /pkg/
12
+ /spec/reports/
13
+ /vendor/
14
+ /node_modules/
15
+
16
+ # directory contents (these will not ignore .keep)
17
+ /cache/*
18
+ /tmp/*
19
+ /pid/*
20
+ /log/*
21
+ /public/*
22
+ /db/*
23
+
24
+ # files
25
+ *.dump
26
+ *.log
27
+ *.mod
28
+ *.o
29
+ *~
30
+ .*.swp
31
+ .DS_Store
32
+ .byebug
33
+ .idea
34
+ .project
35
+ .rake*
36
+ .rake*
37
+ .ruby-*
38
+ .rvmrc
39
+ .rubocop*
40
+ .secret
41
+ .yardoc
42
+ TODO.md
43
+ core.*
44
+ cscope.out
45
+ secrets.yml
46
+ .tags
47
+ NOTES*
48
+ MEETING*
49
+ *.jar
50
+
51
+ # don't ignore
52
+ !.gitignore
53
+ !.keep
54
+ !Capfile
55
+ !Cheffile
56
+ !Gemfile
57
+ ![MR]akefile
58
+ !bin/**/[^.]*
59
+ !exe/**/[^.]*
60
+
61
+ /.bundle/
62
+ /.yardoc
63
+ /_yardoc/
64
+ /coverage/
65
+ /doc/
66
+ /pkg/
67
+ /spec/reports/
68
+ /tmp/
data/.rubocop.yml ADDED
@@ -0,0 +1,38 @@
1
+ # Generate rubocop_todo.yml via 'rubocop --auto-gen-config'
2
+ inherit_from: .rubocop_todo.yml
3
+
4
+ AllCops: { Exclude: [ bin/**/*, node_modules/**/*, tmp/**/*, vendor/**/*, .git/**/* ] }
5
+
6
+ Layout/CommentIndentation: { Enabled: false }
7
+ Layout/LeadingCommentSpace: { Enabled: false }
8
+ Layout/SpaceAroundOperators: { Enabled: false }
9
+ Layout/SpaceAfterComma: { Enabled: false }
10
+ Naming/MethodParameterName: { Enabled: false }
11
+ Style/Documentation: { Enabled: false }
12
+ Style/FrozenStringLiteralComment: { Enabled: false }
13
+ Style/FormatStringToken: { Enabled: false }
14
+ Style/StringLiterals: { Enabled: false }
15
+ Layout/LineLength: { Max: 85, IgnoredPatterns: [ ^ *# ], Exclude: [ test/**/*, app/controllers/**/*, config/**/*, Gemfile ] }
16
+ Layout/HashAlignment: { Enabled: false }
17
+ Metrics/BlockLength: { Exclude: [ lib/tasks/**/*, db/schema.rb ] }
18
+ Layout/EmptyLinesAroundBlockBody: { Exclude: [ db/schema.rb ] }
19
+ Style/NumericLiterals: { Exclude: [ db/schema.rb ] }
20
+ Metrics/MethodLength: { Max: 20, Exclude: [ db/migrate/* ] }
21
+ Metrics/AbcSize: { Exclude: [ db/migrate/* ] }
22
+ Style/CommentAnnotation: { Enabled: false }
23
+ Style/RedundantCondition: { Enabled: false }
24
+ Style/PerlBackrefs: { Enabled: false }
25
+ Style/ParallelAssignment: { Enabled: false }
26
+ Style/GuardClause: { Enabled: false }
27
+
28
+ # TODO try to use 'SafeAssignmentInCondition' instead of disabling this cop
29
+ Lint/AssignmentInCondition: { Enabled: false}
30
+
31
+ # These are new cops that must be enabled explicitly to remove warning messages
32
+ Layout/SpaceAroundMethodCallOperator: { Enabled: true }
33
+ Lint/RaiseException: { Enabled: true }
34
+ Lint/StructNewOverride: { Enabled: true }
35
+ Style/ExponentialNotation: { Enabled: true }
36
+ Style/HashEachMethods: { Enabled: true }
37
+ Style/HashTransformKeys: { Enabled: true }
38
+ Style/HashTransformValues: { Enabled: true }
data/CHANGELOG.md ADDED
@@ -0,0 +1,5 @@
1
+ ## [Unreleased]
2
+
3
+ ## [0.1.0] - 2021-07-26
4
+
5
+ - Initial release
data/Gemfile ADDED
@@ -0,0 +1,6 @@
1
+ # frozen_string_literal: true
2
+
3
+ source "https://rubygems.org"
4
+
5
+ # Specify your gem's dependencies in chimney.gemspec
6
+ gemspec
data/Gemfile.lock ADDED
@@ -0,0 +1,52 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ chimney (0.1.0)
5
+
6
+ GEM
7
+ remote: https://rubygems.org/
8
+ specs:
9
+ ansi (1.5.0)
10
+ ast (2.4.2)
11
+ builder (3.2.4)
12
+ byebug (11.0.1)
13
+ minitest (5.14.4)
14
+ minitest-reporters (1.4.3)
15
+ ansi
16
+ builder
17
+ minitest (>= 5.0)
18
+ ruby-progressbar
19
+ parallel (1.20.1)
20
+ parser (3.0.2.0)
21
+ ast (~> 2.4.1)
22
+ rainbow (3.0.0)
23
+ rake (13.0.6)
24
+ regexp_parser (2.1.1)
25
+ rexml (3.2.5)
26
+ rubocop (1.18.3)
27
+ parallel (~> 1.10)
28
+ parser (>= 3.0.0.0)
29
+ rainbow (>= 2.2.2, < 4.0)
30
+ regexp_parser (>= 1.8, < 3.0)
31
+ rexml
32
+ rubocop-ast (>= 1.7.0, < 2.0)
33
+ ruby-progressbar (~> 1.7)
34
+ unicode-display_width (>= 1.4.0, < 3.0)
35
+ rubocop-ast (1.8.0)
36
+ parser (>= 3.0.1.1)
37
+ ruby-progressbar (1.11.0)
38
+ unicode-display_width (2.0.0)
39
+
40
+ PLATFORMS
41
+ x86_64-linux
42
+
43
+ DEPENDENCIES
44
+ byebug (~> 11.0.1)
45
+ chimney!
46
+ minitest (~> 5.0)
47
+ minitest-reporters
48
+ rake
49
+ rubocop (~> 1.7)
50
+
51
+ BUNDLED WITH
52
+ 2.2.17
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2021 Sergio Romero
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,39 @@
1
+ # Chimney
2
+
3
+ Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/chimney`. To experiment with that code, run `bin/console` for an interactive prompt.
4
+
5
+ TODO: Delete this and the text above, and describe your gem
6
+
7
+ ## Installation
8
+
9
+ Add this line to your application's Gemfile:
10
+
11
+ ```ruby
12
+ gem 'chimney'
13
+ ```
14
+
15
+ And then execute:
16
+
17
+ $ bundle install
18
+
19
+ Or install it yourself as:
20
+
21
+ $ gem install chimney
22
+
23
+ ## Usage
24
+
25
+ TODO: Write usage instructions here
26
+
27
+ ## Development
28
+
29
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
30
+
31
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
32
+
33
+ ## Contributing
34
+
35
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/chimney.
36
+
37
+ ## License
38
+
39
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
data/Rakefile ADDED
@@ -0,0 +1,15 @@
1
+ require 'bundler/gem_tasks'
2
+ require 'rake/testtask'
3
+ require 'rake/clean'
4
+
5
+ CLEAN.include ['**/.*.sw?', '**/*.gem', 'test/test.log']
6
+
7
+ task default: %i[test package]
8
+ task package: :clean
9
+
10
+ Rake::TestTask.new do |t|
11
+ t.libs << 'lib' << 'test'
12
+ t.test_files = FileList['test/**/*_test.rb']
13
+ t.warning = false
14
+ t.verbose = false
15
+ end
data/bin/console ADDED
@@ -0,0 +1,15 @@
1
+ #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
3
+
4
+ require "bundler/setup"
5
+ require "chimney"
6
+
7
+ # You can add fixtures and/or initialization code here to make experimenting
8
+ # with your gem easier. You can also use a different console, if you like.
9
+
10
+ # (If you use this, don't forget to add pry to your Gemfile!)
11
+ # require "pry"
12
+ # Pry.start
13
+
14
+ require "irb"
15
+ IRB.start(__FILE__)
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
data/chimney.gemspec ADDED
@@ -0,0 +1,45 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative "lib/chimney/version"
4
+
5
+ Gem::Specification.new do |spec|
6
+ spec.name = "chimney"
7
+ spec.version = Chimney::VERSION
8
+ spec.authors = ["Sergio Romero"]
9
+ spec.email = ["yo@sergioro.com"]
10
+
11
+ spec.summary = "Write a short summary, because RubyGems requires one."
12
+ spec.description = "Write a longer description or delete this line."
13
+ #spec.homepage = "http://example.com"
14
+ spec.license = "MIT"
15
+ spec.required_ruby_version = Gem::Requirement.new(">= 2.4.0")
16
+
17
+ #spec.metadata["allowed_push_host"] = "Set to 'http://mygemserver.com'"
18
+ #spec.metadata["homepage_uri"] = spec.homepage
19
+ #spec.metadata["source_code_uri"] = "Put your gem's public repo URL here."
20
+ #spec.metadata["changelog_uri"] = "Put your gem's CHANGELOG.md URL here."
21
+
22
+ # Specify which files should be added to the gem when it is released.
23
+ # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
24
+ spec.files = Dir.chdir(File.expand_path(__dir__)) do
25
+ `git ls-files -z`.split("\x0").reject { |f| f.match(%r{\A(?:test|spec|features)/}) }
26
+ end
27
+ spec.bindir = "exe"
28
+ spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
29
+ spec.require_paths = ["lib"]
30
+
31
+ # Uncomment to register a new dependency of your gem
32
+ # spec.add_dependency "example-gem", "~> 1.0"
33
+
34
+ # For more information and examples about making a new gem, checkout our
35
+ # guide at: https://bundler.io/guides/creating_gem.html
36
+
37
+ #spec.add_development_dependency "benchmark-ips", ">= 0"
38
+ spec.add_development_dependency "byebug", "~> 11.0.1"
39
+ spec.add_development_dependency "minitest", "~> 5.0"
40
+ spec.add_development_dependency "minitest-reporters"
41
+ spec.add_development_dependency "rake"
42
+ #spec.add_development_dependency "ruby-prof"
43
+
44
+ #spec.add_runtime_dependency "SOME_GEM", "~> VERSION"
45
+ end
data/exe/chimney ADDED
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ $LOAD_PATH.unshift File.expand_path('../lib', __dir__)
4
+
5
+ require "chimney"
data/lib/chimney.rb ADDED
@@ -0,0 +1,44 @@
1
+ $LOAD_PATH.unshift __dir__
2
+
3
+ require "xyz/version"
4
+ require 'optparse'
5
+
6
+ module Chimney
7
+ class Error < StandardError; end
8
+
9
+ def self.run(args)
10
+ options = Options.parse(args)
11
+ end
12
+
13
+ class Options
14
+ def self.parse(args)
15
+ options = {}
16
+
17
+ OptionParser.new do |opts|
18
+ opts.program_name = File.basename(bash)
19
+ opts.banner = "Usage: #{opts.program_name} [options]"
20
+
21
+ opts.separator ""
22
+ opts.separator "Options:"
23
+
24
+ opts.on("-oNAME", "--output=NAME", "Specify output file name") do |v|
25
+ options[:output] = v
26
+ end
27
+
28
+ opts.on("-v", "--[no-]verbose", "Run verbosely") do |v|
29
+ options[:verbose] = v
30
+ end
31
+
32
+ opts.on_tail("-h", "--help", "Print help", "something else") do |v|
33
+ abort opts.to_s
34
+ end
35
+
36
+ opts.on_tail("-V", "--version", "Print version") do |v|
37
+ abort "#{opts.program_name} #{VERSION}"
38
+ end
39
+ end.parse!(args)
40
+
41
+ options
42
+ end
43
+ end
44
+ end
@@ -0,0 +1,5 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Chimney
4
+ VERSION = "0.1.0"
5
+ end
metadata ADDED
@@ -0,0 +1,114 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: chimney
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Sergio Romero
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2021-07-26 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: byebug
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: 11.0.1
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: 11.0.1
27
+ - !ruby/object:Gem::Dependency
28
+ name: minitest
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '5.0'
34
+ type: :development
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '5.0'
41
+ - !ruby/object:Gem::Dependency
42
+ name: minitest-reporters
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rake
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
69
+ description: Write a longer description or delete this line.
70
+ email:
71
+ - yo@sergioro.com
72
+ executables:
73
+ - chimney
74
+ extensions: []
75
+ extra_rdoc_files: []
76
+ files:
77
+ - ".gitignore"
78
+ - ".rubocop.yml"
79
+ - CHANGELOG.md
80
+ - Gemfile
81
+ - Gemfile.lock
82
+ - LICENSE.txt
83
+ - README.md
84
+ - Rakefile
85
+ - bin/console
86
+ - bin/setup
87
+ - chimney.gemspec
88
+ - exe/chimney
89
+ - lib/chimney.rb
90
+ - lib/chimney/version.rb
91
+ homepage:
92
+ licenses:
93
+ - MIT
94
+ metadata: {}
95
+ post_install_message:
96
+ rdoc_options: []
97
+ require_paths:
98
+ - lib
99
+ required_ruby_version: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: 2.4.0
104
+ required_rubygems_version: !ruby/object:Gem::Requirement
105
+ requirements:
106
+ - - ">="
107
+ - !ruby/object:Gem::Version
108
+ version: '0'
109
+ requirements: []
110
+ rubygems_version: 3.2.11
111
+ signing_key:
112
+ specification_version: 4
113
+ summary: Write a short summary, because RubyGems requires one.
114
+ test_files: []