nova-cli 0.2.5 → 0.2.6

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.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/nova/generator.rb +29 -0
  3. data/lib/nova.rb +1 -1
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4a92ecdbd773eb5b3be48411c1a947ad1cb8696f4ceeecba783c42cb2f740f1a
4
- data.tar.gz: bc9a5f7ef3cdecac0c9b2083f131e5fdad280f918b3e9540a3aeab713a301416
3
+ metadata.gz: 151c2a58346e1260b2c7a2248e84e4fa89a72a9226ebcf2773b7b9e79f0a01f2
4
+ data.tar.gz: 9a43f7115da40d8be57576b01b733e747f2af8bac40cabc96875caca863220fc
5
5
  SHA512:
6
- metadata.gz: f4272e18a33a4e86617e7a433bff71c973b3d0f5e015ca1ae85bd430e94408bc3e4723c6f811a9fde0376631580bc32506c1500a3282e4a0b9d93aafdd4d90ef
7
- data.tar.gz: 1d4da4a7794282337336560a1e79c5b73a75f11a54bf26db04e0ccc9278a89803bcc1094783acfcf7465434e2935b8de99bd7b739b03ef4b18cf0012ece8a696
6
+ metadata.gz: abc1c15c0e9ed2ab91e03febdf970a7fa5897adf4d85fd5e31eb1efba08fc911291cd349ff4e1de295cc5f2707bd791fa671367eed8073800f9567b49e003618
7
+ data.tar.gz: e41105ee6c2a22717f8f0c1196266304ec904e4363491bc842c0f903b3c0f1531e8d9fc9e45b8fb39377a04f682cdeade4ffcf99474554989f200f414ad8178c
@@ -51,6 +51,7 @@ module Nova
51
51
  def generate
52
52
  create_main_directories
53
53
  create_all_files_and_directories
54
+ initialize_shape_git_repo
54
55
  display_success_message
55
56
  end
56
57
 
@@ -149,5 +150,33 @@ module Nova
149
150
  create_file_from_template(File.join(app_name, file_entry[:path]), file_entry[:template])
150
151
  end
151
152
  end
153
+
154
+ def initialize_shape_git_repo
155
+ shape_path = File.join(app_name, 'shape')
156
+
157
+ # Initialize git repository in shape directory
158
+ Dir.chdir(shape_path) do
159
+ system('git init', out: File::NULL, err: File::NULL)
160
+
161
+ # Configure git user for initial commit (using system defaults)
162
+ # This ensures the commit works even if global git config is not set
163
+ system('git config user.email "nova-cli@example.com"', out: File::NULL, err: File::NULL)
164
+ system('git config user.name "Nova CLI"', out: File::NULL, err: File::NULL)
165
+
166
+ # Add all files
167
+ system('git add .', out: File::NULL, err: File::NULL)
168
+
169
+ # Make initial commit
170
+ system('git commit -m "Initial nova shape documentation structure"', out: File::NULL, err: File::NULL)
171
+
172
+ # Remove the local git config so user's global config takes over
173
+ system('git config --unset user.email', out: File::NULL, err: File::NULL)
174
+ system('git config --unset user.name', out: File::NULL, err: File::NULL)
175
+ end
176
+
177
+ puts "\n✓ Git repository initialized in shape/ directory with initial commit"
178
+ rescue => e
179
+ puts "\n⚠ Warning: Could not initialize git repository in shape/ directory: #{e.message}"
180
+ end
152
181
  end
153
182
  end
data/lib/nova.rb CHANGED
@@ -2,5 +2,5 @@ require_relative 'nova/cli'
2
2
  require_relative 'nova/generator'
3
3
 
4
4
  module Nova
5
- VERSION = '0.2.5'
5
+ VERSION = '0.2.6'
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nova-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.5
4
+ version: 0.2.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Francis