-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
69 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,64 @@ | ||
package cmd | ||
|
||
//TODO | ||
import ( | ||
"fmt" | ||
) | ||
|
||
func PrintHelp() { | ||
|
||
fmt.Println("\033[1m+------------------------+\033[0m") | ||
fmt.Println("\033[1m| UptimeKuma - Probe CLI |\033[0m") | ||
fmt.Println("\033[1m+------------------------+\033[0m") | ||
|
||
fmt.Println("\033[1mRepository:\033[0m github.com/K-cermak/UptimeKumaProbe") | ||
fmt.Println("\033[1mLicense:\033[0m MIT") | ||
fmt.Println("\033[1mAuthor:\033[0m Karel Cermak | karlosoft.com") | ||
fmt.Println("\033[1mVersion:\033[0m v1.0, © 2025") | ||
|
||
fmt.Println("\n\033[1mUsage: kprobe <command>\033[0m") | ||
fmt.Println("\n\033[1mCommands:\033[0m") | ||
|
||
fmt.Println(" \033[1m-> cron <type>\033[0m") | ||
fmt.Println(" \033[3mStart the cron job with the specified type.\033[0m") | ||
fmt.Println(" \033[3mUse 'all' to start all cron jobs.\033[0m") | ||
fmt.Println(" \033[3mUse 'all_except:<names>' to start all cron jobs except the specified ones (seperate names with comma without space).\033[0m") | ||
fmt.Println(" \033[3mUse 'only:<names>' to start only the specified cron jobs (seperate names with comma without space).\033[0m") | ||
|
||
fmt.Println("\n \033[1m-> history <scan_name> <from> <to>\033[0m") | ||
fmt.Println(" \033[3mView the history of the specified scan.\033[0m") | ||
fmt.Println(" \033[3mFor <from> and <to> use the format 'YYYY-MM-DD HH:MM:SS'.\033[0m") | ||
|
||
fmt.Println("\n \033[1m-> db init\033[0m") | ||
fmt.Println(" \033[3mInitialize the database.\033[0m") | ||
fmt.Println(" \033[1m-> db reset\033[0m") | ||
fmt.Println(" \033[3mReset the database, this will delete all the data!\033[0m") | ||
|
||
fmt.Println("\n \033[1m-> config verify <path>\033[0m") | ||
fmt.Println(" \033[3mVerify the configuration file at the specified path.\033[0m") | ||
fmt.Println(" \033[1m-> config replace <path>\033[0m") | ||
fmt.Println(" \033[3mReplace the current configuration with the one at the specified path.\033[0m") | ||
fmt.Println(" \033[3mFile is copied to the database, so you can delete the original file afterwards.\033[0m") | ||
fmt.Println(" \033[1m-> config view\033[0m") | ||
fmt.Println(" \033[3mView the current configuration.\033[0m") | ||
|
||
fmt.Println("\n \033[1m-> keys view all\033[0m") | ||
fmt.Println(" \033[3mView all the keys with their values in the database.\033[0m") | ||
fmt.Println(" \033[3mKeys with the * prefix can be changed.\033[0m") | ||
fmt.Println(" \033[1m-> keys view <key>\033[0m") | ||
fmt.Println(" \033[3mView the value of the specified key.\033[0m") | ||
fmt.Println(" \033[3mIf the key has the * prefix, it can be changed.\033[0m") | ||
|
||
fmt.Println("\n \033[1m-> test ping <address> <timeout_ms>\033[0m") | ||
fmt.Println(" \033[3mTest the ping to the specified address with the specified timeout.\033[0m") | ||
fmt.Println(" \033[3mTimeout is in milliseconds.\033[0m") | ||
fmt.Println(" \033[1m-> test http <address> <timeout_ms>\033[0m") | ||
fmt.Println(" \033[3mTest the http request to the specified address with the specified timeout.\033[0m") | ||
fmt.Println(" \033[3mTimeout is in milliseconds.\033[0m") | ||
fmt.Println(" \033[1m-> test api [service|http]\033[0m") | ||
fmt.Println(" \033[3mTest the api service or the http service.\033[0m") | ||
fmt.Println(" \033[3mUse 'service' to test the api service via systemctl.\033[0m") | ||
fmt.Println(" \033[3mUse 'http' to test the api service via http request.\033[0m") | ||
|
||
fmt.Println("\n \033[1m-> help\033[0m") | ||
fmt.Println(" \033[3mPrint this help message.\033[0m") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters