@hankychung/node-copy-dir
v1.0.5
Published
copy the whole directory from here to there, base on node.js
Downloads
2
Readme
description
copy the whole directory from here to there
usage
const copyDir = require('@hankychung/node-copy-dir')
copyDir('./somewhere/src', './other/dest').then(() => {
// the whole `src` directory will be copied to the `dest` directory, if the promise is resolved
}).catch(e => {
console.log(e)
})
params
example: copyDir(srcPath, destPath, isIncludeRootFolder)
srcPath
type: string
desc: the source directory path
destPath
type: string
desc: the destination path
isIncludeRootFolder
type: boolean
desc: copy with the source directory's root folder or not
default: true