bake-modernize 0.4.9 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/bake/modernize/gemspec.rb +9 -1
- data/bake/modernize/git.rb +28 -0
- data/bake/modernize/signing.rb +15 -0
- data/bake/modernize.rb +1 -1
- data/lib/bake/modernize/version.rb +1 -1
- data/template/actions/.github/workflows/development.yml +1 -0
- data/template/actions/.github/workflows/documentation.yml +2 -2
- data.tar.gz.sig +3 -0
- metadata +34 -4
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e11c201a35fdc9cd899028ac476adab1f763a51671b8007968e35f91225ea53f
|
4
|
+
data.tar.gz: 8299d83c2cc14942f10df8b9a9b0689b1ac61d558894e32e91b621cf5bd96307
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b466a7d30dd821f6e83a5eb7c0be394e3d1fd6089ab1c2e2a43516e33cc127971ca20b98dbd15e80d2278e402e5f005383a4623b5bc7328b1a01667525a5cc1b
|
7
|
+
data.tar.gz: 1e2208a4ee6f2aaa6aa4c2763307c583f3dd21346e04853720392d546b83ec6f15f6006214b3ded3d0f2d2138742355236fbc706ff4a526d853a363940367f63
|
checksums.yaml.gz.sig
ADDED
Binary file
|
data/bake/modernize/gemspec.rb
CHANGED
@@ -12,7 +12,7 @@ end
|
|
12
12
|
# Rewrite the specified gemspec.
|
13
13
|
# @param
|
14
14
|
def update(path: default_gemspec_path, output: $stdout)
|
15
|
-
spec = Gem::Specification.load(path)
|
15
|
+
spec = ::Gem::Specification.load(path)
|
16
16
|
|
17
17
|
root = File.dirname(path)
|
18
18
|
version_path = version_path(root)
|
@@ -38,6 +38,14 @@ def update(path: default_gemspec_path, output: $stdout)
|
|
38
38
|
output.puts "\tspec.authors = #{spec.authors.inspect}"
|
39
39
|
output.puts "\tspec.license = #{spec.license.inspect}"
|
40
40
|
|
41
|
+
certificate_path = File.expand_path('release.cert', root)
|
42
|
+
|
43
|
+
if File.exist?(certificate_path)
|
44
|
+
output.puts "\t"
|
45
|
+
output.puts "\tspec.cert_chain = ['release.cert']"
|
46
|
+
output.puts "\tspec.signing_key = File.expand_path('~/.gem/release.pem')"
|
47
|
+
end
|
48
|
+
|
41
49
|
if spec.homepage and !spec.homepage.empty?
|
42
50
|
output.puts "\t"
|
43
51
|
output.puts "\tspec.homepage = #{spec.homepage.inspect}"
|
@@ -0,0 +1,28 @@
|
|
1
|
+
|
2
|
+
require 'bake/modernize'
|
3
|
+
|
4
|
+
def git
|
5
|
+
update(root: Dir.pwd)
|
6
|
+
end
|
7
|
+
|
8
|
+
def update(root:)
|
9
|
+
if current_branch != "main"
|
10
|
+
# https://github.com/github/renaming
|
11
|
+
system("git", "branch", "-M", "main")
|
12
|
+
system("git", "push", "-u", "origin", "main")
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
16
|
+
private
|
17
|
+
|
18
|
+
def current_branch
|
19
|
+
require 'open3'
|
20
|
+
|
21
|
+
output, status = Open3.capture2("git", "branch", "--show-current")
|
22
|
+
|
23
|
+
unless status.success?
|
24
|
+
raise "Could not get current branch!"
|
25
|
+
end
|
26
|
+
|
27
|
+
return output
|
28
|
+
end
|
@@ -0,0 +1,15 @@
|
|
1
|
+
|
2
|
+
require 'bake/modernize'
|
3
|
+
|
4
|
+
def signing
|
5
|
+
update(root: Dir.pwd)
|
6
|
+
end
|
7
|
+
|
8
|
+
def update(root:)
|
9
|
+
release_certificate_path = File.expand_path("~/.gem/release.cert")
|
10
|
+
certificate_path = File.expand_path("release.cert", root)
|
11
|
+
|
12
|
+
if File.exist?(release_certificate_path)
|
13
|
+
FileUtils.cp(release_certificate_path, certificate_path)
|
14
|
+
end
|
15
|
+
end
|
data/bake/modernize.rb
CHANGED
@@ -3,7 +3,7 @@ name: Documentation
|
|
3
3
|
on:
|
4
4
|
push:
|
5
5
|
branches:
|
6
|
-
-
|
6
|
+
- main
|
7
7
|
|
8
8
|
jobs:
|
9
9
|
deploy:
|
@@ -15,7 +15,7 @@ jobs:
|
|
15
15
|
env:
|
16
16
|
BUNDLE_WITH: maintenance
|
17
17
|
with:
|
18
|
-
ruby-version:
|
18
|
+
ruby-version: 3.0
|
19
19
|
bundler-cache: true
|
20
20
|
|
21
21
|
- name: Installing packages
|
data.tar.gz.sig
ADDED
@@ -0,0 +1,3 @@
|
|
1
|
+
7�mVD�:s�=�G��Iy�\�Ñۗ�=����:��N�*��Hqp���4$���T�M'�J��x�L<G���U ������ЪER5.���K�kJI;�"e��+�0$i��-���\�x�~İ���J�-0��b^`C�q߸wBy�0��X��)=�(�����1=�;��6�/��z�z�vתlw�07��pSy�嫸�J��n#!lDg#.&{g�D��!�������f���L������6�Nf��LP5P�o��J� �XP�Qj8'�o��I!��w*�
|
2
|
+
G����G<�B��?[>�s]��P����?.��ڗU�{͟8X�kPc�v?.?s: <T��jc��.
|
3
|
+
�
|
metadata
CHANGED
@@ -1,14 +1,42 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bake-modernize
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Samuel Williams
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
|
-
cert_chain:
|
11
|
-
|
10
|
+
cert_chain:
|
11
|
+
- |
|
12
|
+
-----BEGIN CERTIFICATE-----
|
13
|
+
MIIEhDCCAuygAwIBAgIBATANBgkqhkiG9w0BAQsFADA3MTUwMwYDVQQDDCxzYW11
|
14
|
+
ZWwud2lsbGlhbXMvREM9b3Jpb250cmFuc2Zlci9EQz1jby9EQz1uejAeFw0yMTA4
|
15
|
+
MTYwNjMzNDRaFw0yMjA4MTYwNjMzNDRaMDcxNTAzBgNVBAMM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6g4VWO5ZU7z2JmPoTXZtYMunRAmQPFL/gSUc6aK
|
31
|
+
vszMHIyhtyzRc6DnfW2AiVOjMBjaYv8xXZc9bduniRVPrLR4J7ozmGLh4o4uJp7w
|
32
|
+
x9KCFaR8Lvn/r0oJWJOqb/DMAYI83YeN2Dlt3jpwrsmsONrtC5S3gOUle5afSGos
|
33
|
+
bYt5ocnEpKSomR9ZtnCGljds/aeO1Xgpn2r9HHcjwnH346iNrnHmMlC7BtHUFPDg
|
34
|
+
Ts92S47PTOXzwPBDsrFiq3VLbRjHSwf8rpqybQBH9MfzxGGxTaETQYOd6b4e4Ag6
|
35
|
+
y92abGna0bmIEb4+Tx9rQ10Uijh1POzvr/VTH4bbIPy9FbKrRsIQ24qDbNJRtOpE
|
36
|
+
RAOsIl+HOBTb252nx1kIRN5hqQx272AJCbCjKx8egcUQKffFVVCI0nye09v5CK+a
|
37
|
+
HiLJ8VOFx6w=
|
38
|
+
-----END CERTIFICATE-----
|
39
|
+
date: 2021-09-20 00:00:00.000000000 Z
|
12
40
|
dependencies:
|
13
41
|
- !ruby/object:Gem::Dependency
|
14
42
|
name: async-http
|
@@ -105,6 +133,8 @@ files:
|
|
105
133
|
- bake/modernize/editorconfig.rb
|
106
134
|
- bake/modernize/gemfile.rb
|
107
135
|
- bake/modernize/gemspec.rb
|
136
|
+
- bake/modernize/git.rb
|
137
|
+
- bake/modernize/signing.rb
|
108
138
|
- lib/bake/modernize.rb
|
109
139
|
- lib/bake/modernize/version.rb
|
110
140
|
- template/actions/.github/workflows/development.yml
|
@@ -131,7 +161,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
131
161
|
- !ruby/object:Gem::Version
|
132
162
|
version: '0'
|
133
163
|
requirements: []
|
134
|
-
rubygems_version: 3.
|
164
|
+
rubygems_version: 3.1.6
|
135
165
|
signing_key:
|
136
166
|
specification_version: 4
|
137
167
|
summary: Automatically modernize parts of your project/gem.
|
metadata.gz.sig
ADDED
Binary file
|