1.0.2 • Published 4 years ago
@krissself/deploy-env v1.0.2
Deploy Env By Config
in project root, create an
environmentsdirmake a config file
config.jsinenvironmentsdir
const path = require('path')
module.exports = {
deploy_path: path.join(__dirname, '../'),
envs: {
dev: path.join(__dirname, 'dev'),
t1: path.join(__dirname, 't1'),
t2: path.join(__dirname, 't2'),
}
}- put your envs files to dir under
environments
dir like:
- root
- environments
- dev a.xx b.xx
- t1 a.xx b.xx
- t2 a.xx b.xx
- config.js
- environments
- open cmd and exec
deploy-env -e <env>(replace with yourenvskey)
files in <env> dir will be copy to deploy_path