1
0
mirror of https://github.com/jht5945/buildj.git synced 2025-12-28 17:50:05 +08:00

add print_version

This commit is contained in:
2019-08-11 12:01:51 +08:00
parent 86b7b85776
commit b6933ff3b8
2 changed files with 12 additions and 0 deletions

View File

@@ -9,6 +9,7 @@ pub fn print_usage() {
print!(r#"
buildj ::: - print this message
buildj :::help - print this message
buildj :::version - print version
buildj :::create --java<version> --maven<version> - create java + maven project
e.g. buildj :::create --java1.8 --maven3.5.2
buildj :::create --java<version> --gradle<version> - create java + gradle project
@@ -23,6 +24,15 @@ buildj - run build, run assigned v
"#);
}
pub fn print_version() {
print!(r#"buildj {} - {}
Copyright (C) 2019 Hatter Jiang.
License MIT <https://opensource.org/licenses/MIT>
Written by Hatter Jiang
"#, super::BUDERJ_VER, &super::GIT_HASH[0..7]);
}
pub fn is_verbose() -> bool {
match env::var("BUILDJ_VERBOSE") {
Err(_) => false,