jinda 0.7.7.3 → 0.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +40 -37
- data/app/assets/config/manifest.js +4 -1
- data/lib/generators/jinda/config_generator.rb +1 -1
- data/lib/generators/jinda/install_generator.rb +3 -4
- data/lib/generators/jinda/templates/app/assets/config/manifest.js +4 -0
- data/lib/generators/jinda/templates/config/mongoid.yml +3 -3
- data/lib/generators/jinda/templates/config/mongoid.yml-docker +3 -3
- data/lib/generators/jinda/templates/config/mongoid.yml-localhost +3 -3
- data/lib/generators/jinda/templates/spec/features/userlogins_spec.rb +1 -1
- data/lib/jinda/version.rb +1 -1
- data/test/dummy/Gemfile +6 -5
- data/test/dummy/Gemfile.lock +196 -181
- data/test/dummy/app/assets/config/manifest.js +4 -0
- data/test/dummy/config/credentials.yml.enc +1 -1
- data/test/dummy/config/environments/test.rb +1 -1
- data/test/dummy/config/initializers/content_security_policy.rb +5 -4
- data/test/dummy/config/initializers/filter_parameter_logging.rb +1 -3
- data/test/dummy/config/mongoid.yml-docker +3 -3
- data/test/dummy/config/mongoid.yml-localhost +3 -3
- data/test/dummy/docker-compose.yml +0 -2
- data/test/dummy/log/development.log +2 -699
- data/test/dummy/spec/features/userlogins_spec.rb +1 -1
- data/test/dummy/tmp/development_secret.txt +1 -1
- data/test/integration/config_generator_test.rb +28 -0
- metadata +3 -3
- data/test/Gemfile +0 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 967e167ae196e69b249b11576dafa1801b2a4cedee8441ec3c9d20ad3762cb20
|
4
|
+
data.tar.gz: bd9bbdfd476a063b4648cc0a746dbd5e21ed26329671ec83a338115a1153d6b4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bb5e145f1930bee99eebdea5b4e664d8726e89a74d78937951f6591aa33f38d50efcf5c9b4c5f3e2bc85039f57d644aa3f91febe29b5a6fbe4dcf3ff5284fe1f
|
7
|
+
data.tar.gz: 11a37c1e814d64f34b010ea3dbdef2b98149c423a8799d2a4a3f51794dad065a1f0d361e2aa05390e31f12d0e6e40aa340455b4d3ac72ab78b694f510f78c05b
|
data/README.md
CHANGED
@@ -37,8 +37,8 @@ Jinda is a tools for Ruby on Rails developer. (Required: basic Ruby on Rails )
|
|
37
37
|
|
38
38
|
These versions works for sure but others may do.
|
39
39
|
|
40
|
-
- Ruby 3.
|
41
|
-
- Rails
|
40
|
+
- Ruby 3.1.2
|
41
|
+
- Rails 7.0.0
|
42
42
|
- MongoDB 6
|
43
43
|
- Freemind 1.0.1
|
44
44
|
|
@@ -70,64 +70,67 @@ arch -x86_64 gem install nokogiri -v '1.10.10' --platform=ruby -- --use-system-l
|
|
70
70
|
|
71
71
|
[![yt_logo_rgb_light](https://user-images.githubusercontent.com/3953832/110579381-4fa9bc00-812c-11eb-973e-da9d0f2a8109.png)](https://www.youtube.com/watch?v=XUXv7Yrskjk&feature=youtu.be)
|
72
72
|
<br />
|
73
|
-
[![
|
73
|
+
[![Jinda Install](https://i9.ytimg.com/vi/XUXv7Yrskjk/mq3.jpg?sqp=CPjUoIIG&rs=AOn4CLBfMkmMtOGz3OfUp2zyhMs3Dy9xrw)](https://www.youtube.com/watch?v=XUXv7Yrskjk&feature=youtu.be)
|
74
74
|
|
75
75
|
### Sample Jinda in Docker
|
76
76
|
|
77
77
|
- https://github.com/kul1/jinda-docker
|
78
78
|
|
79
|
-
|
80
|
-
|
81
|
-
$ docker-compose up
|
82
|
-
$ cd test/dummy
|
83
|
-
$ reails s
|
84
|
-
|
85
|
-
- http://localhost:3000
|
86
|
-
|
87
|
-
To start your own app:
|
88
|
-
first create a Rails
|
79
|
+
Supposed we want to create ecommerce web site, first create a Rails
|
89
80
|
app without ActiveRecord
|
90
81
|
|
91
|
-
$ rails new YOURAPP -BOTJ
|
82
|
+
$ rails _7.0.0_ new YOURAPP -BOTJ
|
92
83
|
|
93
84
|
## Add jinda to your Gemfile:
|
94
|
-
|
85
|
+
```
|
95
86
|
gem 'jinda'
|
96
|
-
|
97
|
-
|
87
|
+
```
|
98
88
|
For Development (most updated)
|
99
|
-
|
89
|
+
```
|
100
90
|
gem 'jinda', github:'kul1/jinda'
|
101
|
-
|
91
|
+
```
|
102
92
|
depend on your operating system, you may need to uncomment
|
103
|
-
|
93
|
+
```
|
104
94
|
gem 'therubyracer', :platforms => :ruby
|
105
|
-
|
95
|
+
```
|
106
96
|
install gems
|
107
|
-
|
108
|
-
$ bundle
|
109
|
-
|
97
|
+
```
|
98
|
+
$ bundle install
|
99
|
+
```
|
110
100
|
generate jinda application
|
111
|
-
|
101
|
+
```
|
112
102
|
$ rails generate jinda:install
|
113
|
-
|
103
|
+
```
|
114
104
|
Then run bundle again to install additional gems added by jinda
|
115
|
-
|
116
|
-
$ bundle
|
117
|
-
|
105
|
+
```
|
106
|
+
$ bundle install
|
107
|
+
```
|
118
108
|
configure mongoid, omniauth
|
119
|
-
|
109
|
+
```
|
120
110
|
$ rails generate jinda:config
|
121
|
-
|
111
|
+
```
|
122
112
|
Please make sure mongod is running then create admin user
|
123
|
-
|
113
|
+
```
|
124
114
|
$ rails jinda:seed
|
125
|
-
|
126
|
-
|
115
|
+
```
|
116
|
+
# Option: to use jinda_adminlte theme require add Gemfile with:
|
117
|
+
```
|
118
|
+
gem 'jinda_adminlte'
|
119
|
+
```
|
120
|
+
Then
|
121
|
+
```
|
122
|
+
$ rails g jinda_adminlte:install
|
123
|
+
```
|
127
124
|
now the application is ready, start it as any Rails application
|
128
|
-
|
129
|
-
|
130
|
-
|
125
|
+
Please include your .env for social login, here sample
|
126
|
+
```
|
127
|
+
GOOGLE_CLIENT_ID=
|
128
|
+
|
129
|
+
GOOGLE_CLIENT_SECRET=
|
130
|
+
```
|
131
|
+
```
|
132
|
+
$ rails server
|
133
|
+
```
|
131
134
|
go to http://localhost:3000, click _Sign In_ on the left menu, and enter user name `admin` and password `secret`
|
132
135
|
|
133
136
|
![login](https://user-images.githubusercontent.com/3953832/41832924-d868f8f0-7813-11e8-93bb-19c0357cf604.png)
|
@@ -45,7 +45,7 @@ module Jinda
|
|
45
45
|
|
46
46
|
desc "Set up mongoid config"
|
47
47
|
def setup_mongoid
|
48
|
-
generate "mongoid:config"
|
48
|
+
generate "mongoid:config -f"
|
49
49
|
inject_into_file 'config/mongoid.yml', :after => ' # raise_not_found_error: true' do
|
50
50
|
"\n raise_not_found_error: false"
|
51
51
|
end
|
@@ -9,7 +9,7 @@ module Jinda
|
|
9
9
|
# define required gems: jinda_gem, jinda_dev_gem
|
10
10
|
jinda_gem =
|
11
11
|
[
|
12
|
-
["bson", "4.
|
12
|
+
["bson", "4.15"],
|
13
13
|
["maruku", "~> 0.7.3"],
|
14
14
|
["bcrypt"],
|
15
15
|
["rouge"],
|
@@ -18,7 +18,7 @@ module Jinda
|
|
18
18
|
["font-awesome-sass", "~> 5.12.0"],
|
19
19
|
["meta-tags"],
|
20
20
|
["jquery-turbolinks", "2.1.0"],
|
21
|
-
["mongo", "2.
|
21
|
+
["mongo", "~> 2.19", ">= 2.19.3"],
|
22
22
|
["turbolinks_render"],
|
23
23
|
["haml-rails", "~> 2.0.1"],
|
24
24
|
["haml", "~> 5.1", ">= 5.1.2"],
|
@@ -248,8 +248,7 @@ IMAGE_LOCATION = "upload"
|
|
248
248
|
end
|
249
249
|
inject_into_file 'config/initializers/assets.rb', :after => '# Precompile additional assets.
|
250
250
|
' do
|
251
|
-
"Rails.application.config.assets.precompile +=
|
252
|
-
"\nRails.application.config.assets.precompile += %w( disable_enter_key.js )\n"
|
251
|
+
"Rails.application.config.assets.precompile += ['*.js', '*.css', '*.css.erb']\n"
|
253
252
|
end
|
254
253
|
end
|
255
254
|
|
@@ -4,12 +4,12 @@ development:
|
|
4
4
|
# Defines the default client. (required)
|
5
5
|
default:
|
6
6
|
# Mongoid can connect to a URI accepted by the driver:
|
7
|
-
# uri: mongodb://user:password@mongodb.domain.com:27017/
|
7
|
+
# uri: mongodb://user:password@mongodb.domain.com:27017/jinda_development
|
8
8
|
|
9
9
|
# Otherwise define the parameters separately.
|
10
10
|
# This defines the name of the default database that Mongoid can connect to.
|
11
11
|
# (required).
|
12
|
-
database:
|
12
|
+
database: jinda_development
|
13
13
|
# Provides the hosts the default client can connect to. Must be an array
|
14
14
|
# of host:port pairs. (required)
|
15
15
|
hosts:
|
@@ -173,7 +173,7 @@ production:
|
|
173
173
|
test:
|
174
174
|
clients:
|
175
175
|
default:
|
176
|
-
database:
|
176
|
+
database: jinda_test
|
177
177
|
hosts:
|
178
178
|
- localhost:27017
|
179
179
|
options:
|
@@ -4,12 +4,12 @@ development:
|
|
4
4
|
# Defines the default client. (required)
|
5
5
|
default:
|
6
6
|
# Mongoid can connect to a URI accepted by the driver:
|
7
|
-
# uri: mongodb://user:password@mongodb.domain.com:27017/
|
7
|
+
# uri: mongodb://user:password@mongodb.domain.com:27017/jinda_development
|
8
8
|
|
9
9
|
# Otherwise define the parameters separately.
|
10
10
|
# This defines the name of the default database that Mongoid can connect to.
|
11
11
|
# (required).
|
12
|
-
database:
|
12
|
+
database: jinda_development
|
13
13
|
# Provides the hosts the default client can connect to. Must be an array
|
14
14
|
# of host:port pairs. (required)
|
15
15
|
hosts:
|
@@ -173,7 +173,7 @@ production:
|
|
173
173
|
test:
|
174
174
|
clients:
|
175
175
|
default:
|
176
|
-
database:
|
176
|
+
database: jinda_test
|
177
177
|
hosts:
|
178
178
|
- localhost:27017
|
179
179
|
options:
|
@@ -4,12 +4,12 @@ development:
|
|
4
4
|
# Defines the default client. (required)
|
5
5
|
default:
|
6
6
|
# Mongoid can connect to a URI accepted by the driver:
|
7
|
-
# uri: mongodb://user:password@mongodb.domain.com:27017/
|
7
|
+
# uri: mongodb://user:password@mongodb.domain.com:27017/jinda_development
|
8
8
|
|
9
9
|
# Otherwise define the parameters separately.
|
10
10
|
# This defines the name of the default database that Mongoid can connect to.
|
11
11
|
# (required).
|
12
|
-
database:
|
12
|
+
database: jinda_development
|
13
13
|
# Provides the hosts the default client can connect to. Must be an array
|
14
14
|
# of host:port pairs. (required)
|
15
15
|
hosts:
|
@@ -173,7 +173,7 @@ production:
|
|
173
173
|
test:
|
174
174
|
clients:
|
175
175
|
default:
|
176
|
-
database:
|
176
|
+
database: jinda_test
|
177
177
|
hosts:
|
178
178
|
- localhost:27017
|
179
179
|
options:
|
data/lib/jinda/version.rb
CHANGED
data/test/dummy/Gemfile
CHANGED
@@ -4,7 +4,7 @@ git_source(:github) { |repo| "https://github.com/#{repo}.git" }
|
|
4
4
|
ruby "3.1.2"
|
5
5
|
|
6
6
|
# Bundle edge Rails instead: gem "rails", github: "rails/rails", branch: "main"
|
7
|
-
gem "rails", "~> 7.0.
|
7
|
+
gem "rails", "~> 7.0.0"
|
8
8
|
|
9
9
|
# The original asset pipeline for Rails [https://github.com/rails/sprockets-rails]
|
10
10
|
gem "sprockets-rails"
|
@@ -48,9 +48,10 @@ group :development do
|
|
48
48
|
# Speed up commands on slow machines / big apps [https://github.com/rails/spring]
|
49
49
|
# gem "spring"
|
50
50
|
end
|
51
|
-
|
52
|
-
gem
|
53
|
-
gem "
|
51
|
+
|
52
|
+
gem "jinda", path: "../../../jinda"
|
53
|
+
gem "jinda_adminlte", path: "../../../jinda_adminlte"
|
54
|
+
gem "bson", "4.15"
|
54
55
|
gem "maruku", "~> 0.7.3"
|
55
56
|
gem "bcrypt"
|
56
57
|
gem "rouge"
|
@@ -59,7 +60,7 @@ gem "font-awesome-rails"
|
|
59
60
|
gem "font-awesome-sass", "~> 5.12.0"
|
60
61
|
gem "meta-tags"
|
61
62
|
gem "jquery-turbolinks", "2.1.0"
|
62
|
-
gem "mongo"
|
63
|
+
gem "mongo"
|
63
64
|
gem "turbolinks_render"
|
64
65
|
gem "haml-rails", "~> 2.0.1"
|
65
66
|
gem "prawn"
|