- 授权协议: Apache
- 开发语言: Google Go
- 操作系统: 跨平台
- 软件首页: https://github.com/subchen/frep
- 软件文档: https://github.com/subchen/frep
软件介绍
frep 是一个根据模版文件生成相应的配置文件功能,相关数据可以从环境变量,json,yaml,toml文件中获取。
比如根据 nginx.conf.in 模版文件 和 动态数据 data.json,动态生成 nginx.conf
frep nginx.conf.in --load data.json
具体帮助参考:
NAME: frep - Generate file using template USAGE: frep [options] input-file[:output-file] ... VERSION: 1.2.0-50 AUTHORS: Guoqiang ChenOPTIONS: -e name=value, --env name=value set variable name=value, can be passed multiple times --json jsonstring load variables from json object string --load file load variables from json/yaml/toml file --overwrite overwrite if destination file exists --dryrun just output result to console instead of file --delims value template tag delimiters (default: {{:}}) --help print this usage --version print version information EXAMPLES: frep nginx.conf.in -e webroot=/usr/share/nginx/html -e port=8080 frep nginx.conf.in:/etc/nginx.conf -e webroot=/usr/share/nginx/html -e port=8080 frep nginx.conf.in --json '{"webroot": "/usr/share/nginx/html", "port": 8080}' frep nginx.conf.in --load config.json --overwrite
