fasten 0.8.6 → 0.8.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3755f7b4fdd1580eb82e5930db4a11413b8a99a2bca14d71857cb51318ca6359
4
- data.tar.gz: b04722ff51e62edbad0a1a47e62d7bdf1637092069649ff8c42645a860acdf47
3
+ metadata.gz: 8676c0dabe61dbc24c1ac60dcf94978c1be59164d3f5e984baa22aac659429cf
4
+ data.tar.gz: a45dc9af10e008c126ae334ea3629dff04e0317217aad0d9da78370a6a00152d
5
5
  SHA512:
6
- metadata.gz: 48fa44c95c394cf8b31a69064678c47061d0cab9c44eea37e906b2d32fcefbbd3c3dd722b270f250f24874469041927cbeb7d8644a4d321cad097c0503cceefc
7
- data.tar.gz: b47fae7fc3befd3122c505bb88d03425d05c71da83ede189cebec2ee8e471dd588e53f488ce0447a1e561376304a186c2c0d0048383d9ac699974490ea3bd4d1
6
+ metadata.gz: 3b337229f16bf52aa3d8e2ba55d82584f5658aabd552d98c57ca833978cee980c3b0833b8ac8e219a5ce916f4aa6e9b8befb85925dfa354b91638bbe28c3a327
7
+ data.tar.gz: 79bfb314e3ece8694c2968c0ee376a4d22214872d6e7cd90771931307e45f6f48258ddaad4f37476a3103a56b10a67fba814e455a2558fce0f2bed55898f67d6
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- ruby-2.5.3
1
+ ruby-2.6.4
data/.tool-versions ADDED
@@ -0,0 +1 @@
1
+ ruby 2.6.4
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- fasten (0.8.6)
4
+ fasten (0.8.8)
5
5
  binding_of_caller
6
6
  hirb
7
7
  os
@@ -20,7 +20,7 @@ GEM
20
20
  hirb (0.7.3)
21
21
  jaro_winkler (1.5.1)
22
22
  method_source (0.9.1)
23
- os (1.0.0)
23
+ os (1.0.1)
24
24
  parallel (1.12.1)
25
25
  parser (2.5.3.0)
26
26
  ast (~> 2.4.0)
data/README.md CHANGED
@@ -81,6 +81,12 @@ After checking out the repo, run `bin/setup` to install dependencies. Then, run
81
81
 
82
82
  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 tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
83
83
 
84
+ ## Make a new relese
85
+
86
+ Just run the provided script and follow the instructions:
87
+
88
+ $ bin/release-version
89
+
84
90
  ## Contributing
85
91
 
86
92
  Bug reports and pull requests are welcome on GitHub at https://github.com/a0/a0-fasten-ruby. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
@@ -0,0 +1,56 @@
1
+ #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
3
+
4
+ path = File.realpath File.join(__dir__, '../lib/fasten/version.rb')
5
+ load path
6
+
7
+ current = Fasten::VERSION
8
+ numbers = current.split('.').map(&:to_i)
9
+ length = numbers.count
10
+
11
+ versions = length.times.map do |index|
12
+ version = numbers.dup
13
+ version[index] += index.zero? ? 1 : 2
14
+ index += 1
15
+ (index...length).each do |i|
16
+ version[i] = 0
17
+ end
18
+ version.join '.'
19
+ end.reverse
20
+
21
+ text = versions.each_with_index.map do |version, index|
22
+ "#{index + 1}. #{version}"
23
+ end.join("\n")
24
+
25
+ puts <<~FIN
26
+
27
+ Version file: #{path}
28
+
29
+ Current version: #{current}. Choose next version:
30
+ #{text}
31
+
32
+ FIN
33
+
34
+ print 'Choose? [1]'
35
+ option = gets.strip
36
+
37
+ index = option == '' ? 0 : option.to_i - 1
38
+ version = versions[index]
39
+ raise "Invalid option #{option}" unless version
40
+
41
+ `ruby -p -i -e 'gsub /#{current}/,"#{version}"' #{path}`
42
+ puts `bundle; git add #{path} Gemfile.lock; git commit -m "Version #{version}."; git tag v#{version}`
43
+
44
+ puts <<~FIN
45
+
46
+ Press enter to git push or CTRL+C to cancel
47
+
48
+ FIN
49
+
50
+ print 'git push origin master --tags'
51
+ gets
52
+ puts `git push origin master --tags`
53
+
54
+ puts 'rake release'
55
+ gets
56
+ puts `rake release`
@@ -57,8 +57,11 @@ module Fasten
57
57
  end
58
58
 
59
59
  def create_pipes
60
- self.child_read, self.parent_write = IO.pipe
61
- self.parent_read, self.child_write = IO.pipe
60
+ self.child_read, self.parent_write = IO.pipe binmode: true
61
+ self.parent_read, self.child_write = IO.pipe binmode: true
62
+
63
+ child_write.set_encoding 'binary'
64
+ parent_write.set_encoding 'binary'
62
65
  end
63
66
 
64
67
  def close_parent_pipes
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Fasten
4
- VERSION = '0.8.6'
4
+ VERSION = '0.8.8'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fasten
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.6
4
+ version: 0.8.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aldrin Martoq
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-12-28 00:00:00.000000000 Z
11
+ date: 2019-10-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -163,6 +163,7 @@ files:
163
163
  - ".rubocop.yml"
164
164
  - ".ruby-gemset"
165
165
  - ".ruby-version"
166
+ - ".tool-versions"
166
167
  - ".travis.yml"
167
168
  - CODE_OF_CONDUCT.md
168
169
  - Gemfile
@@ -171,6 +172,7 @@ files:
171
172
  - README.md
172
173
  - Rakefile
173
174
  - bin/console
175
+ - bin/release-version
174
176
  - bin/setup
175
177
  - exe/fasten
176
178
  - fasten.gemspec
@@ -212,8 +214,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
212
214
  - !ruby/object:Gem::Version
213
215
  version: '0'
214
216
  requirements: []
215
- rubyforge_project:
216
- rubygems_version: 2.7.8
217
+ rubygems_version: 3.0.3
217
218
  signing_key:
218
219
  specification_version: 4
219
220
  summary: Fasten your seatbelts! Run jobs in parallel, intelligently.