genesis_rails 0.0.3 → 0.0.4
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/README.md +41 -2
- data/lib/generators/genesis_rails/templates/service.rb +1 -1
- data/lib/genesis_rails/templates/erb/scaffold/_form.html.erb +1 -1
- data/lib/genesis_rails/templates/rails/scaffold_controller/controller.rb +2 -2
- data/lib/genesis_rails/version.rb +1 -1
- 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: 8c9a4db021003c7fea7b1660cd22d960d387c987
|
4
|
+
data.tar.gz: 5ecad4eef16b9582eec752cd0ece7d8053ded68e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d873f72af1f5c8947520d2f5c8d8f9746dcda68547d72c9a5baa713f0686a5078e3d737c01b176f1514fc1e95f4fa4bddba6fdeede335507e05bbe2847cd9e42
|
7
|
+
data.tar.gz: c83b3f2c36b9b2f7bbe0f3101ae52daa03208f5b832d5e6e27ade57702a8ea41def904127304472abf400071044cf184693d877183d9a1b12078e9c43460deed
|
data/README.md
CHANGED
@@ -1,2 +1,41 @@
|
|
1
|
-
#
|
2
|
-
|
1
|
+
# genesis\_rails
|
2
|
+
|
3
|
+
GenesisRails is a warehouse for templates and initial configurations for
|
4
|
+
brand new rails project with the minimum needed for a quick development
|
5
|
+
environment.
|
6
|
+
|
7
|
+
## Use
|
8
|
+
|
9
|
+
As this project is meant to be a set of basic generators and overrided templates
|
10
|
+
that depends on third party projects. These are the gems you will need for it:
|
11
|
+
|
12
|
+
- genesis\_rails (itself)
|
13
|
+
- rspec-rails
|
14
|
+
- factory\_girls\_rails
|
15
|
+
- responders
|
16
|
+
- simple\_form
|
17
|
+
|
18
|
+
Soon we will have a template for `rails new -m template.rb`, but for now, just
|
19
|
+
make sure you have all these gems on your Gemfile. Here is an example that
|
20
|
+
should work:
|
21
|
+
|
22
|
+
```ruby
|
23
|
+
gem 'genesis_rails'
|
24
|
+
gem 'responders'
|
25
|
+
gem 'simple_form'
|
26
|
+
|
27
|
+
group :test do
|
28
|
+
gem "rspec"
|
29
|
+
gem "rspec-rails"
|
30
|
+
gem "capybara"
|
31
|
+
gem "database_cleaner"
|
32
|
+
gem 'factory_girl_rails'
|
33
|
+
end
|
34
|
+
|
35
|
+
source 'https://rails-assets.org' do
|
36
|
+
gem 'rails-assets-bootstrap'
|
37
|
+
end
|
38
|
+
```
|
39
|
+
|
40
|
+
If you have any doubt or problem, don't be ashamed and open an issue.
|
41
|
+
|
@@ -1,5 +1,5 @@
|
|
1
1
|
<% module_namespacing do -%>
|
2
|
-
class <%= class_name.pluralize %>Service < GenesisRails::
|
2
|
+
class <%= class_name.pluralize %>Service < GenesisRails::Services::CRUD
|
3
3
|
# you can overwrite these methods if you want to do something more when you
|
4
4
|
# are dealing with the <%= class_name %> model
|
5
5
|
# def create
|
@@ -5,7 +5,7 @@
|
|
5
5
|
<div class="panel">
|
6
6
|
<div class="panel-body">
|
7
7
|
<%%= simple_form_for(@<%= singular_table_name %>) do |f| %>
|
8
|
-
<%%=
|
8
|
+
<%%= f.error_notification %>
|
9
9
|
|
10
10
|
<div class="form-inputs">
|
11
11
|
<%- attributes.each do |attribute| -%>
|
@@ -1,9 +1,9 @@
|
|
1
1
|
<% if namespaced? -%>
|
2
|
-
require_dependency "<%= namespaced_path %>/
|
2
|
+
require_dependency "<%= namespaced_path %>/application_controller"
|
3
3
|
|
4
4
|
<% end -%>
|
5
5
|
<% module_namespacing do -%>
|
6
|
-
class <%= controller_class_name %>Controller <
|
6
|
+
class <%= controller_class_name %>Controller < ApplicationController
|
7
7
|
respond_to :html
|
8
8
|
|
9
9
|
def index
|