schienenzeppelin 0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.github/workflows/main.yml +17 -0
- data/.github/workflows/outdated.yml +20 -0
- data/.gitignore +282 -0
- data/.rspec_status +3 -0
- data/.rubocop.yml +28 -0
- data/.tool-versions +1 -0
- data/CODE_OF_CONDUCT.md +84 -0
- data/GALLERY.md +29 -0
- data/Gemfile +13 -0
- data/Gemfile.lock +184 -0
- data/LICENSE +21 -0
- data/LICENSE.txt +21 -0
- data/README.md +174 -0
- data/Rakefile +12 -0
- data/TODO.md +32 -0
- data/bin/console +15 -0
- data/bin/setup +8 -0
- data/exe/sz +25 -0
- data/images/create.png +0 -0
- data/images/error.png +0 -0
- data/images/home.png +0 -0
- data/images/index.png +0 -0
- data/images/login.png +0 -0
- data/images/mobile.png +0 -0
- data/lib/schienenzeppelin.rb +18 -0
- data/lib/schienenzeppelin/app_builder.rb +88 -0
- data/lib/schienenzeppelin/app_generator.rb +95 -0
- data/lib/schienenzeppelin/helper_base.rb +28 -0
- data/lib/schienenzeppelin/helpers/annotate.rb +11 -0
- data/lib/schienenzeppelin/helpers/capistrano.rb +35 -0
- data/lib/schienenzeppelin/helpers/continuous_integration.rb +12 -0
- data/lib/schienenzeppelin/helpers/credentials.rb +49 -0
- data/lib/schienenzeppelin/helpers/devise.rb +45 -0
- data/lib/schienenzeppelin/helpers/errors.rb +67 -0
- data/lib/schienenzeppelin/helpers/factory_bot.rb +13 -0
- data/lib/schienenzeppelin/helpers/generators.rb +26 -0
- data/lib/schienenzeppelin/helpers/high_voltage.rb +11 -0
- data/lib/schienenzeppelin/helpers/home.rb +17 -0
- data/lib/schienenzeppelin/helpers/hotwire.rb +11 -0
- data/lib/schienenzeppelin/helpers/pundit.rb +12 -0
- data/lib/schienenzeppelin/helpers/rspec.rb +13 -0
- data/lib/schienenzeppelin/helpers/rubocop.rb +11 -0
- data/lib/schienenzeppelin/helpers/scaffold.rb +11 -0
- data/lib/schienenzeppelin/helpers/services.rb +11 -0
- data/lib/schienenzeppelin/helpers/sidekiq.rb +13 -0
- data/lib/schienenzeppelin/helpers/stimulus.rb +11 -0
- data/lib/schienenzeppelin/helpers/stimulus_components.rb +29 -0
- data/lib/schienenzeppelin/helpers/tailwind.rb +18 -0
- data/lib/schienenzeppelin/version.rb +7 -0
- data/schienenzeppelin.gemspec +37 -0
- data/schienenzeppelin.jpg +0 -0
- data/script.md +104 -0
- data/templates/.dockerignore.erb +51 -0
- data/templates/.entrypoint.sh.erb +16 -0
- data/templates/.env.development.erb +3 -0
- data/templates/.foreman.erb +1 -0
- data/templates/.github/workflows/build.yml.erb +49 -0
- data/templates/.gitignore.erb +285 -0
- data/templates/.irbrc.erb +12 -0
- data/templates/.rubocop.yml.erb +37 -0
- data/templates/.tool-versions.erb +1 -0
- data/templates/Capfile.erb +24 -0
- data/templates/Dockerfile.erb +45 -0
- data/templates/Gemfile.erb +122 -0
- data/templates/Procfile.dev.erb +6 -0
- data/templates/Procfile.erb +2 -0
- data/templates/README.md.erb +43 -0
- data/templates/app/controllers/authorized_controller.rb.erb +10 -0
- data/templates/app/controllers/errors_controller.rb.erb +24 -0
- data/templates/app/javascript/images/checkmark.svg +1 -0
- data/templates/app/javascript/images/logo.svg +1 -0
- data/templates/app/javascript/stylesheets/components.scss +206 -0
- data/templates/app/policies/application_policy.rb +55 -0
- data/templates/app/services/application_service.rb +14 -0
- data/templates/app/views/devise/confirmations/new.html.erb +24 -0
- data/templates/app/views/devise/passwords/edit.html.erb +34 -0
- data/templates/app/views/devise/passwords/new.html.erb +23 -0
- data/templates/app/views/devise/registrations/edit.html.erb +62 -0
- data/templates/app/views/devise/registrations/new.html.erb +45 -0
- data/templates/app/views/devise/sessions/new.html.erb +33 -0
- data/templates/app/views/devise/shared/_error_messages.html.erb +15 -0
- data/templates/app/views/devise/shared/_form_wrap.html.erb +5 -0
- data/templates/app/views/devise/shared/_links.html.erb +25 -0
- data/templates/app/views/devise/unlocks/new.html.erb +22 -0
- data/templates/app/views/errors/internal_error.html.erb +14 -0
- data/templates/app/views/errors/not_found.html.erb +14 -0
- data/templates/app/views/errors/unacceptable.html.erb +14 -0
- data/templates/app/views/layouts/application.html.erb.tt +30 -0
- data/templates/app/views/pages/home.html.erb.tt +20 -0
- data/templates/app/views/shared/_flashes.html.erb.tt +12 -0
- data/templates/app/views/shared/_footer.html.erb.tt +21 -0
- data/templates/app/views/shared/_navbar.html.erb.tt +40 -0
- data/templates/bin/setup.erb +146 -0
- data/templates/config/credentials.yml.erb +7 -0
- data/templates/config/initializers/high_voltage.rb +6 -0
- data/templates/config/initializers/lograge.rb +5 -0
- data/templates/config/initializers/sidekiq.rb +10 -0
- data/templates/config/postgresql.yml.erb +23 -0
- data/templates/docker-compose.yml.erb +21 -0
- data/templates/lib/capistrano/tasks/seeds.rake +12 -0
- data/templates/lib/capistrano/tasks/sidekiq.rake +36 -0
- data/templates/lib/generators/rails/navigation/USAGE +6 -0
- data/templates/lib/generators/rails/navigation/navigation_generator.rb +15 -0
- data/templates/lib/generators/rails/scaffold_controller_generator.rb +12 -0
- data/templates/lib/tasks/auto_annotate_models.rake +58 -0
- data/templates/lib/templates/erb/scaffold/_form.html.erb +39 -0
- data/templates/lib/templates/erb/scaffold/edit.html.erb +7 -0
- data/templates/lib/templates/erb/scaffold/index.html.erb +34 -0
- data/templates/lib/templates/erb/scaffold/new.html.erb +7 -0
- data/templates/lib/templates/erb/scaffold/show.html.erb +18 -0
- data/templates/public/500.html.erb +26 -0
- data/templates/spec/rails_helper.rb +26 -0
- data/templates/spec/spec_helper.rb +61 -0
- data/templates/spec/support/factory_bot.rb +5 -0
- data/templates/spec/support/shoulda_matchers.rb +8 -0
- metadata +179 -0
data/GALLERY.md
ADDED
@@ -0,0 +1,29 @@
|
|
1
|
+
# Gallery
|
2
|
+
|
3
|
+
Schienenzeppelin comes with a nice and unobstrusive UI to get you started quickly.
|
4
|
+
|
5
|
+
## Home
|
6
|
+
|
7
|
+
TailwindCSS and responsive views already done. Minimalism first, so these things stay out of your way.
|
8
|
+
|
9
|
+
![home](./images/home.png)
|
10
|
+
![home_mobile](./images/mobile.png)
|
11
|
+
|
12
|
+
## Devise
|
13
|
+
|
14
|
+
All devise forms (login, sign up, profile...) feature the same simple design.
|
15
|
+
|
16
|
+
![devise](./images/login.png)
|
17
|
+
|
18
|
+
## Scaffold
|
19
|
+
|
20
|
+
Adding new views via `rails scaffold` tends to result in a ton of work to get those to look nice. Not anymore!
|
21
|
+
|
22
|
+
![scaffold](images/index.png)
|
23
|
+
![create](images/create.png)
|
24
|
+
|
25
|
+
## Error Pages
|
26
|
+
|
27
|
+
Even if things go wrong, they should look nice, right?
|
28
|
+
|
29
|
+
![error](images/error.png)
|
data/Gemfile
ADDED
@@ -0,0 +1,13 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
source 'https://rubygems.org'
|
4
|
+
|
5
|
+
# Specify your gem's dependencies in schienenzeppelin.gemspec
|
6
|
+
gemspec
|
7
|
+
|
8
|
+
gem 'rake', '~> 13.0'
|
9
|
+
|
10
|
+
gem 'rspec', '~> 3.10'
|
11
|
+
|
12
|
+
gem 'rubocop', '~> 1.9'
|
13
|
+
gem 'rubocop-rspec', '~> 1.40'
|
data/Gemfile.lock
ADDED
@@ -0,0 +1,184 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
schienenzeppelin (0.1)
|
5
|
+
rails (~> 6.1.2)
|
6
|
+
|
7
|
+
GEM
|
8
|
+
remote: https://rubygems.org/
|
9
|
+
specs:
|
10
|
+
actioncable (6.1.2.1)
|
11
|
+
actionpack (= 6.1.2.1)
|
12
|
+
activesupport (= 6.1.2.1)
|
13
|
+
nio4r (~> 2.0)
|
14
|
+
websocket-driver (>= 0.6.1)
|
15
|
+
actionmailbox (6.1.2.1)
|
16
|
+
actionpack (= 6.1.2.1)
|
17
|
+
activejob (= 6.1.2.1)
|
18
|
+
activerecord (= 6.1.2.1)
|
19
|
+
activestorage (= 6.1.2.1)
|
20
|
+
activesupport (= 6.1.2.1)
|
21
|
+
mail (>= 2.7.1)
|
22
|
+
actionmailer (6.1.2.1)
|
23
|
+
actionpack (= 6.1.2.1)
|
24
|
+
actionview (= 6.1.2.1)
|
25
|
+
activejob (= 6.1.2.1)
|
26
|
+
activesupport (= 6.1.2.1)
|
27
|
+
mail (~> 2.5, >= 2.5.4)
|
28
|
+
rails-dom-testing (~> 2.0)
|
29
|
+
actionpack (6.1.2.1)
|
30
|
+
actionview (= 6.1.2.1)
|
31
|
+
activesupport (= 6.1.2.1)
|
32
|
+
rack (~> 2.0, >= 2.0.9)
|
33
|
+
rack-test (>= 0.6.3)
|
34
|
+
rails-dom-testing (~> 2.0)
|
35
|
+
rails-html-sanitizer (~> 1.0, >= 1.2.0)
|
36
|
+
actiontext (6.1.2.1)
|
37
|
+
actionpack (= 6.1.2.1)
|
38
|
+
activerecord (= 6.1.2.1)
|
39
|
+
activestorage (= 6.1.2.1)
|
40
|
+
activesupport (= 6.1.2.1)
|
41
|
+
nokogiri (>= 1.8.5)
|
42
|
+
actionview (6.1.2.1)
|
43
|
+
activesupport (= 6.1.2.1)
|
44
|
+
builder (~> 3.1)
|
45
|
+
erubi (~> 1.4)
|
46
|
+
rails-dom-testing (~> 2.0)
|
47
|
+
rails-html-sanitizer (~> 1.1, >= 1.2.0)
|
48
|
+
activejob (6.1.2.1)
|
49
|
+
activesupport (= 6.1.2.1)
|
50
|
+
globalid (>= 0.3.6)
|
51
|
+
activemodel (6.1.2.1)
|
52
|
+
activesupport (= 6.1.2.1)
|
53
|
+
activerecord (6.1.2.1)
|
54
|
+
activemodel (= 6.1.2.1)
|
55
|
+
activesupport (= 6.1.2.1)
|
56
|
+
activestorage (6.1.2.1)
|
57
|
+
actionpack (= 6.1.2.1)
|
58
|
+
activejob (= 6.1.2.1)
|
59
|
+
activerecord (= 6.1.2.1)
|
60
|
+
activesupport (= 6.1.2.1)
|
61
|
+
marcel (~> 0.3.1)
|
62
|
+
mimemagic (~> 0.3.2)
|
63
|
+
activesupport (6.1.2.1)
|
64
|
+
concurrent-ruby (~> 1.0, >= 1.0.2)
|
65
|
+
i18n (>= 1.6, < 2)
|
66
|
+
minitest (>= 5.1)
|
67
|
+
tzinfo (~> 2.0)
|
68
|
+
zeitwerk (~> 2.3)
|
69
|
+
ast (2.4.2)
|
70
|
+
builder (3.2.4)
|
71
|
+
concurrent-ruby (1.1.8)
|
72
|
+
crass (1.0.6)
|
73
|
+
diff-lcs (1.4.4)
|
74
|
+
erubi (1.10.0)
|
75
|
+
globalid (0.4.2)
|
76
|
+
activesupport (>= 4.2.0)
|
77
|
+
i18n (1.8.9)
|
78
|
+
concurrent-ruby (~> 1.0)
|
79
|
+
loofah (2.9.0)
|
80
|
+
crass (~> 1.0.2)
|
81
|
+
nokogiri (>= 1.5.9)
|
82
|
+
mail (2.7.1)
|
83
|
+
mini_mime (>= 0.1.1)
|
84
|
+
marcel (0.3.3)
|
85
|
+
mimemagic (~> 0.3.2)
|
86
|
+
method_source (1.0.0)
|
87
|
+
mimemagic (0.3.5)
|
88
|
+
mini_mime (1.0.2)
|
89
|
+
minitest (5.14.3)
|
90
|
+
nio4r (2.5.5)
|
91
|
+
nokogiri (1.11.1-x86_64-linux)
|
92
|
+
racc (~> 1.4)
|
93
|
+
parallel (1.20.1)
|
94
|
+
parser (3.0.0.0)
|
95
|
+
ast (~> 2.4.1)
|
96
|
+
racc (1.5.2)
|
97
|
+
rack (2.2.3)
|
98
|
+
rack-test (1.1.0)
|
99
|
+
rack (>= 1.0, < 3)
|
100
|
+
rails (6.1.2.1)
|
101
|
+
actioncable (= 6.1.2.1)
|
102
|
+
actionmailbox (= 6.1.2.1)
|
103
|
+
actionmailer (= 6.1.2.1)
|
104
|
+
actionpack (= 6.1.2.1)
|
105
|
+
actiontext (= 6.1.2.1)
|
106
|
+
actionview (= 6.1.2.1)
|
107
|
+
activejob (= 6.1.2.1)
|
108
|
+
activemodel (= 6.1.2.1)
|
109
|
+
activerecord (= 6.1.2.1)
|
110
|
+
activestorage (= 6.1.2.1)
|
111
|
+
activesupport (= 6.1.2.1)
|
112
|
+
bundler (>= 1.15.0)
|
113
|
+
railties (= 6.1.2.1)
|
114
|
+
sprockets-rails (>= 2.0.0)
|
115
|
+
rails-dom-testing (2.0.3)
|
116
|
+
activesupport (>= 4.2.0)
|
117
|
+
nokogiri (>= 1.6)
|
118
|
+
rails-html-sanitizer (1.3.0)
|
119
|
+
loofah (~> 2.3)
|
120
|
+
railties (6.1.2.1)
|
121
|
+
actionpack (= 6.1.2.1)
|
122
|
+
activesupport (= 6.1.2.1)
|
123
|
+
method_source
|
124
|
+
rake (>= 0.8.7)
|
125
|
+
thor (~> 1.0)
|
126
|
+
rainbow (3.0.0)
|
127
|
+
rake (13.0.3)
|
128
|
+
regexp_parser (2.0.3)
|
129
|
+
rexml (3.2.4)
|
130
|
+
rspec (3.10.0)
|
131
|
+
rspec-core (~> 3.10.0)
|
132
|
+
rspec-expectations (~> 3.10.0)
|
133
|
+
rspec-mocks (~> 3.10.0)
|
134
|
+
rspec-core (3.10.1)
|
135
|
+
rspec-support (~> 3.10.0)
|
136
|
+
rspec-expectations (3.10.1)
|
137
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
138
|
+
rspec-support (~> 3.10.0)
|
139
|
+
rspec-mocks (3.10.1)
|
140
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
141
|
+
rspec-support (~> 3.10.0)
|
142
|
+
rspec-support (3.10.1)
|
143
|
+
rubocop (1.9.1)
|
144
|
+
parallel (~> 1.10)
|
145
|
+
parser (>= 3.0.0.0)
|
146
|
+
rainbow (>= 2.2.2, < 4.0)
|
147
|
+
regexp_parser (>= 1.8, < 3.0)
|
148
|
+
rexml
|
149
|
+
rubocop-ast (>= 1.2.0, < 2.0)
|
150
|
+
ruby-progressbar (~> 1.7)
|
151
|
+
unicode-display_width (>= 1.4.0, < 3.0)
|
152
|
+
rubocop-ast (1.4.1)
|
153
|
+
parser (>= 2.7.1.5)
|
154
|
+
rubocop-rspec (1.42.0)
|
155
|
+
rubocop (>= 0.87.0)
|
156
|
+
ruby-progressbar (1.11.0)
|
157
|
+
sprockets (4.0.2)
|
158
|
+
concurrent-ruby (~> 1.0)
|
159
|
+
rack (> 1, < 3)
|
160
|
+
sprockets-rails (3.2.2)
|
161
|
+
actionpack (>= 4.0)
|
162
|
+
activesupport (>= 4.0)
|
163
|
+
sprockets (>= 3.0.0)
|
164
|
+
thor (1.1.0)
|
165
|
+
tzinfo (2.0.4)
|
166
|
+
concurrent-ruby (~> 1.0)
|
167
|
+
unicode-display_width (2.0.0)
|
168
|
+
websocket-driver (0.7.3)
|
169
|
+
websocket-extensions (>= 0.1.0)
|
170
|
+
websocket-extensions (0.1.5)
|
171
|
+
zeitwerk (2.4.2)
|
172
|
+
|
173
|
+
PLATFORMS
|
174
|
+
x86_64-linux
|
175
|
+
|
176
|
+
DEPENDENCIES
|
177
|
+
rake (~> 13.0)
|
178
|
+
rspec (~> 3.10)
|
179
|
+
rubocop (~> 1.9)
|
180
|
+
rubocop-rspec (~> 1.40)
|
181
|
+
schienenzeppelin!
|
182
|
+
|
183
|
+
BUNDLED WITH
|
184
|
+
2.2.7
|
data/LICENSE
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Copyright (c) 2021 Hans-Jörg Schnedlitz
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
13
|
+
copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
21
|
+
SOFTWARE.
|
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2021 hschne
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,174 @@
|
|
1
|
+
<h1 align="center">Schienenzeppelin</h1>
|
2
|
+
|
3
|
+
<p align="center">
|
4
|
+
<img src="https://github.com/hschne/schienenzeppelin/workflows/Ruby/badge.svg"/>
|
5
|
+
<img src="https://badge.fury.io/rb/pundit.svg"/>
|
6
|
+
</p>
|
7
|
+
|
8
|
+
The Ruby on Rails app generator to get you started quickly. Includes TailwindCSS,
|
9
|
+
Devise, Capistrano and much more. Check out these [screenshots](GALLERY.md) and [What's in the Box](#whats-in-the-box) to find out more.
|
10
|
+
|
11
|
+
![zeppelin](./schienenzeppelin.jpg)
|
12
|
+
|
13
|
+
## Getting Started
|
14
|
+
|
15
|
+
Install the Schienenzeppelin gem:
|
16
|
+
|
17
|
+
```
|
18
|
+
gem install schienenzeppelin
|
19
|
+
```
|
20
|
+
|
21
|
+
Make sure you have [Ruby](https://www.ruby-lang.org/en/) and [ Yarn ](https://yarnpkg.com/) installed. Then run:
|
22
|
+
|
23
|
+
```
|
24
|
+
sz <app-name>
|
25
|
+
```
|
26
|
+
|
27
|
+
## What's in the Box?
|
28
|
+
|
29
|
+
Loads of things!
|
30
|
+
|
31
|
+
Schienenzeppelin provides you with a ready-to-go Rails app that you can take to production in a matter of minutes. It comes pre-configured with several gems and utilities that - while kind of standard - are not included in the default Rails app generator. Some highlights include:
|
32
|
+
|
33
|
+
- Fully responsive pages using [TailwindCSS](https://tailwindcss.com/) and [High Voltage](https://github.com/thoughtbot/high_voltage) out of the box. And custom scaffolds to boot! :sparkles:
|
34
|
+
- Authentication & Authorization comes standard. Starting your app with Schienenzeppelin means [Devise](https://github.com/heartcombo/devise) is already set up :+1:
|
35
|
+
- Dockerized everything. That includes a Dockerfile to get you started with containerizing your app, and a [docker-compose](https://docs.docker.com/compose/)-powered development environment :whale:
|
36
|
+
- Deploying your app is easy as pie. All the basic [Capistrano](https://capistranorb.com/) configuration is done already, just put in your server location and you are off to the races :rocket:
|
37
|
+
|
38
|
+
### Frontend
|
39
|
+
|
40
|
+
The nice thing about Schienenzeppelin is that it sets you up with basic pages that don't look like garbage - allowing you to focus on other things than design.
|
41
|
+
|
42
|
+
Curious what that looks like? Check out these [screenshots](GALLERY.md).
|
43
|
+
|
44
|
+
#### Tailwind CSS
|
45
|
+
|
46
|
+
Schienenzeppelin comes pre-configured with [tailwindcss-rails](https://github.com/rails/tailwindcss-rails). We provide several UI components as a starting point in `app/javascript/stylesheets/components.scss` - easy to adapt, and easy to add your own.
|
47
|
+
|
48
|
+
#### Custom Views
|
49
|
+
|
50
|
+
[High Voltage](https://github.com/thoughtbot/high_voltage) offers an easy way to add static pages - no controllers needed. Out of the box, Schienenzeppelin provides a mobile-friendly home page and an improved application layout.
|
51
|
+
|
52
|
+
#### Custom Scaffold
|
53
|
+
|
54
|
+
Schienenzeppelin adds a bunch of scaffolds that you adapt to suit your own needs in `lib/scaffolds`. These scaffolds take advantage of Tailwind to match the look of the rest of your application.
|
55
|
+
|
56
|
+
#### Turbo
|
57
|
+
|
58
|
+
[Hotwire](https://hotwire.dev/) is the new hotness. Starting with Schienenzeppelin means that Hotwire and its components such as [Stimulus](https://github.com/hotwired/stimulus) are already added to your application.
|
59
|
+
|
60
|
+
Schienenzeppelin also takes advantage of [Tailwind-Stimulus-Components](https://github.com/excid3/tailwindcss-stimulus-components) to provide interactive componenets (Dropdowns, Alerts...) out of the box.
|
61
|
+
|
62
|
+
### Backend
|
63
|
+
|
64
|
+
Modern web apps need tons of functionality out of the box. Authentication, Authorization, APIs and much more. Schienenzeppelin comes with some basics to get you started quickly.
|
65
|
+
|
66
|
+
#### Authentication
|
67
|
+
|
68
|
+
Devise is already configured if you start your application with Schienenzeppelin. For a smooth first start, `db/seeds.rb` create an admin user, and your navigation bar already contains links where users can sign in or sign up.
|
69
|
+
|
70
|
+
#### Authorization
|
71
|
+
|
72
|
+
[Pundit](https://github.com/varvet/pundit) provides a simple way to encapsulate authorization logic in your application. You can add new policies to the `app/policies` folder. To generate a new policy run `rails generate pundit:policy`.
|
73
|
+
|
74
|
+
#### Background Jobs
|
75
|
+
|
76
|
+
Schienenzeppelin per default foregoes ActiveJob in favor of [Sidekiq](https://github.com/mperham/sidekiq).
|
77
|
+
|
78
|
+
#### OJ
|
79
|
+
|
80
|
+
To serialize and deserialize to and from Json [OJ](https://github.com/ohler55/oj) is pretty much standard. Schienenzeppelin already comes pre-configured with it.
|
81
|
+
|
82
|
+
#### JB
|
83
|
+
|
84
|
+
For rendering JSON views we use [JB](https://github.com/amatsuda/jb) instead of [JBuilder](https://github.com/rails/jbuilder), as it is both faster and simpler to use.
|
85
|
+
|
86
|
+
#### Service Objects
|
87
|
+
|
88
|
+
[Service Objects](https://www.toptal.com/ruby-on-rails/rails-service-objects-tutorial) are a simple, straight-forward way to encapsulate your business logic and keep your controllers and models nice and slim.
|
89
|
+
|
90
|
+
Schienenzeppelin provides a basic service object base class you can inherit from to add your own service objects in `app/services`.
|
91
|
+
|
92
|
+
### Development
|
93
|
+
|
94
|
+
#### Setup Script
|
95
|
+
|
96
|
+
A setup script that allows for easy setup of the application on a new machine is provided. It is automatically tailored to your specific
|
97
|
+
app configuration.
|
98
|
+
|
99
|
+
#### Start Script
|
100
|
+
|
101
|
+
Once you have set up everything your application can be started with a single command-line call - using Foreman. All necessary procfiles are generated.
|
102
|
+
|
103
|
+
#### Better Rails Console
|
104
|
+
|
105
|
+
Schienenzeppelin comes with a custom `.irbrc` that adds history and syntax completion. [Factory Bot](#factory_bot) methods will also be available in the console.
|
106
|
+
|
107
|
+
#### Annotate
|
108
|
+
|
109
|
+
[Annotate](https://github.com/ctran/annotate_models) adds comments to your models to show the current table schema. Automatically run during each migration.
|
110
|
+
|
111
|
+
#### Database
|
112
|
+
|
113
|
+
PostgreSQL is already configured if you start your app - in such a way that it plays nicely with other utilities such as `dotenv` and `docker-compose` too!
|
114
|
+
|
115
|
+
#### Dotenv
|
116
|
+
|
117
|
+
[Dotenv](https://github.com/bkeepers/dotenv) is a nifty gem that makes environment variables easier to manage.
|
118
|
+
|
119
|
+
#### Docker
|
120
|
+
|
121
|
+
Docker is incredibly helpful when developing and deploying your application. Schienenzeppelin provides a `docker-compose` file
|
122
|
+
as well as an optimized `Dockerfile` (with complementary `.dockerignore`) to get you started.
|
123
|
+
|
124
|
+
#### Version Manager Support
|
125
|
+
|
126
|
+
We added support for the [asdf version manager](https://asdf-vm.com/#/). A `.tool-versions` file is automatically included in your app.
|
127
|
+
|
128
|
+
#### Improved Gitignore
|
129
|
+
|
130
|
+
Schienenzeppelin provides a custom `.gitignore` that is tailored to your app.
|
131
|
+
|
132
|
+
#### Rubocop
|
133
|
+
|
134
|
+
Creating your app with Schienenzeppelin will automatically add Rubocop and a minimal set of Rubocop rules for both your production and test code.
|
135
|
+
|
136
|
+
#### Improved Credentials
|
137
|
+
|
138
|
+
While Rails secrets are usually prepared for development, Schienezeppelin sets up everything for production as well.
|
139
|
+
|
140
|
+
#### Rspec
|
141
|
+
|
142
|
+
[Rspec](https://github.com/rspec/rspec) and its helpers [rspec-mocks](https://github.com/rspec/rspec-mocks) and [shoulda](https://github.com/thoughtbot/shoulda) come standard.
|
143
|
+
|
144
|
+
#### Factorybot
|
145
|
+
|
146
|
+
[Factorybot](https://github.com/thoughtbot/factory_bot) provides an easy way to create test data.
|
147
|
+
|
148
|
+
### Deployment & CI
|
149
|
+
|
150
|
+
#### Github Actions
|
151
|
+
|
152
|
+
Schienenzeppelin already comes with a workflow file that should cover your basic need. A good starting point for further customization.
|
153
|
+
|
154
|
+
#### Capistrano
|
155
|
+
|
156
|
+
Capistrano is already set up. Deploy to a server of your choice with minimal effort.
|
157
|
+
|
158
|
+
## FAQ
|
159
|
+
|
160
|
+
#### Why another template generator?
|
161
|
+
|
162
|
+
I wanted something that fits the way I like to write my Rails app. There are many application templates, but this one is mine.
|
163
|
+
|
164
|
+
#### What's with the German gibberish name?
|
165
|
+
|
166
|
+
I'm so glad you asked. The [Schienenzeppelin](https://en.wikipedia.org/wiki/Schienenzeppelin) was an experimental railcar that was briefly in operation during the 1930s. It was pretty fast, and it ran on Rails. Get it? :zany_face:
|
167
|
+
|
168
|
+
#### Credits
|
169
|
+
|
170
|
+
This idea is nothing new, and there are tons of other projects I took inspiration from.
|
171
|
+
|
172
|
+
Special shout out to Chris Oliver, whose [Jumpstart Pro](https://jumpstartrails.com/) is crazy good. You should get it.
|
173
|
+
|
174
|
+
[Suspenders](https://github.com/thoughtbot/suspenders) was where I first came across the idea to try my hand at custom template generators.
|