mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
[web] esm-check-migration
to lookup scripts and migrations (#20736)
* [web] `esm-check-migration` to lookup scripts and migrations * Remove unnecessary minimist default GitOrigin-RevId: 55b0900d2d1dc2669e297ddc778dcd236c2912a7
This commit is contained in:
parent
cd6631c105
commit
a6016ff984
1 changed files with 3 additions and 4 deletions
|
@ -2,7 +2,7 @@ const fs = require('fs')
|
|||
const path = require('path')
|
||||
const minimist = require('minimist')
|
||||
|
||||
const APP_CODE_PATH = ['app', 'modules']
|
||||
const APP_CODE_PATH = ['app', 'modules', 'migrations', 'scripts']
|
||||
|
||||
const {
|
||||
_: args,
|
||||
|
@ -17,7 +17,6 @@ const {
|
|||
json: 'j',
|
||||
},
|
||||
default: {
|
||||
_: ['app', 'modules'],
|
||||
files: false,
|
||||
help: false,
|
||||
json: false,
|
||||
|
@ -85,8 +84,8 @@ function collectJsFiles(dir, files = []) {
|
|||
if (stat.isDirectory()) {
|
||||
const basename = path.basename(fullPath)
|
||||
|
||||
// skipping 'test' and 'frontend' directories from search
|
||||
if (basename !== 'test' && basename !== 'frontend') {
|
||||
// skipping directories from search
|
||||
if (!['test', 'frontend', 'node_modules'].includes(basename)) {
|
||||
collectJsFiles(fullPath, files)
|
||||
}
|
||||
} else if (
|
||||
|
|
Loading…
Reference in a new issue