From 8158c13801871963a55e4ba4309b782cd3cfd639 Mon Sep 17 00:00:00 2001 From: fbt Date: Fri, 27 Nov 2026 21:50:53 +0000 Subject: [PATCH] minor fixes Signed-off-by: fbt --- ufw | 6 +++--- ufwd | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ufw b/ufw index 6e4e4df..7357b31 100755 --- a/ufw +++ b/ufw @@ -45,6 +45,7 @@ usage() { -v|--void # Don't add the file to my files. -c|--clipboard # Throw the result into the clipboard -i|--my-ip # Get the IP you're reaching the service with, usually it will be your public address. + -l|--login # Get a login token sent to email for Config options (~/.config/ufw): secret # Your personal token. Get it at https://8fw.me/settings_form @@ -242,7 +243,7 @@ get_my_ip() { } login() { - declare api_response + declare api_response login=$1 api_response=$( curl "$cfg_service_url/token_request.json?login=$login" ) @@ -255,7 +256,6 @@ login() { get_token() { [[ $secret ]] && return 0 - [[ -f $cfg_file ]] && return 1 declare api_response login password @@ -463,7 +463,7 @@ main() { ;; getmyip) get_my_ip;; - login) login;; + login) login "${args[0]}";; esac } diff --git a/ufwd b/ufwd index 8ac2542..1cba4bd 100755 --- a/ufwd +++ b/ufwd @@ -10,7 +10,7 @@ msg() { printf '%s\n' "$*"; } err() { echo "$*" >&2; } usage() { - printf 'Usage: ufwd [-hn] [-d workdir] -D [check delay]\n' + printf 'Usage: ufwd [flags]\n' printf ' -h # Show this message.\n' printf ' -n # Enable notifications with notify-send. Must be installed.\n' printf ' -d [path] # Set the dir that is to be watched.\n'