File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ import fs from 'fs';
22import globby from 'globby' ;
33import Handlebars from 'handlebars' ;
44import isUtf8 from 'is-utf8' ;
5- import path from 'path' ;
5+ import path , { sep } from 'path' ;
66import slash from 'slash' ;
77import { v4 as uuidv4 } from 'uuid' ;
88import { View } from '.' ;
@@ -91,7 +91,7 @@ export async function copy(args: CopyConfig) {
9191 const targetPath = format (
9292 slash ( path . resolve ( args . packageDir , relativePath ) ) ,
9393 args . view
94- ) . replace ( / g i t i g n o r e $ / , '.gitignore' ) ; // https://github.com/uetchy/create-create-app/issues/38
94+ ) . replace ( new RegExp ( ` ${ sep } gitignore$` , 'g' ) , ` ${ sep } .gitignore` ) ; // https://github.com/uetchy/create-create-app/issues/38
9595 prepareDirectory ( targetPath ) ;
9696
9797 let sourceData = fs . readFileSync ( sourcePath ) ;
You can’t perform that action at this time.
0 commit comments