File tree Expand file tree Collapse file tree 3 files changed +10
-1
lines changed
Expand file tree Collapse file tree 3 files changed +10
-1
lines changed Original file line number Diff line number Diff line change 8181 "docs:prepare:publish:5x" : " git checkout 5.x && git merge 5.x && npm run docs:clean:stable && npm run docs:generate && npm run docs:copy:tmp && git checkout gh-pages && npm run docs:copy:tmp:5x" ,
8282 "docs:prepare:publish:6x" : " git checkout 6.x && git merge 6.x && npm run docs:clean:stable && env DOCS_DEPLOY=true npm run docs:generate && mv ./docs/6.x ./tmp && git checkout gh-pages && npm run docs:copy:tmp:6x" ,
8383 "docs:prepare:publish:7x" : " env DOCS_DEPLOY=true npm run docs:generate && git checkout gh-pages && rimraf ./docs/7.x && mv ./tmp ./docs/7.x" ,
84- "docs:prepare:publish:8x" : " git checkout gh-pages && git merge 8.x && npm run docs:generate " ,
84+ "docs:prepare:publish:8x" : " env DOCS_DEPLOY=true npm run docs:generate && git checkout gh-pages && rimraf ./docs/ 8.x && mv ./tmp ./ docs/8.x " ,
8585 "docs:check-links" : " blc http://127.0.0.1:8089 -ro" ,
8686 "lint" : " eslint ." ,
8787 "lint-js" : " eslint . --ext .js --ext .cjs" ,
Original file line number Diff line number Diff line change @@ -20,6 +20,8 @@ markdown.setOptions({
2020// 5.13.5 -> 5.x, 6.8.2 -> 6.x, etc.
2121version = version . slice ( 0 , version . indexOf ( '.' ) ) + '.x' ;
2222
23+ console . log ( 'Generating search for version' , version ) ;
24+
2325const contentSchema = new mongoose . Schema ( {
2426 title : { type : String , required : true } ,
2527 body : { type : String , required : true } ,
@@ -116,12 +118,16 @@ function generateContents() {
116118}
117119
118120async function generateSearch ( config ) {
121+ console . log ( 'Connect to' , config . uri ) ;
119122 await mongoose . connect ( config . uri , { dbName : 'mongoose' } ) ;
120123
121124 // wait for the index to be created
125+ console . log ( 'Init Content model...' ) ;
122126 await Content . init ( ) ;
123127
128+ console . log ( 'Deleting existing content...' ) ;
124129 await Content . deleteMany ( { version } ) ;
130+ console . log ( 'Deleted content for version' , version ) ;
125131
126132 const contents = generateContents ( ) ;
127133
Original file line number Diff line number Diff line change @@ -147,6 +147,7 @@ function deleteAllHtmlFiles() {
147147}
148148
149149function moveDocsToTemp ( ) {
150+ console . log ( 'Moving docs to tmp dir...' ) ;
150151 if ( ! versionObj . versionedPath ) {
151152 throw new Error ( 'Cannot move unversioned deploy to /tmp' ) ;
152153 }
@@ -622,7 +623,9 @@ if (isMain) {
622623 }
623624
624625 if ( generateSearchPromise ) {
626+ console . log ( 'Generating search...' ) ;
625627 await generateSearchPromise ;
628+ console . log ( 'Search generated successfully' ) ;
626629 }
627630
628631 console . log ( 'Done Processing' ) ;
You can’t perform that action at this time.
0 commit comments