gempilot 0.2.0 → 0.2.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 +4 -4
- data/.ruby-version +1 -1
- data/Rakefile +7 -8
- data/data/templates/gem/Gemfile.erb +1 -0
- data/issues.rec +76 -10
- data/lib/core_ext/string/inflection_methods.rb +3 -1
- data/lib/gempilot/cli/commands/create.rb +12 -0
- data/lib/gempilot/cli/commands/destroy.rb +1 -0
- data/lib/gempilot/cli/commands/new.rb +1 -0
- data/lib/gempilot/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9d85c949ecc31934a9f30013cf3216e6f5560f83f4847caf1ac7d54fad31556b
|
|
4
|
+
data.tar.gz: b27b62a0b5491c32152ef170b300fe2a1bebcce9b848936d6472688bacce545f
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: dcda741a835bb6c586adb888ec6e790edd7c7c72029034d161da046b15e187c7934fbe7bfad65481a056a981bf86bda3b4d910ea7181d67fee0968faa423a4dc
|
|
7
|
+
data.tar.gz: 4f7ac2bad5ab9f332eec6de811d705ea825587a3d4dfbc0dae860e6bdc9520da30fe89dcca3ae3c57d094c0eab2617b535b7d7f17aa7cb9f270ea37b5dbb7f29
|
data/.ruby-version
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
4.0.1
|
data/Rakefile
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
require "bundler/gem_tasks"
|
|
2
|
-
Bundler::GemHelper.install_tasks name: "gempilot"
|
|
3
2
|
|
|
4
3
|
require "minitest/test_task"
|
|
5
4
|
Minitest::TestTask.create
|
|
@@ -7,7 +6,7 @@ Minitest::TestTask.create
|
|
|
7
6
|
require "rspec/core/rake_task"
|
|
8
7
|
RSpec::Core::RakeTask.new(:spec)
|
|
9
8
|
|
|
10
|
-
require_relative
|
|
9
|
+
require_relative "lib/gempilot"
|
|
11
10
|
|
|
12
11
|
namespace :spec do
|
|
13
12
|
desc "Prints the specification suite in documentation format and exits"
|
|
@@ -30,12 +29,12 @@ end
|
|
|
30
29
|
require "rubocop/rake_task"
|
|
31
30
|
RuboCop::RakeTask.new do |t|
|
|
32
31
|
t.patterns = [
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
32
|
+
"lib/*.rb",
|
|
33
|
+
"lib/**/*.rb",
|
|
34
|
+
"spec/*.rb",
|
|
35
|
+
"spec/**/*.rb",
|
|
36
|
+
"test/*.rb",
|
|
37
|
+
"test/**/*.rb",
|
|
39
38
|
]
|
|
40
39
|
end
|
|
41
40
|
|
data/issues.rec
CHANGED
|
@@ -11,16 +11,16 @@
|
|
|
11
11
|
%mandatory: Title Description
|
|
12
12
|
|
|
13
13
|
Id: 6F683910-2EFA-4356-B1FE-3E4FE3E20A38
|
|
14
|
-
Updated:
|
|
14
|
+
Updated: Fri, 05 Jun 2026 00:00:00 -0400
|
|
15
15
|
Title: Rake build triggers gem to be built twice?
|
|
16
16
|
Description: Why am I seeing 2 messages about gempilot being built to pkg/gempilot-0.1.0.gem
|
|
17
|
-
Status:
|
|
17
|
+
Status: closed
|
|
18
18
|
|
|
19
19
|
Id: 011FB117-BC52-453F-A8E8-6955FE3EBCE8
|
|
20
|
-
Updated:
|
|
20
|
+
Updated: Sat, 06 Jun 2026 00:00:00 -0400
|
|
21
21
|
Title: rubocop-rake is not active
|
|
22
22
|
Description: It should be active for this project
|
|
23
|
-
Status:
|
|
23
|
+
Status: closed
|
|
24
24
|
|
|
25
25
|
Id: F0833E66-A35C-4054-884B-F90C81F08838
|
|
26
26
|
Updated: Mon, 02 Mar 2026 10:37:33 -0500
|
|
@@ -35,10 +35,10 @@ Description:
|
|
|
35
35
|
Status: open
|
|
36
36
|
|
|
37
37
|
Id: 131EA3CE-2F3D-4E37-9D9B-A25E0A651F1B
|
|
38
|
-
Updated:
|
|
38
|
+
Updated: Fri, 05 Jun 2026 00:00:00 -0400
|
|
39
39
|
Title: irb is required now as a gem
|
|
40
40
|
Description: Needs to go in template gemfile
|
|
41
|
-
Status:
|
|
41
|
+
Status: closed
|
|
42
42
|
|
|
43
43
|
Id: 3178AC5C-09A9-44A9-ACE1-11BED0BA7276
|
|
44
44
|
Updated: Mon, 06 Apr 2026 00:00:00 -0400
|
|
@@ -53,16 +53,16 @@ Description: The commit should be tagged with git tag upon committing, as this i
|
|
|
53
53
|
Status: closed
|
|
54
54
|
|
|
55
55
|
Id: 7825507C-ABD2-4618-A591-BCDB54152C6B
|
|
56
|
-
Updated:
|
|
56
|
+
Updated: Fri, 05 Jun 2026 00:00:00 -0400
|
|
57
57
|
Title: Rake task version:bump should support "dev increments", like "0.2.1.dev3". Perhaps a task like "version:bump:dev" is created to allow for this
|
|
58
58
|
Description: open
|
|
59
|
-
Status:
|
|
59
|
+
Status: closed
|
|
60
60
|
|
|
61
61
|
Id: 5E4D51AB-F9BF-4C72-8165-F1B900799FA7
|
|
62
|
-
Updated: Sat,
|
|
62
|
+
Updated: Sat, 06 Jun 2026 00:00:00 -0400
|
|
63
63
|
Title: Hundreds of rubocop failures exist
|
|
64
64
|
Description: These need to be addressed
|
|
65
|
-
Status:
|
|
65
|
+
Status: closed
|
|
66
66
|
|
|
67
67
|
Id: 74D0FD90-0421-4452-8591-2798EE6FD23E
|
|
68
68
|
Updated: Sat, 28 Mar 2026 12:59:40 -0400
|
|
@@ -75,3 +75,69 @@ Updated: Mon, 06 Apr 2026 00:00:00 -0400
|
|
|
75
75
|
Title: Replace 4.0.1 with 3.4.8
|
|
76
76
|
Description: Need to move ruby version down to 3.4.8
|
|
77
77
|
Status: closed
|
|
78
|
+
|
|
79
|
+
Id: 776F52C8-390E-11F1-8D46-FE6CB9572C2F
|
|
80
|
+
Updated: Fri, 05 Jun 2026 00:00:00 -0400
|
|
81
|
+
Title: `gempilot new` => `3) command` => `Codeball::Command::Filter` fails
|
|
82
|
+
Description: Generating commands with gempilot new is failing with the following error:
|
|
83
|
+
+ gempilot new command 'Codeball::Command::Filter'
|
|
84
|
+
+
|
|
85
|
+
+ Oops! Looks like you have found a bug. Please report it!
|
|
86
|
+
+ https://github.com/dgillis/gempilot/issues/new
|
|
87
|
+
+
|
|
88
|
+
+ ```
|
|
89
|
+
+ gempilot new: /Users/davidgillis/.rbenv/versions/4.0.1/lib/ruby/gems/4.0.0/gems/gempilot-0.2.0/lib/core_ext/string/inflection_methods.rb:33:in 'scan_word_token': cannot convert string to underscored: "Codeball::Command::Filter" (ArgumentError)
|
|
90
|
+
+
|
|
91
|
+
+ raise(ArgumentError, "cannot convert string to underscored: #{scanner.string.inspect}")
|
|
92
|
+
Status: closed
|
|
93
|
+
|
|
94
|
+
Id: 4EB6E51C-4322-11F1-B1B2-FE6CB9572C2F
|
|
95
|
+
Updated: Tue, 28 Apr 2026 12:50:05 -0400
|
|
96
|
+
Title: Existing git repo on gempilot create needs new commit message
|
|
97
|
+
Description: Currently it commits "Initial commit". Inappropriate for a git repo that already has a history
|
|
98
|
+
Status: open
|
|
99
|
+
|
|
100
|
+
Id: 0411D4DA-4323-11F1-847C-FE6CB9572C2F
|
|
101
|
+
Updated: Tue, 28 Apr 2026 12:55:09 -0400
|
|
102
|
+
Title: rubocop config should not exclude rakelib
|
|
103
|
+
Description: it is supplied by gempilot. Should not be eliminating author files
|
|
104
|
+
Status: open
|
|
105
|
+
|
|
106
|
+
Id: C72CD130-4324-11F1-ACAE-FE6CB9572C2F
|
|
107
|
+
Updated: Tue, 28 Apr 2026 13:07:46 -0400
|
|
108
|
+
Title: Make zeitwerk setup a block
|
|
109
|
+
Description: e.g.
|
|
110
|
+
+ Zeitwerk::Loader.for_gem.tap do |l|
|
|
111
|
+
+ l.setup
|
|
112
|
+
+ end
|
|
113
|
+
+
|
|
114
|
+
+
|
|
115
|
+
Status: open
|
|
116
|
+
|
|
117
|
+
Id: 5618BB20-4325-11F1-BF5A-FE6CB9572C2F
|
|
118
|
+
Updated: Tue, 28 Apr 2026 13:11:46 -0400
|
|
119
|
+
Title: Move zeitwerk check task into gempilot
|
|
120
|
+
Description: Can't iterate on it when its not managed by gempilot. A new feature needs to be added
|
|
121
|
+
Status: open
|
|
122
|
+
|
|
123
|
+
Id: 6BE168E4-4325-11F1-BE0F-FE6CB9572C2F
|
|
124
|
+
Updated: Tue, 28 Apr 2026 13:12:22 -0400
|
|
125
|
+
Title: Add zeitwerk:all task
|
|
126
|
+
Description: Add rake task that runs LOADER.all_expected_cpaths and prints in a nice table, similar to rails routes
|
|
127
|
+
Status: open
|
|
128
|
+
|
|
129
|
+
Id: 56DB9634-4327-11F1-8D0F-FE6CB9572C2F
|
|
130
|
+
Updated: Fri, 05 Jun 2026 00:00:00 -0400
|
|
131
|
+
Title: 'gempilot new' doesn't even work
|
|
132
|
+
Description: "
|
|
133
|
+
+ Fully-qualified constant name (e.g., Television::Services::Authentication).
|
|
134
|
+
+ Constant: Television::CLI::Screen
|
|
135
|
+
+
|
|
136
|
+
+ Oops! Looks like you have found a bug. Please report it!
|
|
137
|
+
+ https://github.com/dgillis/gempilot/issues/new
|
|
138
|
+
+
|
|
139
|
+
+ ```
|
|
140
|
+
+ gempilot new: /Users/davidgillis/.rbenv/versions/4.0.1/lib/ruby/gems/4.0.0/gems/gempilot-0.2.0/lib/core_ext/string/inflection_methods.rb:33:in 'scan_word_token': cannot convert string to underscored: "Television::CLI::Screen" (ArgumentError)
|
|
141
|
+
+ ```
|
|
142
|
+
+ "
|
|
143
|
+
Status: closed
|
|
@@ -36,6 +36,8 @@ class String
|
|
|
36
36
|
def scan_underscore_separator(scanner)
|
|
37
37
|
if (sep = scanner.scan(/[_-]+/))
|
|
38
38
|
"_" * sep.length
|
|
39
|
+
elsif scanner.scan("::")
|
|
40
|
+
"/"
|
|
39
41
|
elsif scanner.eos?
|
|
40
42
|
""
|
|
41
43
|
else
|
|
@@ -58,7 +60,7 @@ class String
|
|
|
58
60
|
|
|
59
61
|
if scanner.scan(/[_-]+/)
|
|
60
62
|
nil
|
|
61
|
-
elsif scanner.scan(%r{
|
|
63
|
+
elsif scanner.scan(%r{/|::})
|
|
62
64
|
buffer << "::"
|
|
63
65
|
else
|
|
64
66
|
raise(ArgumentError, "cannot convert string to CamelCase: #{scanner.string.inspect}")
|
|
@@ -87,11 +87,23 @@ module Gempilot
|
|
|
87
87
|
initialize_git_repo
|
|
88
88
|
end
|
|
89
89
|
|
|
90
|
+
GEM_NAME_PATTERN = /\A[a-z][a-z0-9]*([_-][a-z0-9]+)*\z/
|
|
91
|
+
private_constant :GEM_NAME_PATTERN
|
|
92
|
+
|
|
90
93
|
def collect_gem_name(gem_name)
|
|
91
94
|
@gem_name = gem_name || begin
|
|
92
95
|
puts colors.bright_black("The gem name determines the directory, require path, and gemspec name.")
|
|
93
96
|
ask(colors.green("Gem name"), required: true)
|
|
94
97
|
end
|
|
98
|
+
validate_gem_name
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
def validate_gem_name
|
|
102
|
+
return if @gem_name.match?(GEM_NAME_PATTERN)
|
|
103
|
+
|
|
104
|
+
puts colors.red("Invalid gem name '#{@gem_name}'.")
|
|
105
|
+
puts colors.red("Use lowercase letters, digits, hyphens, or underscores (e.g., my_gem or my-gem).")
|
|
106
|
+
exit 1
|
|
95
107
|
end
|
|
96
108
|
|
|
97
109
|
def derive_naming
|
|
@@ -114,6 +114,7 @@ module Gempilot
|
|
|
114
114
|
end
|
|
115
115
|
|
|
116
116
|
def add_command(name)
|
|
117
|
+
name = name.split("::").last if name.include?("::")
|
|
117
118
|
file_name = name.underscore
|
|
118
119
|
command_name = name.camelize
|
|
119
120
|
file_path = File.join("lib", @require_path, "cli", "commands", "#{file_name}.rb")
|
data/lib/gempilot/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: gempilot
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- David Gillis
|
|
@@ -159,7 +159,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
159
159
|
- !ruby/object:Gem::Version
|
|
160
160
|
version: '0'
|
|
161
161
|
requirements: []
|
|
162
|
-
rubygems_version: 4.0.
|
|
162
|
+
rubygems_version: 4.0.13
|
|
163
163
|
specification_version: 4
|
|
164
164
|
summary: A toolkit for creating, managing, and releasing your own rubygems
|
|
165
165
|
test_files: []
|