写了一个类似项目模版的东西(这东西写的很烂,目前在重写中),用到了Nginx Upload module一类的,为了方便,写了个配置文件的示例,又想,既然有了示例,为什么不写个脚本来生成配置文件?
脚本读取项目的配置文件,然后将别的程序的配置文件里面专门留下来用来替换的字符串 例如 {{{site_name}}}
具体是这样的
https://github.com/tioover/hanger/tree/master/example/conf
https://github.com/tioover/hanger/blob/master/example/project_initer.py
感觉这种方法丑的不行,有没有更好一点的方法
脚本读取项目的配置文件,然后将别的程序的配置文件里面专门留下来用来替换的字符串 例如 {{{site_name}}}
具体是这样的
https://github.com/tioover/hanger/tree/master/example/conf
https://github.com/tioover/hanger/blob/master/example/project_initer.py
感觉这种方法丑的不行,有没有更好一点的方法

