From ea057e74011bce23826725a900a2eef3bdb926ea Mon Sep 17 00:00:00 2001 From: Quentin Snow Date: Tue, 17 Jan 2023 13:42:09 -0600 Subject: [PATCH] Update readme with correct spacing --- README.md | 48 ++++++++++++++---------------- src/optHandlers/mainOptHandler.cpp | 32 ++++++++++---------- 2 files changed, 38 insertions(+), 42 deletions(-) diff --git a/README.md b/README.md index 66e9522..a443da4 100644 --- a/README.md +++ b/README.md @@ -1,41 +1,37 @@ Output of budget. ``` Usage: - budget [options] ... Actions: - -h --help Prints this. - -a --account<=STRING> Management tools for an account. - -c --create<=STRING> Creates a new account with NAME. - -e --earn<=STRING> Add an earning to an account. - -p --payment<=STRING> Add a payment to an account. + -h --help Prints this. + -a --account<=STRING> Management tools for an account. + -c --create<=STRING> Creates a new account with NAME. + -e --earn<=STRING> Add an earning to an account. + -p --payment<=STRING> Add a payment to an account. Account Options: [-dvD] - -d --delete Deletes specified account. - --force-delete Deletes the specified account without confirmation. - -v --value Gets the current value of the account. - -D --description<=STRING> Changes the description of the account. + -d --delete Deletes specified account. + --force-delete Deletes the specified account without confirmation. + -v --value Gets the current value of the account. + -D --description<=STRING> Changes the description of the account. Create Options: [-d] - -d --description<=STRING> Sets a description for an account. + -d --description<=STRING> Sets a description for an account. Earn Options: -v [-drD] - -v --value= Value for earning. - -d --description= Description for earning. - -r --receipt= Path to file to store in DB as receipt. - -D --date=
Date as dd/mm/yyyy. Default will be today. - -t --time= 24 hour time as hh/mm/ss. Default will be now. + -v --value= Value for earning. + -d --description= Description for earning. + -r --receipt= Path to file to store in DB as receipt. + -D --date= Date as dd/mm/yyyyTHH:MM:SS. Default will be today. Payment Options: -v [-drD] - -v --value= Value for payment. - -d --description= Description for payment. - -r --receipt= Path to file to store in DB as receipt. - -D --date= Date as dd/mm/yyyy. Default will be today. - -t --time= 24 hour time as hh/mm/ss. Default will be now. + -v --value= Value for payment. + -d --description= Description for payment. + -r --receipt= Path to file to store in DB as receipt. + -D --date= Date as dd/mm/yyyyTHH:MM:SS. Default will be today. ``` Arguments are processed like blocks with each one terminated by the next Action. For example ``` budget -cAcct -eAcct -v10.00 -r"./receipt.pdf" -pAcct -v5.50 -r"./payment.pdf" -``` +```` Does the following in order: -1. Creates an account named ``Acct`` with no description. -2. Earns ``10.00`` to it with a receipt. -3. Pays ``5.50`` to it with a receipt. - +Creates an account named Acct with no description. +Earns 10.00 to it with a receipt. +Pays 5.50 to it with a receipt. diff --git a/src/optHandlers/mainOptHandler.cpp b/src/optHandlers/mainOptHandler.cpp index 16aec56..f682668 100644 --- a/src/optHandlers/mainOptHandler.cpp +++ b/src/optHandlers/mainOptHandler.cpp @@ -295,27 +295,27 @@ void MainOptHandler::help() { std::cout << "Usage:" << std::endl; std::cout << "\tbudget [options] ..." << std::endl; std::cout << "Actions:" << std::endl; - std::cout << "\t-h --help Prints this." << std::endl; - std::cout << "\t-a --account<=STRING> Management tools for an account." << std::endl; - std::cout << "\t-c --create<=STRING> Creates a new account with NAME." << std::endl; - std::cout << "\t-e --earn<=STRING> Add an earning to an account." << std::endl; - std::cout << "\t-p --payment<=STRING> Add a payment to an account." << std::endl; + std::cout << "\t-h --help Prints this." << std::endl; + std::cout << "\t-a --account<=STRING> Management tools for an account." << std::endl; + std::cout << "\t-c --create<=STRING> Creates a new account with NAME." << std::endl; + std::cout << "\t-e --earn<=STRING> Add an earning to an account." << std::endl; + std::cout << "\t-p --payment<=STRING> Add a payment to an account." << std::endl; std::cout << "Account Options: [-dvD]" << std::endl; - std::cout << "\t-d --delete Deletes specified account." << std::endl; - std::cout << "\t--force-delete Deletes the specified account without confirmation." << std::endl; - std::cout << "\t-v --value Gets the current value of the account." << std::endl; - std::cout << "\t-D --description<=STRING> Changes the description of the account." << std::endl; + std::cout << "\t-d --delete Deletes specified account." << std::endl; + std::cout << "\t--force-delete Deletes the specified account without confirmation." << std::endl; + std::cout << "\t-v --value Gets the current value of the account." << std::endl; + std::cout << "\t-D --description<=STRING> Changes the description of the account." << std::endl; std::cout << "Create Options: [-d]" << std::endl; - std::cout << "\t-d --description<=STRING> Sets a description for an account." << std::endl; + std::cout << "\t-d --description<=STRING> Sets a description for an account." << std::endl; std::cout << "Earn Options: -v [-drD]" << std::endl; - std::cout << "\t-v --value= Value for earning." << std::endl; - std::cout << "\t-d --description= Description for earning." << std::endl; - std::cout << "\t-r --receipt= Path to file to store in DB as receipt." << std::endl; + std::cout << "\t-v --value= Value for earning." << std::endl; + std::cout << "\t-d --description= Description for earning." << std::endl; + std::cout << "\t-r --receipt= Path to file to store in DB as receipt." << std::endl; std::cout << "\t-D --date= Date as dd/mm/yyyyTHH:MM:SS. Default will be today." << std::endl; std::cout << "Payment Options: -v [-drD]" << std::endl; - std::cout << "\t-v --value= Value for payment." << std::endl; - std::cout << "\t-d --description= Description for payment." << std::endl; - std::cout << "\t-r --receipt= Path to file to store in DB as receipt." << std::endl; + std::cout << "\t-v --value= Value for payment." << std::endl; + std::cout << "\t-d --description= Description for payment." << std::endl; + std::cout << "\t-r --receipt= Path to file to store in DB as receipt." << std::endl; std::cout << "\t-D --date= Date as dd/mm/yyyyTHH:MM:SS. Default will be today." << std::endl; std::cout << std::endl; std::cout << "Arguments are processed like blocks with each one terminated by the next Action. For example"