# lib/dsu/subcommands en: subcommands: browse: week: desc: week|w usage: Browse DSU entries for the current week long_desc: | Browse DSU entries for the current week. $ dsu browse w $ dsu browse w month: desc: month|m usage: Browse DSU entries for the current month long_desc: | Browse DSU entries for the current month. $ dsu browse month $ dsu browse m year: desc: year|y usage: Browse DSU entries for the current year long_desc: | Browse DSU entries for the current year. $ dsu browse year $ dsu browse y headers: browsing: Browsing DSU entries for %{of} (%{from} thru %{to}) week_of: Week of %{week} month_of: Month of %{month} year_of: Year of %{year} config: delete: desc: delete usage: Deletes the configuration file long_desc: | Deletes the configuration file. EXAMPLES: dsu config delete NOTES Deleting the dsu configuration file will simply cause dsu to use the default configuration options (`Dsu::Models::Configuration::DEFAULT_CONFIGURATION`). info: desc: info usage: Displays information about this gem configuration long_desc: | Displays information about this gem configuration. EXAMPLES: $ dsu config info init: desc: init usage: Creates and initializes a .dsu file in your home folder long_desc: | Creates and initializes a .dsu file in your home folder (%{home_folder}) that may be edited. EXAMPLES: $ dsu config init CONFIGURATION FILE ENTRIES The following configuration file options are available: version: The configuration version - DO NOT ALTER THIS VALUE! editor: The default editor to use when editing entry groups if the EDITOR environment variable on your system is not set. The default is 'nano'. You'll need to change the default editor on Windows systems. Default: "nano" on nix sytems. entries_display_order: The order by which entries will be displayed, "asc" or "desc" (ascending or descending, respectively). Default: "desc" carry_over_entries_to_today: Applicable to the `dsu edit` command. Valid values are true|false. If true, when editing DSU entries for the first time on any given day (e.g. `dsu edit today`), DSU entries from the previous day will be copied into the current editing session. If there are no DSU entries from the previous day, dsu will search backwards up to 7 days to find a DSU date that has entries to copy. If after searching back 7 days, no DSU entries are found, the editor session will simply provide no previous DSU entries. Default: false include_all: Applicable to dsu commands that display DSU date lists (e.g. `dsu list` commands). Valid values are true|false. If true, all DSU dates within the specified range will be displayed, regardless of whether or not a particular date has entries. If false, only DSU dates between the first and last DSU dates that have entries will be displayed. Default: false theme_name: Default: "default" delete: date: desc: date|d DATE|MNEMONIC usage: Deletes the DSU entries for the given DATE or MNEMONIC long_desc: | Deletes the DSU entries for the given DATE or MNEMONIC. %{date_option_description} %{mnemonic_option_description} dates: desc: dates|dd OPTIONS usage: Deletes the DSU entries for the OPTIONS provided long_desc: | Deletes the DSU entries for the given OPTIONS. $ dsu delete dates OPTIONS $ dsu d dd OPTIONS OPTIONS: -f|--from DATE|MNEMONIC: The DATE or MNEMONIC that represents the start of the range of DSU dates to delete. If a relative mnemonic is used (+/-n, e.g +1, -1, etc.), the date calculated will be relative to the current date (e.g. `.to_i.days.from_now(Time.now)`). -t|--to DATE|MNEMONIC: The DATE or MNEMONIC that represents the end of the range of DSU dates to delete. If a relative mnemonic is used (+/-n, e.g +1, -1, etc.), the date calculated will be relative to the date that resulting from the `--from` option date calculation. %{date_option_description} %{mnemonic_option_description} EXAMPLES: NOTE: All examples can substitute their respective short form options (e.g. `-f`, `-t`, etc. for `--from`, `--to`, etc.). The below will delete the DSU entries for the range of dates from 1/1 to 1/4 for the current year: $ dsu delete dates --from 1/1 --to +3 This will delete the DSU entries for the range of dates from 1/2 to 1/5 for the year 2022: $ dsu delete dates --from 1/5/2022 --to -3 This (assuming "today" is 1/10) will delete the DSU entries for the last week 1/10 to 1/3 of the current year: $ dsu delete dates --from today --to -7 This (assuming "today" is 5/23) will delete the DSU entries for the last week 5/16 to 5/22. This example simply illustrates the fact that you can use relative mnemonics for both `--from` and `--to` options; this doesn't mean you should do so... While you can use relative mnemonics for both `--from` and `--to` options, there is always a more intuitive way. The below example basically deletes one week of DSU entries back 1 week from yesterday's date: $ dsu delete dates --from -7 --to +6 The above can be accomplished MUCH easier by simply using the `yesterday` mnemonic... This (assuming "today" is 5/23) will delete the DSU entries back 1 week from yesterday's date 5/16 to 5/22: $ dsu delete dates --from yesterday --to -6 today: desc: today|n usage: Deletes the DSU entries for today long_desc: | Deletes the DSU entries for today. $ dsu delete today $ dsu delete n tomorrow: desc: tomorrow|t usage: Deletes the DSU entries for tomorrow long_desc: | Deletes the DSU entries for tomorrow. $ dsu delete tomorrow $ dsu delete t yesterday: desc: yesterday|y usage: Deletes the DSU entries for yesterday long_desc: | Deletes the DSU entries for yesterday. $ dsu delete yesterday $ dsu delete y messages: deleted: Deleted %{count} entry group(s). cancelled: Cancelled. prompts: are_you_sure: Are you sure you want to delete all the entries for %{dates} (%{count} entry groups)? edit: date: desc: date|d DATE usage: Edits the DSU entries for DATE long_desc: | Edits the DSU entries for DATE. %{date_option_description} today: desc: today|n usage: Edits the DSU entries for today long_desc: | Edits the DSU entries for today. tomorrow: desc: tomorrow|t usage: Edits the DSU entries for tomorrow long_desc: | Edits the DSU entries for tomorrow. yesterday: desc: yesterday|y usage: Edits the DSU entries for yesterday long_desc: | Edits the DSU entries for yesterday. export: dates: desc: dates|dd OPTIONS usage: Exports the DSU entries for the OPTIONS provided long_desc: | Exports the DSU entries for the given OPTIONS. $ dsu export dates OPTIONS $ dsu x dd OPTIONS OPTIONS: -f|--from DATE|MNEMONIC: The DATE or MNEMONIC that represents the start of the range of DSU dates to export. If a relative mnemonic is used (+/-n, e.g +1, -1, etc.), the date calculated will be relative to the current date (e.g. `.to_i.days.from_now(Time.now)`). -t|--to DATE|MNEMONIC: The DATE or MNEMONIC that represents the end of the range of DSU dates to export. If a relative mnemonic is used (+/-n, e.g +1, -1, etc.), the date calculated will be relative to the date that resulting from the `--from` option date calculation. %{date_option_description} %{mnemonic_option_description} EXAMPLES: NOTE: All examples can substitute their respective short form options (e.g. `-f`, `-t`, etc. for `--from`, `--to`, etc.). The below will export the DSU entries for the range of dates from 1/1 to 1/4 for the current year: $ dsu export dates --from 1/1 --to +3 This will export the DSU entries for the range of dates from 1/2 to 1/5 for the year 2022: $ dsu x dd --from 1/5/2022 --to -3 This (assuming "today" is 1/10) will export the DSU entries for the last week 1/10 to 1/3 of the current year: $ dsu export dates --from today --to -7 This (assuming "today" is 5/23) will export the DSU entries for the last week 5/16 to 5/22. This example simply illustrates the fact that you can use relative mnemonics for both `--from` and `--to` options; this doesn't mean you should do so... While you can use relative mnemonics for both `--from` and `--to` options, there is always a more intuitive way. The below example basically exports one week of DSU entries back 1 week from yesterday's date: $ dsu export dates --from -7 --to +6 The above can be accomplished MUCH easier by simply using the `yesterday` mnemonic... This (assuming "today" is 5/23) will delete the DSU entries back 1 week from yesterday's date 5/16 to 5/22: $ dsu x dd --from yesterday --to -6 all: desc: all|a usage: Exports all DSU entries long_desc: | Exports all DSU entries. $ dsu export all $ dsu x a messages: exported: Export successful. exported_to: Entry groups exported to %{file_path}. nothing_to_export: No entry groups to export. cancelled: Cancelled. prompts: export_all_confirm: Export all the entries (%{count} entry groups)? export_dates_confirm: Export all the entries for %{from} thru %{to} (%{count} entry groups)? options: - y - N import: dates: desc: dates|dd OPTIONS usage: Imports the DSU entries given the OPTIONS provided long_desc: | Imports the DSU entries for the given OPTIONS provided. $ dsu import dates OPTIONS $ dsu m dd OPTIONS OPTIONS: -i|--import-file IMPORT_CVS_FILE: The IMPORT_CVS_FILE file to import. IMPORT_CVS_FILE should be a fully qualified path to a file that was previously created as a result of running `dsu export`. see `dsu help export`. -m|--merge true|false (default: true): If true, imported entries will be added to the entry group if the entry group already exists. If false, the imported entries will replace all existing entries for the entry group if the entry group already exists. If the entry group does not exist, it will be created using the imported entries. -f|--from DATE|MNEMONIC: The DATE or MNEMONIC that represents the start of the range of DSU dates to import. If a relative mnemonic is used (+/-n, e.g +1, -1, etc.), the date calculated will be relative to the current date (e.g. `.to_i.days.from_now(Time.now)`). -t|--to DATE|MNEMONIC: The DATE or MNEMONIC that represents the end of the range of DSU dates to import. If a relative mnemonic is used (+/-n, e.g +1, -1, etc.), the date calculated will be relative to the date that resulting from the `--from` option date calculation. %{date_option_description} %{mnemonic_option_description} EXAMPLES: NOTE: All examples can substitute their respective short form options (e.g. `-f`, `-t`, etc. for `--from`, `--to`, etc.). The below will import the DSU entries for the range of dates from 1/1 to 1/4 for the current year, from the import file, and replace all the entries for the respective entry groups imported: $ dsu import dates --from 1/1 --to +3 -i /path/to/import.csv -m false This will import the DSU entries for the range of dates from 1/2 to 1/5 for the year 2022, from the import file, and merge all the entries for the respective entry groups imported: $ dsu m dd --from 1/5/2022 --to -3 -i /path/to/import.csv This (assuming "today" is 1/10) will import the DSU entries for the last week 1/10 to 1/3 of the current year, from the import file, and merge all the entries for the respective entry groups imported: $ dsu import dates --from today --to -7 -i /path/to/import.csv -m true This (assuming "today" is 5/23) will import the DSU entries for the last week 5/16 to 5/22. This example simply illustrates the fact that you can use relative mnemonics for both `--from` and `--to` options; this doesn't mean you should do so... While you can use relative mnemonics for both `--from` and `--to` options, there is always a more intuitive way. The below example basically imports one week of DSU entries back 1 week from yesterday's date, from the import file, and merge all the entries for the respective entry groups imported: $ dsu import dates --from -7 --to +6 -i /path/to/import.csv The above can be accomplished MUCH easier by simply using the `yesterday` mnemonic... This (assuming "today" is 5/23) will import the DSU entries back 1 week from yesterday's date 5/16 to 5/22, from the import file, and merge all the entries for the respective entry groups imported: $ dsu m dd --from yesterday --to -6 -i /path/to/import.csv all: desc: all|a OPTIONS usage: Imports all DSU entries from a given DSU export .csv file long_desc: | Imports all DSU entries from a given DSU export .csv file. $ dsu import all OPTIONS $ dsu m a OPTIONS OPTIONS: -i|--import-file IMPORT_CVS_FILE: The IMPORT_CVS_FILE file to import. IMPORT_CVS_FILE should be a fully qualified path to a file that was previously created as a result of running `dsu export`. see `dsu help export`. -m|--merge true|false (default: true): If true, imported entries will be added to the entry group if the entry group already exists. If false, the imported entries will replace all existing entries for the entry group if the entry group already exists. If the entry group does not exist, it will be created using the imported entries. EXAMPLES: This will import all the DSU entries from the import file, and replace all the entries for the respective entry groups imported: $ dsu import all -i /path/to/import.csv -m false This will import all the DSU entries from the import file, and merge all the entries for the respective entry groups imported: $ dsu import all -i /path/to/import.csv messages: import_success: Entry group for %{date} imported successfully. import_error: "Entry group for %{date} imported with an error: %{error}." nothing_to_import: No entry groups to import. cancelled: Cancelled. file_not_exist: Import file %{file_path} does not exist. prompts: import_all_confirm: Import all entry groups (%{count} entry groups)? import_dates_confirm: Import all the entry groups for %{from} thru %{to} (%{count} entry groups)? options: - y - N list: date: desc: date|d DATE|MNEMONIC usage: Displays the DSU entries for the given DATE or MNEMONIC long_desc: | Displays the DSU entries for the given DATE or MNEMONIC. %{date_option_description} %{mnemonic_option_description} dates: desc: dates|dd OPTIONS usage: Displays the DSU entries for the OPTIONS provided long_desc: | Displays the DSU entries for the given OPTIONS. $ dsu list dates OPTIONS $ dsu l dd OPTIONS OPTIONS: -a|--include-all true|false: If true, all DSU dates within the specified range will be displayed. If false, DSU dates between the first and last DSU dates that have NO entries will NOT be displayed.. The default is taken from the dsu configuration setting :include_all, see `dsu config info`. -f|--from DATE|MNEMONIC: The DATE or MNEMONIC that represents the start of the range of DSU dates to display. If a relative mnemonic is used (+/-n, e.g +1, -1, etc.), the date calculated will be relative to the current date (e.g. `.to_i.days.from_now(Time.now)`). -t|--to DATE|MNEMONIC: The DATE or MNEMONIC that represents the end of the range of DSU dates to display. If a relative mnemonic is used (+/-n, e.g +1, -1, etc.), the date calculated will be relative to the date that resulting from the `--from` option date calculation. %{date_option_description} %{mnemonic_option_description} EXAMPLES: NOTE: All example results are subject to the `--include-all|-a` option. NOTE: All examples can substitute their respective short form options (e.g. `-f`, `-t`, etc. for `--from`, `--to`, etc.). The below will display the DSU entries for the range of dates from 1/1 to 1/4 for the current year: $ dsu list dates --from 1/1 --to +3 This will display the DSU entries for the range of dates from 1/2 to 1/5 for the year 2022: $ dsu list dates --from 1/5/2022 --to -3 This (assuming "today" is 1/10) will display the DSU entries for the last week 1/10 to 1/3 of the current year: $ dsu list dates --from today --to -7 This (assuming "today" is 5/23) will display the DSU entries for the last week 5/16 to 5/22. This example simply illustrates the fact that you can use relative mnemonics for both `--from` and `--to` options; this doesn't mean you should do so... While you can use relative mnemonics for both `--from` and `--to` options, there is always a more intuitive way. The below example basically lists one week of DSU entries back 1 week from yesterday's date: $ dsu list dates --from -7 --to +6 The above can be accomplished MUCH easier by simply using the `yesterday` mnemonic... This (assuming "today" is 5/23) will display the DSU entries back 1 week from yesterday's date 5/16 to 5/22: $ dsu list dates --from yesterday --to -6 today: desc: today|n usage: Displays the DSU entries for today long_desc: | Displays the DSU entries for today. $ dsu list today $ dsu list n tomorrow: desc: tomorrow|t usage: Displays the DSU entries for tomorrow long_desc: | Displays the DSU entries for tomorrow. $ dsu list tomorrow $ dsu list t yesterday: desc: yesterday|y usage: Displays the DSU entries for yesterday long_desc: | Displays the DSU entries for yesterday. $ dsu list yesterday $ dsu list y theme: create: desc: create THEME_NAME [OPTIONS] usage: Creates a dsu color theme named THEME_NAME long_desc: | Creates a dsu color theme named THEME_NAME in the %{themes_folder} folder. $ dsu create THEME_NAME [-d|--description DESCRIPTION] OPTIONS: -d|--description DESCRIPTION: Creates the dsu color theme with having DESCRIPTION as the color theme description. DESCRIPTION Must be be between 2 and 256 characters (inclusive) in length. prompts: create_theme: Create color theme "%{theme_name}"? errors: already_exists: Color theme "%{theme_name}" already exists. messages: created: Created color theme "%{theme_name}". cancelled: Cancelled. delete: desc: delete THEME_NAME usage: Deletes the existing dsu color theme THEME_NAME long_desc: | Deletes the existing dsu color theme THEME_NAME in the %{themes_folder} folder. $ dsu theme delete THEME_NAME prompts: delete_theme: Delete color theme "%{theme_name}"? errors: cannot_delete: Color theme "%{theme_name}" cannot be deleted. messages: cancelled: Cancelled. deleted: Deleted color theme "%{theme_name}". list: desc: list usage: Lists the available dsu color themes. long_desc: | Lists the available dsu color themes in the %{themes_folder} folder. $ dsu theme list use: desc: use [THEME_NAME] usage: Sets the dsu color theme to THEME_NAME long_desc: | Sets the dsu color theme to THEME_NAME. $ dsu theme use [THEME_NAME] NOTES If THEME_NAME is not provided, the default theme will be used. If THEME_NAME does not exist, you will be given the option to create a new theme. messages: using_color_theme: Using color theme "%{theme_name}". show: desc: show THEME_NAME usage: Displays the dsu color theme THEME_NAME long_desc: | Displays the dsu color theme THEME_NAME. $ dsu theme show THEME_NAME generic: color_theme: "%{theme_name} color theme" errors: does_not_exist: Color theme "%{theme_name}" does not exist.