mecha 0.6.1 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.ruby-version +1 -1
- data/README.md +24 -4
- data/TODO.md +9 -0
- data/lib/mecha/generators/app/app_builder.rb +16 -7
- data/lib/mecha/generators/app/app_generator.rb +10 -1
- data/lib/mecha/generators/app/templates/Gemfile.erb +10 -7
- data/lib/mecha/generators/app/templates/README.md.erb +13 -3
- data/lib/mecha/generators/app/templates/gitignore.erb +7 -0
- data/lib/mecha/generators/bitbucket_pipelines/bitbucket_pipelines_generator.rb +0 -1
- data/lib/mecha/generators/cpf_cnpj/cpf_cnpj_generator.rb +17 -0
- data/lib/mecha/generators/cpf_cnpj/templates/app/validators/cnpj_format_validator.rb +6 -0
- data/lib/mecha/generators/danger/danger_generator.rb +37 -0
- data/lib/mecha/generators/danger/templates/Dangerfile +68 -0
- data/lib/mecha/generators/devise/devise_generator.rb +18 -2
- data/lib/mecha/generators/guard/guard_generator.rb +3 -3
- data/lib/mecha/generators/guard/templates/Guardfile +43 -0
- data/lib/mecha/generators/heroku/heroku_generator.rb +99 -0
- data/lib/mecha/generators/heroku/templates/app.json +21 -0
- data/lib/mecha/generators/i18n/i18n_generator.rb +2 -4
- data/lib/mecha/generators/pronto/pronto_generator.rb +74 -0
- data/lib/mecha/generators/pronto/templates/flayignore +4 -0
- data/lib/mecha/generators/pronto/templates/reek +48 -0
- data/lib/mecha/generators/rubocop/templates/rubocop.yml +16 -1
- data/lib/mecha/generators/sentry/sentry_generator.rb +32 -18
- data/lib/mecha/generators/sentry/templates/_sentry.html.erb +2 -0
- data/lib/mecha/generators/sentry/templates/sentry.rb +5 -0
- data/lib/mecha/generators/simplecov/simplecov_generator.rb +34 -4
- data/lib/mecha/generators/tests/templates/spec/rails_helper.rb +18 -0
- data/lib/mecha/generators/tests/templates/spec/spec_helper.rb +27 -0
- data/lib/mecha/generators/tests/templates/spec/support/factory_bot.rb +3 -0
- data/lib/mecha/generators/tests/templates/test/test_helper.rb +10 -19
- data/lib/mecha/generators/tests/tests_generator.rb +37 -6
- data/lib/mecha/version.rb +3 -3
- data/lib/mecha.rb +30 -9
- data/mecha.gemspec +3 -6
- metadata +22 -53
- data/lib/mecha/generators/i18n/templates/config/locales/en.yml +0 -213
- data/lib/mecha/generators/i18n/templates/config/locales/pt-BR.yml +0 -221
- data/lib/mecha/generators/sentry/templates/rubocop.yml +0 -47
- data/lib/mecha/generators/simplecov/templates/simplecov +0 -10
@@ -1,213 +0,0 @@
|
|
1
|
-
---
|
2
|
-
en:
|
3
|
-
activerecord:
|
4
|
-
errors:
|
5
|
-
messages:
|
6
|
-
record_invalid: "Validation failed: %{errors}"
|
7
|
-
restrict_dependent_destroy:
|
8
|
-
has_one: "Cannot delete record because a dependent %{record} exists"
|
9
|
-
has_many: "Cannot delete record because dependent %{record} exist"
|
10
|
-
date:
|
11
|
-
abbr_day_names:
|
12
|
-
- Sun
|
13
|
-
- Mon
|
14
|
-
- Tue
|
15
|
-
- Wed
|
16
|
-
- Thu
|
17
|
-
- Fri
|
18
|
-
- Sat
|
19
|
-
abbr_month_names:
|
20
|
-
-
|
21
|
-
- Jan
|
22
|
-
- Feb
|
23
|
-
- Mar
|
24
|
-
- Apr
|
25
|
-
- May
|
26
|
-
- Jun
|
27
|
-
- Jul
|
28
|
-
- Aug
|
29
|
-
- Sep
|
30
|
-
- Oct
|
31
|
-
- Nov
|
32
|
-
- Dec
|
33
|
-
day_names:
|
34
|
-
- Sunday
|
35
|
-
- Monday
|
36
|
-
- Tuesday
|
37
|
-
- Wednesday
|
38
|
-
- Thursday
|
39
|
-
- Friday
|
40
|
-
- Saturday
|
41
|
-
formats:
|
42
|
-
default: "%Y-%m-%d"
|
43
|
-
long: "%B %d, %Y"
|
44
|
-
short: "%b %d"
|
45
|
-
month_names:
|
46
|
-
-
|
47
|
-
- January
|
48
|
-
- February
|
49
|
-
- March
|
50
|
-
- April
|
51
|
-
- May
|
52
|
-
- June
|
53
|
-
- July
|
54
|
-
- August
|
55
|
-
- September
|
56
|
-
- October
|
57
|
-
- November
|
58
|
-
- December
|
59
|
-
order:
|
60
|
-
- :year
|
61
|
-
- :month
|
62
|
-
- :day
|
63
|
-
datetime:
|
64
|
-
distance_in_words:
|
65
|
-
about_x_hours:
|
66
|
-
one: about 1 hour
|
67
|
-
other: about %{count} hours
|
68
|
-
about_x_months:
|
69
|
-
one: about 1 month
|
70
|
-
other: about %{count} months
|
71
|
-
about_x_years:
|
72
|
-
one: about 1 year
|
73
|
-
other: about %{count} years
|
74
|
-
almost_x_years:
|
75
|
-
one: almost 1 year
|
76
|
-
other: almost %{count} years
|
77
|
-
half_a_minute: half a minute
|
78
|
-
less_than_x_minutes:
|
79
|
-
one: less than a minute
|
80
|
-
other: less than %{count} minutes
|
81
|
-
less_than_x_seconds:
|
82
|
-
one: less than 1 second
|
83
|
-
other: less than %{count} seconds
|
84
|
-
over_x_years:
|
85
|
-
one: over 1 year
|
86
|
-
other: over %{count} years
|
87
|
-
x_days:
|
88
|
-
one: 1 day
|
89
|
-
other: "%{count} days"
|
90
|
-
x_minutes:
|
91
|
-
one: 1 minute
|
92
|
-
other: "%{count} minutes"
|
93
|
-
x_months:
|
94
|
-
one: 1 month
|
95
|
-
other: "%{count} months"
|
96
|
-
x_years:
|
97
|
-
one: 1 year
|
98
|
-
other: "%{count} years"
|
99
|
-
x_seconds:
|
100
|
-
one: 1 second
|
101
|
-
other: "%{count} seconds"
|
102
|
-
prompts:
|
103
|
-
day: Day
|
104
|
-
hour: Hour
|
105
|
-
minute: Minute
|
106
|
-
month: Month
|
107
|
-
second: Seconds
|
108
|
-
year: Year
|
109
|
-
errors:
|
110
|
-
format: "%{attribute} %{message}"
|
111
|
-
messages:
|
112
|
-
accepted: must be accepted
|
113
|
-
blank: can't be blank
|
114
|
-
present: must be blank
|
115
|
-
confirmation: doesn't match %{attribute}
|
116
|
-
empty: can't be empty
|
117
|
-
equal_to: must be equal to %{count}
|
118
|
-
even: must be even
|
119
|
-
exclusion: is reserved
|
120
|
-
greater_than: must be greater than %{count}
|
121
|
-
greater_than_or_equal_to: must be greater than or equal to %{count}
|
122
|
-
inclusion: is not included in the list
|
123
|
-
invalid: is invalid
|
124
|
-
less_than: must be less than %{count}
|
125
|
-
less_than_or_equal_to: must be less than or equal to %{count}
|
126
|
-
model_invalid: "Validation failed: %{errors}"
|
127
|
-
not_a_number: is not a number
|
128
|
-
not_an_integer: must be an integer
|
129
|
-
odd: must be odd
|
130
|
-
required: must exist
|
131
|
-
taken: has already been taken
|
132
|
-
too_long:
|
133
|
-
one: is too long (maximum is 1 character)
|
134
|
-
other: is too long (maximum is %{count} characters)
|
135
|
-
too_short:
|
136
|
-
one: is too short (minimum is 1 character)
|
137
|
-
other: is too short (minimum is %{count} characters)
|
138
|
-
wrong_length:
|
139
|
-
one: is the wrong length (should be 1 character)
|
140
|
-
other: is the wrong length (should be %{count} characters)
|
141
|
-
other_than: must be other than %{count}
|
142
|
-
template:
|
143
|
-
body: 'There were problems with the following fields:'
|
144
|
-
header:
|
145
|
-
one: 1 error prohibited this %{model} from being saved
|
146
|
-
other: "%{count} errors prohibited this %{model} from being saved"
|
147
|
-
helpers:
|
148
|
-
select:
|
149
|
-
prompt: Please select
|
150
|
-
submit:
|
151
|
-
create: Create %{model}
|
152
|
-
submit: Save %{model}
|
153
|
-
update: Update %{model}
|
154
|
-
number:
|
155
|
-
currency:
|
156
|
-
format:
|
157
|
-
delimiter: ","
|
158
|
-
format: "%u%n"
|
159
|
-
precision: 2
|
160
|
-
separator: "."
|
161
|
-
significant: false
|
162
|
-
strip_insignificant_zeros: false
|
163
|
-
unit: "$"
|
164
|
-
format:
|
165
|
-
delimiter: ","
|
166
|
-
precision: 3
|
167
|
-
separator: "."
|
168
|
-
significant: false
|
169
|
-
strip_insignificant_zeros: false
|
170
|
-
human:
|
171
|
-
decimal_units:
|
172
|
-
format: "%n %u"
|
173
|
-
units:
|
174
|
-
billion: Billion
|
175
|
-
million: Million
|
176
|
-
quadrillion: Quadrillion
|
177
|
-
thousand: Thousand
|
178
|
-
trillion: Trillion
|
179
|
-
unit: ''
|
180
|
-
format:
|
181
|
-
delimiter: ''
|
182
|
-
precision: 3
|
183
|
-
significant: true
|
184
|
-
strip_insignificant_zeros: true
|
185
|
-
storage_units:
|
186
|
-
format: "%n %u"
|
187
|
-
units:
|
188
|
-
byte:
|
189
|
-
one: Byte
|
190
|
-
other: Bytes
|
191
|
-
gb: GB
|
192
|
-
kb: KB
|
193
|
-
mb: MB
|
194
|
-
tb: TB
|
195
|
-
percentage:
|
196
|
-
format:
|
197
|
-
delimiter: ''
|
198
|
-
format: "%n%"
|
199
|
-
precision:
|
200
|
-
format:
|
201
|
-
delimiter: ''
|
202
|
-
support:
|
203
|
-
array:
|
204
|
-
last_word_connector: ", and "
|
205
|
-
two_words_connector: " and "
|
206
|
-
words_connector: ", "
|
207
|
-
time:
|
208
|
-
am: am
|
209
|
-
formats:
|
210
|
-
default: "%a, %d %b %Y %H:%M:%S %z"
|
211
|
-
long: "%B %d, %Y %H:%M"
|
212
|
-
short: "%d %b %H:%M"
|
213
|
-
pm: pm
|
@@ -1,221 +0,0 @@
|
|
1
|
-
---
|
2
|
-
pt-BR:
|
3
|
-
activerecord:
|
4
|
-
errors:
|
5
|
-
messages:
|
6
|
-
record_invalid: 'A validação falhou: %{errors}'
|
7
|
-
restrict_dependent_destroy:
|
8
|
-
has_one: Não é possível excluir o registro pois existe um %{record} dependente
|
9
|
-
has_many: Não é possível excluir o registro pois existem %{record} dependentes
|
10
|
-
date:
|
11
|
-
abbr_day_names:
|
12
|
-
- Dom
|
13
|
-
- Seg
|
14
|
-
- Ter
|
15
|
-
- Qua
|
16
|
-
- Qui
|
17
|
-
- Sex
|
18
|
-
- Sáb
|
19
|
-
abbr_month_names:
|
20
|
-
-
|
21
|
-
- Jan
|
22
|
-
- Fev
|
23
|
-
- Mar
|
24
|
-
- Abr
|
25
|
-
- Mai
|
26
|
-
- Jun
|
27
|
-
- Jul
|
28
|
-
- Ago
|
29
|
-
- Set
|
30
|
-
- Out
|
31
|
-
- Nov
|
32
|
-
- Dez
|
33
|
-
day_names:
|
34
|
-
- Domingo
|
35
|
-
- Segunda-feira
|
36
|
-
- Terça-feira
|
37
|
-
- Quarta-feira
|
38
|
-
- Quinta-feira
|
39
|
-
- Sexta-feira
|
40
|
-
- Sábado
|
41
|
-
formats:
|
42
|
-
default: "%d/%m/%Y"
|
43
|
-
long: "%d de %B de %Y"
|
44
|
-
short: "%d de %B"
|
45
|
-
month_names:
|
46
|
-
-
|
47
|
-
- Janeiro
|
48
|
-
- Fevereiro
|
49
|
-
- Março
|
50
|
-
- Abril
|
51
|
-
- Maio
|
52
|
-
- Junho
|
53
|
-
- Julho
|
54
|
-
- Agosto
|
55
|
-
- Setembro
|
56
|
-
- Outubro
|
57
|
-
- Novembro
|
58
|
-
- Dezembro
|
59
|
-
order:
|
60
|
-
- :day
|
61
|
-
- :month
|
62
|
-
- :year
|
63
|
-
datetime:
|
64
|
-
distance_in_words:
|
65
|
-
about_x_hours:
|
66
|
-
one: aproximadamente 1 hora
|
67
|
-
other: aproximadamente %{count} horas
|
68
|
-
about_x_months:
|
69
|
-
one: aproximadamente 1 mês
|
70
|
-
other: aproximadamente %{count} meses
|
71
|
-
about_x_years:
|
72
|
-
one: aproximadamente 1 ano
|
73
|
-
other: aproximadamente %{count} anos
|
74
|
-
almost_x_years:
|
75
|
-
one: quase 1 ano
|
76
|
-
other: quase %{count} anos
|
77
|
-
half_a_minute: meio minuto
|
78
|
-
less_than_x_minutes:
|
79
|
-
one: menos de um minuto
|
80
|
-
other: menos de %{count} minutos
|
81
|
-
less_than_x_seconds:
|
82
|
-
one: menos de 1 segundo
|
83
|
-
other: menos de %{count} segundos
|
84
|
-
over_x_years:
|
85
|
-
one: mais de 1 ano
|
86
|
-
other: mais de %{count} anos
|
87
|
-
x_days:
|
88
|
-
one: 1 dia
|
89
|
-
other: "%{count} dias"
|
90
|
-
x_minutes:
|
91
|
-
one: 1 minuto
|
92
|
-
other: "%{count} minutos"
|
93
|
-
x_months:
|
94
|
-
one: 1 mês
|
95
|
-
other: "%{count} meses"
|
96
|
-
x_years:
|
97
|
-
one: 1 ano
|
98
|
-
other: "%{count} anos"
|
99
|
-
x_seconds:
|
100
|
-
one: 1 segundo
|
101
|
-
other: "%{count} segundos"
|
102
|
-
prompts:
|
103
|
-
day: Dia
|
104
|
-
hour: Hora
|
105
|
-
minute: Minuto
|
106
|
-
month: Mês
|
107
|
-
second: Segundo
|
108
|
-
year: Ano
|
109
|
-
errors:
|
110
|
-
format: "%{attribute} %{message}"
|
111
|
-
messages:
|
112
|
-
accepted: deve ser aceito
|
113
|
-
blank: não pode ficar em branco
|
114
|
-
present: deve ficar em branco
|
115
|
-
confirmation: não é igual a %{attribute}
|
116
|
-
empty: não pode ficar vazio
|
117
|
-
equal_to: deve ser igual a %{count}
|
118
|
-
even: deve ser par
|
119
|
-
exclusion: não está disponível
|
120
|
-
greater_than: deve ser maior que %{count}
|
121
|
-
greater_than_or_equal_to: deve ser maior ou igual a %{count}
|
122
|
-
inclusion: não está incluído na lista
|
123
|
-
invalid: não é válido
|
124
|
-
less_than: deve ser menor que %{count}
|
125
|
-
less_than_or_equal_to: deve ser menor ou igual a %{count}
|
126
|
-
model_invalid: 'A validação falhou: %{errors}'
|
127
|
-
not_a_number: não é um número
|
128
|
-
not_an_integer: não é um número inteiro
|
129
|
-
odd: deve ser ímpar
|
130
|
-
required: é obrigatório(a)
|
131
|
-
taken: já está em uso
|
132
|
-
too_long:
|
133
|
-
one: 'é muito longo (máximo: 1 caracter)'
|
134
|
-
other: 'é muito longo (máximo: %{count} caracteres)'
|
135
|
-
too_short:
|
136
|
-
one: 'é muito curto (mínimo: 1 caracter)'
|
137
|
-
other: 'é muito curto (mínimo: %{count} caracteres)'
|
138
|
-
wrong_length:
|
139
|
-
one: não possui o tamanho esperado (1 caracter)
|
140
|
-
other: não possui o tamanho esperado (%{count} caracteres)
|
141
|
-
other_than: deve ser diferente de %{count}
|
142
|
-
template:
|
143
|
-
body: 'Por favor, verifique o(s) seguinte(s) campo(s):'
|
144
|
-
header:
|
145
|
-
one: 'Não foi possível gravar %{model}: 1 erro'
|
146
|
-
other: 'Não foi possível gravar %{model}: %{count} erros'
|
147
|
-
helpers:
|
148
|
-
select:
|
149
|
-
prompt: Por favor selecione
|
150
|
-
submit:
|
151
|
-
create: Criar %{model}
|
152
|
-
submit: Salvar %{model}
|
153
|
-
update: Atualizar %{model}
|
154
|
-
number:
|
155
|
-
currency:
|
156
|
-
format:
|
157
|
-
delimiter: "."
|
158
|
-
format: "%u %n"
|
159
|
-
precision: 2
|
160
|
-
separator: ","
|
161
|
-
significant: false
|
162
|
-
strip_insignificant_zeros: false
|
163
|
-
unit: R$
|
164
|
-
format:
|
165
|
-
delimiter: "."
|
166
|
-
precision: 3
|
167
|
-
separator: ","
|
168
|
-
significant: false
|
169
|
-
strip_insignificant_zeros: false
|
170
|
-
human:
|
171
|
-
decimal_units:
|
172
|
-
format: "%n %u"
|
173
|
-
units:
|
174
|
-
billion:
|
175
|
-
one: bilhão
|
176
|
-
other: bilhões
|
177
|
-
million:
|
178
|
-
one: milhão
|
179
|
-
other: milhões
|
180
|
-
quadrillion:
|
181
|
-
one: quatrilhão
|
182
|
-
other: quatrilhões
|
183
|
-
thousand: mil
|
184
|
-
trillion:
|
185
|
-
one: trilhão
|
186
|
-
other: trilhões
|
187
|
-
unit: ''
|
188
|
-
format:
|
189
|
-
delimiter: ""
|
190
|
-
precision: 3
|
191
|
-
significant: true
|
192
|
-
strip_insignificant_zeros: true
|
193
|
-
storage_units:
|
194
|
-
format: "%n %u"
|
195
|
-
units:
|
196
|
-
byte:
|
197
|
-
one: Byte
|
198
|
-
other: Bytes
|
199
|
-
gb: GB
|
200
|
-
kb: KB
|
201
|
-
mb: MB
|
202
|
-
tb: TB
|
203
|
-
percentage:
|
204
|
-
format:
|
205
|
-
delimiter: "."
|
206
|
-
format: "%n%"
|
207
|
-
precision:
|
208
|
-
format:
|
209
|
-
delimiter: "."
|
210
|
-
support:
|
211
|
-
array:
|
212
|
-
last_word_connector: " e "
|
213
|
-
two_words_connector: " e "
|
214
|
-
words_connector: ", "
|
215
|
-
time:
|
216
|
-
am: ''
|
217
|
-
formats:
|
218
|
-
default: "%a, %d de %B de %Y, %H:%M:%S %z"
|
219
|
-
long: "%d de %B de %Y, %H:%M"
|
220
|
-
short: "%d de %B, %H:%M"
|
221
|
-
pm: ''
|
@@ -1,47 +0,0 @@
|
|
1
|
-
Rails:
|
2
|
-
Enabled: true
|
3
|
-
|
4
|
-
AllCops:
|
5
|
-
Exclude:
|
6
|
-
- 'db/schema.rb'
|
7
|
-
- 'bin/**'
|
8
|
-
- 'vendor/**/*'
|
9
|
-
- 'tmp/**/*'
|
10
|
-
- 'Guardfile'
|
11
|
-
- 'config/**/*'
|
12
|
-
- 'lib/tasks/*.rake'
|
13
|
-
|
14
|
-
Documentation:
|
15
|
-
Enabled: false
|
16
|
-
|
17
|
-
Metrics/AbcSize:
|
18
|
-
Exclude:
|
19
|
-
- 'db/**/*'
|
20
|
-
|
21
|
-
Metrics/BlockLength:
|
22
|
-
Exclude:
|
23
|
-
- 'Rakefile'
|
24
|
-
- '**/*.rake'
|
25
|
-
- 'test/**/*'
|
26
|
-
|
27
|
-
Metrics/ClassLength:
|
28
|
-
Exclude:
|
29
|
-
- 'test/**/*'
|
30
|
-
|
31
|
-
Metrics/BlockLength:
|
32
|
-
Exclude:
|
33
|
-
- 'db/migrate/**'
|
34
|
-
- 'test/**/*'
|
35
|
-
|
36
|
-
Metrics/LineLength:
|
37
|
-
Max: 120
|
38
|
-
|
39
|
-
Metrics/MethodLength:
|
40
|
-
Exclude:
|
41
|
-
- 'db/migrate/**'
|
42
|
-
- 'test/**/*'
|
43
|
-
|
44
|
-
Style/ClassAndModuleChildren:
|
45
|
-
EnforcedStyle: nested
|
46
|
-
Exclude:
|
47
|
-
- 'test/test_helper.rb'
|