Cross-platform
cp
copy easy files and folders: create missing folders automatically
use it programmatically:
install via npm i st-cp
or yarn add st-cp
.
import {copyPathOrFile} from 'st-cp';
copyPathOrFile('sourcePath',{path: 'destinationPath', isDirectory: true});
use the cli npx st-cp source destination
- required
- multiple (files and folders)
- required
- enforce folder with / @ the end
# before
├── --- file1
├── --- file2
├── --- file3
st-cp file1 file2 file3 folder
# after
├── --- file1
├── --- file2
├── --- file3
├── --- folder/file1
├── --- folder/file2
├── --- folder/file3
# before
├── --- file
st-cp file folder/
# after
├── --- file
├── --- folder/file
# before
├── --- file
st-cp file folder/new-file
# after
├── --- file
├── --- folder/new-file
# before
├── --- folder
st-cp folder folder1
# after
├── --- folder
├── --- folder1
# before
├── --- file1
├── --- file2
├── --- folder1
├── --- folder2
st-cp file folder dist
# after
├── --- file1
├── --- file2
├── --- folder1
├── --- folder2
├── --- dist/file1
├── --- dist/file2
├── --- dist/folder1
├── --- dist/folder2
copy file to existing folder
# before
├── --- file
├── --- folder
st-cp file folder
# after
├── --- file
├── --- folder
├── --- folder/file
See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope>
is optional
feat: add hat wobble
^--^ ^------------^
| |
| +-> Summary in present tense.
|
+-------> Type: chore, docs, feat, fix, refactor, style, or test.
More Examples:
feat
: (new feature for the user, not a new feature for build script)fix
: (bug fix for the user, not a fix to a build script)docs
: (changes to the documentation)style
: (formatting, missing semi colons, etc; no production code change)refactor
: (refactoring production code, eg. renaming a variable)test
: (adding missing tests, refactoring tests; no production code change)chore
: (updating grunt tasks etc; no production code change)
References:
- https://www.conventionalcommits.org/
- https://seesparkbox.com/foundry/semantic_commit_messages
- http://karma-runner.github.io/1.0/dev/git-commit-msg.html
Thank you so much for supporting us financially! 🙏🏻😎🥳👍
Tom |
SpringType is brought to you by:
Aron Homberg |
Michael Mannseicher |
Please help out to make this project even better and see your name added to the list of our CONTRIBUTORS.md 🎉