Skip to content

希望可执行程序增加参数解析flag,来设置根目录路径,配置文件路径等; #59

@lnlion

Description

@lnlion
  1. 希望可执行程序增加参数解析flag,来设置根目录路径,配置文件路径等; 比如:mindoc --root="/path/to/mindoc" --config="/path/to/mindoc/app.conf"; golang中进行参数读取还是很简单的,具体请参考标准库https://godoc.org/flag; 必须在项目根目录运行程序,才能正确读取项目静态文件,这有点傻傻的感觉;
  2. 希望可执行程序增加daemon运行模式,以便于将可执行程序作为linux服务运行(可接受并处理signal);b
    比如: mindoc --daemon=true; 可使用第三方库实现:https://github.com/takama/daemon;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions