This repository was archived by the owner on Aug 5, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +44
-7
lines changed
Expand file tree Collapse file tree 3 files changed +44
-7
lines changed Original file line number Diff line number Diff line change 441 . [ Installation] ( Installation )
552 . [ Connection Setup] ( Setup )
663 . [ Model Definition] ( Definition )
7- 1 . [ Validations] ( Definition/Validations )
8- 2 . [ Relations] ( Definition/Relations )
9- 3 . [ Before and After Hooks] ( Definition/Hooks )
10- 4 . [ Scopes] ( Definition/Scopes )
7+ 1 . [ Validations] ( Definition_Validations )
8+ 2 . [ Relations] ( Definition_Relations )
9+ 3 . [ Before and After Hooks] ( Definition_Hooks )
10+ 4 . [ Scopes] ( Definition_Scopes )
11114 . [ Model] ( Model )
12- 1 . [ Find] ( Model/Find )
12+ 1 . [ Find] ( Model_Find )
13135 . [ Collection] ( Collection )
14146 . [ Record] ( Record )
1515
Original file line number Diff line number Diff line change 1+ ## Sqlite3
2+ ``` js
3+ var OpenRecord = require (' openrecord' );
4+
5+ var store = new OpenRecord ({
6+ type: ' sqlite3' ,
7+ file: ' test.sqlite'
8+ });
9+ ```
10+
11+ ## Postgres
12+ ``` js
13+ var OpenRecord = require (' openrecord' );
14+
15+ var store = new OpenRecord ({
16+ type: ' postgres' ,
17+ host: ' localhost' ,
18+ database: ' mydb' ,
19+ username: ' myuser' ,
20+ password: ' mypass'
21+ });
22+ ```
23+
24+ ## MySQL
25+ ``` js
26+ var OpenRecord = require (' openrecord' );
27+
28+ var store = new OpenRecord ({
29+ type: ' postgres' ,
30+ host: ' localhost' ,
31+ database: ' mydb' ,
32+ username: ' myuser' ,
33+ password: ' mypass'
34+ });
35+ ```
Original file line number Diff line number Diff line change @@ -13,7 +13,8 @@ var tmp = [];
1313
1414
1515files = glob . sync ( './lib/*.js' ) ;
16- files = files . concat ( glob . sync ( './lib/*/*.js' ) ) ;
16+ files = files . concat ( glob . sync ( './lib/base/*.js' ) ) ;
17+ files = files . concat ( glob . sync ( './lib/stores/**/*.js' ) ) ;
1718files = files . concat ( glob . sync ( './examples/**/*.js' ) ) ;
1819
1920
@@ -130,6 +131,7 @@ async.series(tmp, function(){
130131 ( function ( name , docs ) {
131132
132133 name = name . split ( '.' ) [ 0 ] ;
134+ name = name . replace ( '/' , '_' ) ;
133135
134136 tmp . push ( function ( next ) {
135137 var filename = __dirname + '/docs/' + name + '.md' ;
@@ -160,7 +162,7 @@ async.series(tmp, function(){
160162
161163
162164 async . parallel ( tmp , function ( ) {
163- var copy = [ 'Home.md' , 'Installation.md' ] ;
165+ var copy = [ 'Home.md' , 'Installation.md' , 'Setup.md' ] ;
164166
165167 for ( var i in copy ) {
166168 var file_path = __dirname + '/docs/' + copy [ i ] ;
You can’t perform that action at this time.
0 commit comments