aetherg 0.1.8 → 0.2.0
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/VERSION +1 -1
- data/lib/aetherg/aetherg.rb +4 -1
- data/lib/templates/Gemfile +2 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 43d1d38f5e7047306798c0e945255a6d09331f4a
|
4
|
+
data.tar.gz: d0f731f49f6ea651b14d87c5c88f450e947a060b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4f6ba107c99787f5ddac552dfad3a4ad99a24982f46014f123a3feaeb71523fc0e3faaf30dedb1c5936902b387a5a8b346d86b65c049a0703690cd462fffaa63
|
7
|
+
data.tar.gz: 7c4fc91a5925835edcd375ef32d03bfb8ab5bd5cf0a81239e11c011537c69add5983a6ae05e1d0428c09a5d17dd08a530860dda016dff63e1c7baeeeb6d4b41d
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.2.0
|
data/lib/aetherg/aetherg.rb
CHANGED
@@ -2,7 +2,7 @@ module Aetherg
|
|
2
2
|
class Generator < Thor::Group
|
3
3
|
include Thor::Actions
|
4
4
|
|
5
|
-
desc "Create a new sinatra application with
|
5
|
+
desc "Create a new sinatra application with aetherg"
|
6
6
|
argument :name, :type => :string, :desc => "What's the name of your application"
|
7
7
|
class_option :database, :aliases => "-d", :default => "mysql", :desc => "The type of database to use, sqlite, mysql, postgresql supported"
|
8
8
|
class_option :no_database, :type => :boolean, :desc => "Exclude all database configuration files"
|
@@ -55,10 +55,12 @@ module Aetherg
|
|
55
55
|
#
|
56
56
|
def create_db_config
|
57
57
|
template("config/database.yml", File.join(@app_path, "config/database.example.yml")) unless @no_database
|
58
|
+
template("config/database.yml", File.join(@app_path, "config/database.yml")) unless @no_database
|
58
59
|
end
|
59
60
|
|
60
61
|
def create_settings_config
|
61
62
|
copy_file "config/settings.yml", File.join(@app_path, "config/settings.example.yml")
|
63
|
+
copy_file "config/settings.yml", File.join(@app_path, "config/settings.yml")
|
62
64
|
end
|
63
65
|
|
64
66
|
def create_gitignore
|
@@ -90,5 +92,6 @@ module Aetherg
|
|
90
92
|
create_file File.join(@app_path, "db", "migrate", ".keep")
|
91
93
|
create_file File.join(@app_path, "public", ".keep")
|
92
94
|
end
|
95
|
+
|
93
96
|
end
|
94
97
|
end
|
data/lib/templates/Gemfile
CHANGED
@@ -4,7 +4,7 @@ source "http://ruby.taobao.org"
|
|
4
4
|
gem 'sinatra', '~> 1.4.6', require: false
|
5
5
|
gem 'rake'
|
6
6
|
<%- unless @no_database -%>
|
7
|
-
gem 'activerecord'
|
7
|
+
gem 'activerecord'
|
8
8
|
<%- if @database == 'postgresql' || @database == 'pg' -%>
|
9
9
|
gem 'pg'
|
10
10
|
<%- elsif @database == 'sqlite' -%>
|
@@ -13,7 +13,7 @@ gem 'sqlite3'
|
|
13
13
|
gem 'mongoid'
|
14
14
|
<%- else -%>
|
15
15
|
# default database: mysql
|
16
|
-
gem 'mysql2'
|
16
|
+
gem 'mysql2', '~> 0.3.20'
|
17
17
|
<%- end -%>
|
18
18
|
<%- if @redis -%>
|
19
19
|
gem 'redis'
|