We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent dabd561 commit 4cda4dbCopy full SHA for 4cda4db
index.js
@@ -31,7 +31,7 @@ const getTar = ({
31
repo,
32
path = '',
33
name,
34
- depth = 3
+ depth
35
}) => {
36
const url = `https://codeload.github.com/${user}/${repo}/tar.gz/master`
37
const cmd = `curl ${url} | tar -xz -C ${name} --strip=${depth} ${repo}-master/${path}`
@@ -52,7 +52,7 @@ const create = async (opts = {}) => {
52
const dirname = path.resolve(opts.name)
53
const name = path.basename(dirname)
54
const [ user, repo, ...paths ] = opts.template.split('/')
55
- const depth = opts.templateDepth
+ const depth = paths.length+1
56
57
fs.ensureDirSync(name)
58
0 commit comments