File tree Expand file tree Collapse file tree 2 files changed +8
-1
lines changed
monorepo-templates/src/utils Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ const skipDirs = new Set([
1313
1414const skipFiles = new Set ( [
1515 '.DS_Store' ,
16+ 'CHANGELOG.md' ,
1617 'typed-router.d.ts' ,
1718 'worker-configuration.d.ts' ,
1819] )
Original file line number Diff line number Diff line change 11import path from 'node:path'
2+ import { shouldSkipTemplatePath } from '@icebreakers/monorepo-templates'
23import { simpleGit } from 'simple-git'
34import { templateMap } from '../../src/commands/create'
45import { rootDir } from '../../src/constants'
@@ -16,7 +17,12 @@ export async function getTemplateTargets() {
1617 return Promise . all (
1718 Object . values ( templateMap ) . map ( ( definition ) => {
1819 const sourceDir = path . resolve ( rootDir , 'templates' , definition . source )
19- return getTrackedFilesInDir ( sourceDir )
20+ return getTrackedFilesInDir ( sourceDir ) . then ( ( entries ) => {
21+ return entries . filter ( ( entry ) => {
22+ const targetPath = path . resolve ( rootDir , entry )
23+ return ! shouldSkipTemplatePath ( sourceDir , targetPath )
24+ } )
25+ } )
2026 } ) ,
2127 ) . then ( x => x . flat ( 1 ) . map ( entry => entry . replace ( templatePrefix , '' ) ) )
2228}
You can’t perform that action at this time.
0 commit comments