bake-modernize 0.13.0 → 0.13.1

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: 507d880a18b755b2e592bc82796792b377f68bd30d4484642649be42c35d8d78
4
- data.tar.gz: 15ce7824eba5fe510de11b18debe80ebc216d5c3a744629345c799725768f3cd
3
+ metadata.gz: a5383d60aadbc5f2385c81dd7a03fba4f571baee7f4286d9dfedca1eee1497a9
4
+ data.tar.gz: cc5e62ac4f60879e04d4f73530ca47cac892fd7baa05f31e4d8783ee5df6d0e0
5
5
  SHA512:
6
- metadata.gz: 77db80d99def59dd5b9c84232a466bc22f44b2c150df7817258bfa1c7304fb44e92678fe7079dddef6a17b276873bc41cdb7fd341d0641149c65182ef541c79c
7
- data.tar.gz: 8396c9466c40041b44b71f1a00da695c006084fd5b86d75ccd1491872dd7160a2e34c6b36da9d62d2339397f7632fbe47f639306d60a8cdbbff97802cd62b6ca
6
+ metadata.gz: 76f7fec9e1bae6e30ece5a08fbb88dc10904f8507d81eb86a45ff8b32d755b9ac6f44b3076662f450cfc724351b0146255648e68df7107fce560e3a284c88835
7
+ data.tar.gz: 869556c76b862400d67420e808b2ba94a85a78b3caf0924e6eb79bb883ecefb6e57ca2ce6f7ee8a79b1c9807107aaff059a9d70f8fb7430e19bb89da09f6dde3
checksums.yaml.gz.sig CHANGED
@@ -1,4 +1 @@
1
- H��u]�6?��`$���r1Fs�E,p��` ,_qLn�.8Ϭ+@����F��CFbO�x�* H�y��+�-_!iE���Y��y1ySzM&���:��}��l�H���j��+f3<�V@��j���<���-O�b��̡�d�ӯ���5�]�nMH�UK��F2�
2
- ("��.�St
3
- ;��A������_U�zV���i��E���
4
- ,gS ���*(X�8r���|�.�h/���@�m�F�N���Ãх׏jNvԲ��+X�c
1
+ "�G�>_p����ӥ��ۦK=�+�:%T����lA�v !�K}|�d#�6�\ғeq mdb4�d&[_����7,������FMix�a_Ѐ5Z�>���ؔ����M7-�����% y�E��]��k���航�?AppPZ{=�t>
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
4
  # Copyright, 2020-2022, by Samuel Williams.
3
5
 
@@ -1,5 +1,7 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
- # Copyright, 2020, by Samuel Williams.
4
+ # Copyright, 2020-2022, by Samuel Williams.
3
5
 
4
6
  require 'bake/modernize'
5
7
 
@@ -1,5 +1,7 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
- # Copyright, 2020, by Samuel Williams.
4
+ # Copyright, 2020-2022, by Samuel Williams.
3
5
 
4
6
  require 'bake/modernize'
5
7
 
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
4
  # Copyright, 2020-2022, by Samuel Williams.
3
5
 
@@ -1,5 +1,7 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
- # Copyright, 2021, by Samuel Williams.
4
+ # Copyright, 2021-2022, by Samuel Williams.
3
5
 
4
6
  require 'bake/modernize'
5
7
 
@@ -13,6 +15,9 @@ def update(root:)
13
15
  system("git", "branch", "-M", "main")
14
16
  system("git", "push", "-u", "origin", "main")
15
17
  end
18
+
19
+ template_root = Bake::Modernize.template_path_for('git')
20
+ Bake::Modernize.copy_template(template_root, root)
16
21
  end
17
22
 
18
23
  private
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
4
  # Copyright, 2022, by Samuel Williams.
3
5
 
@@ -49,6 +51,8 @@ def update(root:)
49
51
  end
50
52
 
51
53
  paths.each do |path, authors|
54
+ next unless File.exist?(path)
55
+
52
56
  case path
53
57
  when /\.rb$/
54
58
  self.update_source_file_authors(path, authors)
@@ -62,8 +66,16 @@ def update_source_file_authors(path, authors)
62
66
  input = File.readlines(path)
63
67
  output = []
64
68
 
65
- if input =~ /^\#!/
69
+ if input.first =~ /^\#!/
70
+ output.push input.shift
71
+ end
72
+
73
+ if input.first =~ /^\#.*?\:/
66
74
  output.push input.shift
75
+ if input.first.chomp.empty?
76
+ input.shift
77
+ end
78
+ output << "\n"
67
79
  end
68
80
 
69
81
  # Remove any existing license:
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
4
  # Copyright, 2022, by Samuel Williams.
3
5
 
@@ -1,5 +1,7 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
- # Copyright, 2021, by Samuel Williams.
4
+ # Copyright, 2021-2022, by Samuel Williams.
3
5
 
4
6
  require 'bake/modernize'
5
7
 
data/bake/modernize.rb CHANGED
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
4
  # Copyright, 2020-2022, by Samuel Williams.
3
5
 
@@ -1,8 +1,10 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
4
  # Copyright, 2020-2022, by Samuel Williams.
3
5
 
4
6
  module Bake
5
7
  module Modernize
6
- VERSION = "0.13.0"
8
+ VERSION = "0.13.1"
7
9
  end
8
10
  end
@@ -1,5 +1,7 @@
1
+ # frozen_string_literal: true
2
+
1
3
  # Released under the MIT License.
2
- # Copyright, 2020, by Samuel Williams.
4
+ # Copyright, 2020-2022, by Samuel Williams.
3
5
 
4
6
  require "bake/modernize/version"
5
7
  require 'build/files/glob'
@@ -0,0 +1,5 @@
1
+ /.bundle/
2
+ /pkg/
3
+ /gems.locked
4
+ /.covered.db
5
+ /external
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bake-modernize
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.13.0
4
+ version: 0.13.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
@@ -148,6 +148,7 @@ files:
148
148
  - template/actions/.github/workflows/test-external.yaml
149
149
  - template/actions/.github/workflows/test.yaml
150
150
  - template/editorconfig/.editorconfig
151
+ - template/git/.gitignore
151
152
  - template/readme/README.md
152
153
  homepage: https://github.com/ioquatix/bake-modernize
153
154
  licenses:
metadata.gz.sig CHANGED
Binary file