Skip to content

Commit

Permalink
feat: support routify 2
Browse files Browse the repository at this point in the history
  • Loading branch information
ghostdevv committed May 24, 2022
1 parent 7601111 commit 0fc5708
Show file tree
Hide file tree
Showing 3 changed files with 58 additions and 2 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
"log-symbols": "^5.1.0",
"minimist": "^1.2.6",
"prompts": "^2.4.2",
"simple-git": "^3.7.1",
"update-notifier": "^5.1.0"
},
"devDependencies": {
Expand Down
40 changes: 40 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 17 additions & 2 deletions src/versions/two.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,18 @@
export const run = () => {
console.log('Not done yet!');
import logSymbols from 'log-symbols';
import simpleGit from 'simple-git';
import { rmSync } from 'fs';
import { join } from 'path';
import k from 'kleur';

export const run = async ({ projectDir, args }) => {
const git = simpleGit(projectDir);

console.log(k.blue(`\n${logSymbols.info} Cloning template...`));

await git.clone('https://github.com/roxiness/routify-starter', projectDir);

rmSync(join(projectDir, '.git'), {
recursive: true,
force: true,
});
};

0 comments on commit 0fc5708

Please sign in to comment.