ruby_storm 0.0.8 → 0.0.9

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: c06018e1d6a54f78c31e57ed3a5918055e4ff199
4
- data.tar.gz: b311afdb1736da058089f5db3707fd5992088d6b
3
+ metadata.gz: 5c7e6151c5ed4d97e2d7dc22b9b2f2d2878c91d0
4
+ data.tar.gz: 350cf19b627ea46f0356b3f75add71d455ae0552
5
5
  SHA512:
6
- metadata.gz: c2565e54e23409298295b49b4f67b714319e6b7784bd08ec3e51ae214a4fcbab3d754b6c72bad5c44afdfb71c9a26f29d6c9341387638d29534102568e841210
7
- data.tar.gz: f00c5ac8a06e5b19f64cc92f473ec39665766c2b6729cba0c289305e95c4031899dca3953251add30c68ce14debcb69a4deb5f3fb7b5efb0e459611c1b85433e
6
+ metadata.gz: 483ccedac53f7f5b6648d3c3e1b404f4dc63c38ecd29ac876247a14b77412d8d68056496cc290ea01b4c6dc36162d4f36005c25a5b93eceaa7cbe703b016b65f
7
+ data.tar.gz: 8c4ead33b151c54b1652e70239cf59cc3b4731adc7edb3fc8149e577ba45ac19976189d0ef5be8c1483611011868978ba7710ff9c912f82f3b246b4f00ca0bad
data/README.md CHANGED
@@ -1 +1,84 @@
1
- Ruby Storm
1
+ [![Ruby Storm](https://img.shields.io/badge/Ruby Storm-Ruby%20Stand%20alone%20object%20relational%20mapper-blue.svg)](Ruby Storm)
2
+ [![Gem Version](https://badge.fury.io/rb/ruby_storm.svg)](http://badge.fury.io/rb/ruby_storm)
3
+ [![Downloads](https://img.shields.io/gem/dt/ruby_storm/stable.svg)](https://img.shields.io/gem/dt/ruby_storm)
4
+ [![Inline docs](http://inch-ci.org/github/wouterken/ruby_storm.svg?branch=master)](http://inch-ci.org/github/wouterken/ruby_storm)
5
+
6
+ ### Ruby Storm
7
+
8
+ Ruby Storm is a light-weight **st**and-alone ***o***bject **r**elational **m**apper wrapping the functionality of the Rails active record library into a light-weight tool.
9
+
10
+ You can use ruby storm to generate minimal applications with full support for active-record, migrations, basic model generation and an interactive console.
11
+
12
+ #### Installation
13
+
14
+ ```ruby
15
+ gem install ruby_storm
16
+ ```
17
+
18
+ #### Usage
19
+
20
+ * Generating a new project
21
+
22
+ ````
23
+ storm init my_new_project
24
+ cd my_new_project
25
+ ````
26
+ * Generating a new model (and migration in a project)
27
+
28
+ ````
29
+ storm db:generate MyModel first_name:string last_name:string order:integer happy:boolean
30
+ ````
31
+ * Performing migrations
32
+
33
+ ```
34
+ storm db:migrate
35
+ ```
36
+
37
+ * Rollbacks
38
+
39
+ ```
40
+ storm db:rollback
41
+ STEP=5 storm db:rollback
42
+ ```
43
+ * Version
44
+
45
+ ```
46
+ storm db:version
47
+ ```
48
+
49
+ * Update existing models
50
+
51
+ ```
52
+ storm db:modify MyModel
53
+ ```
54
+
55
+ ### Storm console
56
+ The storm console can be started from the project root directory and will auto-load all of your storm models.
57
+
58
+ ```
59
+ storm console
60
+ ```
61
+
62
+ ### Storm application
63
+ You storm app can function as a traditional c-style application and has a 'main' entry point in the generated application file.
64
+ You can start your storm app by executing the following from the project directory.
65
+
66
+ ```
67
+ storm start
68
+ ```
69
+
70
+ ### Tasks
71
+ You can add additional tasks to your storm application similar to Rake tasks.
72
+ In the application file add a class function with the name of the task you wish to add. You can then execute that task from the command line with an optional number of arguments.
73
+
74
+ ```ruby
75
+ ## In main app file.
76
+ def self.my_task(args)
77
+ print args
78
+ end
79
+
80
+ ## From command line
81
+ storm app my_task arg1 arg2
82
+
83
+ # Outputs => ["arg1", "arg2"]
84
+ ```
@@ -25,6 +25,7 @@ module Storm
25
25
  begin
26
26
  require 'pry'
27
27
  Pry.color = true
28
+ Pry.config.print = proc { |output, value| output.puts "=> #{value.ai}" }
28
29
  load Gem.bin_path('pry', 'pry')
29
30
  rescue Exception => e
30
31
  if @@reload
@@ -1,7 +1,7 @@
1
1
  module Storm
2
2
  class Version
3
3
  def self.to_s(*args)
4
- "0.0.8"
4
+ "0.0.9"
5
5
  end
6
6
 
7
7
  def self.start(*args)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby_storm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Wouter Coppieters