jeanine 0.6.0 → 0.7.0

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
  SHA1:
3
- metadata.gz: 605777e016821bd0a6bd5e400d84dc6c5ad1e2fd
4
- data.tar.gz: 5547bdb35a9a9612f6f1d327c3fc0fa14bae5f83
3
+ metadata.gz: d3df31123e22ecf9f1dd465af168aa34b3199e75
4
+ data.tar.gz: 9fb4883db99cbf0a30b4895064bcb10f00896c6c
5
5
  SHA512:
6
- metadata.gz: e83f8c437da8c145fd618d425e8e1dcf6fb223b492daab6c0ddcb8c24cea734a3d6e0a529ea67713aff2148dd88e13de0f0d5f26f397d06fc66dca7cf6c86995
7
- data.tar.gz: b87de6a104f9b2b7ebd09e10a53aee551dd81b5ea9bcbadd43af7a599e472aeb76b5bb927067c5e0f05cac64286e09387ceca0966c04a02b23429f0eea703c3e
6
+ metadata.gz: e871411c10b283ab9ad26c5b568870e651dc25110cb1e5ea842e607dfe1d3d28dfac640bb574cfe19ee0bb01575668e1906fdbd2c9d5304e0c85a75977d3bfd4
7
+ data.tar.gz: 214f87e732bbfa864f5b64574c27b4a284c260c7447dc867af01a94da52edac49308d427da84c19846b8c540a2309ab3d81117b99b6f4330df04b194b3b5c65a
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require_relative '../lib/jeanine/cli'
4
+
5
+ Jeanine::CLI.new(ARGV).execute
@@ -0,0 +1,32 @@
1
+ require 'fileutils'
2
+
3
+ module Jeanine
4
+ class CLI
5
+ def initialize(args)
6
+ @args = args
7
+ end
8
+
9
+ def execute
10
+ if @args[0] == 'new'
11
+ command_new!
12
+ else
13
+ $stdout.puts "I don't know how to `#{@args[0]}`. Maybe you meant `new`?"
14
+ end
15
+ end
16
+
17
+ def command_new!
18
+ FileUtils.mkdir("#{@args[1]}") unless Dir.exists?("#{@args[1]}")
19
+ FileUtils.mkdir("#{@args[1]}/config") unless Dir.exists?("#{@args[1]}/config")
20
+ relative_dir = "lib/jeanine/generator/new"
21
+ Dir.glob("lib/jeanine/generator/new/**/*.*").each do |file|
22
+ new_dir = file.gsub(relative_dir, "#{@args[1]}")[0...-3]
23
+ FileUtils.copy_file(file, new_dir)
24
+ end
25
+ relative_dir = "lib/jeanine/generator/new/config"
26
+ Dir.glob("lib/jeanine/generator/new/config/**/*.*").each do |file|
27
+ new_dir = file.gsub(relative_dir, "#{@args[1]}/config")[0...-3]
28
+ FileUtils.copy_file(file, new_dir)
29
+ end
30
+ end
31
+ end
32
+ end
@@ -1,3 +1,3 @@
1
1
  module Jeanine
2
- VERSION = "0.6.0"
2
+ VERSION = "0.7.0"
3
3
  end
metadata CHANGED
@@ -1,12 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jeanine
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.0
4
+ version: 0.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Josh Brody
8
8
  autorequire:
9
- bindir: bin
9
+ bindir: exe
10
10
  cert_chain: []
11
11
  date: 2020-07-08 00:00:00.000000000 Z
12
12
  dependencies:
@@ -108,16 +108,18 @@ dependencies:
108
108
  - - ">="
109
109
  - !ruby/object:Gem::Version
110
110
  version: '0'
111
- description: A framework.
111
+ description: A lightning-fast, batteries-included Ruby web micro-framework.
112
112
  email:
113
113
  - git@josh.mn
114
114
  executables: []
115
115
  extensions: []
116
116
  extra_rdoc_files: []
117
117
  files:
118
+ - exe/jeanine
118
119
  - lib/jeanine.rb
119
120
  - lib/jeanine/app.rb
120
121
  - lib/jeanine/callbacks.rb
122
+ - lib/jeanine/cli.rb
121
123
  - lib/jeanine/core_ext.rb
122
124
  - lib/jeanine/core_ext/array.rb
123
125
  - lib/jeanine/core_ext/hash.rb
@@ -165,5 +167,5 @@ rubyforge_project:
165
167
  rubygems_version: 2.6.14.3
166
168
  signing_key:
167
169
  specification_version: 4
168
- summary: A framework.
170
+ summary: A lightning-fast, batteries-included Ruby web micro-framework.
169
171
  test_files: []