0.0.0 • Published 6 years ago
@utftufutukgyftryidytftuv/rbt v0.0.0
RFT - recursive file template
About
RFT replace variables like $FOO ${FOO} and {{FOO}}
RFT has a format rft source target
- If source is file RFT place new in file in target path
If source ia dir RFT replace variables recursive in files and subdirs and place them in target dir relatively by their path from source dir
Options
-e FOO=barand--env FOO=baradd variable--env-file /.envadd variables form file--source /sourceset source instead 1-st argument--target /targetset source instead 2-nd argument
Examples
Cli file
initial paths
/source/file/target/
file by path /source/file
Lorem $FOO ipsum ${FOO} dolor sit {{FOO}} ametcommand
npx @utftufutukgyftryidytftuv/rft -e FOO=bar /source/file /target/new/path/file
result paths
/source/file/target/new/path/file
file by path /target/new/path/file
Lorem bar ipsum bar dolor sit bar ametCli dir
initial paths
/source/file/source/subdir/file/target/
file by path /source/file
Lorem $FOO ipsum ${FOO} dolor sit {{FOO}} ametfile by path /source/subdir/file
Lorem $FOO ipsum ${FOO} dolor sit {{FOO}} ametcommand
npx @utftufutukgyftryidytftuv/rft -e FOO=bar /source /target
result paths
/source/file/source/subdir/file/target/file/target/subdir/file
file by path /target/file
Lorem bar ipsum bar dolor sit bar ametfile by path /target/subdir/file
Lorem bar ipsum bar dolor sit bar amet0.0.0
6 years ago