File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed
npm-packages/cli/source/components/commands Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ export default function Create({cli}: {cli: Result<Flags>}) {
5656 </ Box > ,
5757 ) ;
5858 try {
59- await $ `git clone https://github.com/ClayPulse/pulse-editor-extension-template.git ${ name } ` ;
59+ await $ `git clone --depth 1 https://github.com/ClayPulse/pulse-editor-extension-template.git ${ name } ` ;
6060 } catch ( error ) {
6161 setMessage (
6262 < Text color = "redBright" >
@@ -83,6 +83,18 @@ export default function Create({cli}: {cli: Result<Flags>}) {
8383 // Write the modified package.json back to the file
8484 fs . writeFileSync ( packageJsonPath , JSON . stringify ( packageJson , null , 2 ) ) ;
8585
86+ // Remove the .git directory
87+ const gitDirPath = path . join ( process . cwd ( ) , name , '.git' ) ;
88+ if ( fs . existsSync ( gitDirPath ) ) {
89+ fs . rmSync ( gitDirPath , { recursive : true , force : true } ) ;
90+ }
91+
92+ // Remove the .github directory
93+ const githubDirPath = path . join ( process . cwd ( ) , name , '.github' ) ;
94+ if ( fs . existsSync ( githubDirPath ) ) {
95+ fs . rmSync ( githubDirPath , { recursive : true , force : true } ) ;
96+ }
97+
8698 setMessage (
8799 < Box >
88100 < Spinner type = "dots" />
You can’t perform that action at this time.
0 commit comments