View on GitHub

tp

If you want to start taking charge of your fridge and stop wasting your food, Fridget is for you.

User Guide


Introduction

image info

Fridget is a desktop app built to be used via Command Line Interface (CLI). Fridget is an easier way for you to keep track of the items in your fridge. It makes it convenient for you to add, remove, and find items stored in your fridge. Fridget also reminds you when items are nearing expiry.

image info

Who Is Fridget Meant For?

If you want to start taking charge of your fridge and stop wasting your food, Fridget is for you.

Use Fridget today.

Purpose Of This Guide

This guide is meant for you to quickly get started with Fridget, so you can stop worrying about expired food and start enjoying life.

You can use the Index below to navigate through different sections in the user guide.

Do start at the Legend to get an overview of the icons and terminology we use throughout the document.

If you want to immediately get started with Fridget, just follow the instructions in the Quick Start section. Afterwards, take a look at the Features section to learn about all that you can do with Fridget.

We highly recommend you to refer to the Command Syntax and Things To Note for a better understanding of the properties underlying Fridget and its features.


Index

  1. Legend
  2. Quick Start
  3. Features
  4. Command Syntax
  5. Things to Note

Legend

add ITEM_NAME /EXPIRY_DATE - Texts inside boxes like this refers to either input text by the user or output from Fridget in the terminal. It could also refer to file names like Fridget.jar.

ITEM_NAME or EXPIRY_DATE - Texts which have been capitalized refer to parameters which the user should type in. For example:

A command like add ITEM_NAME /EXPIRY_DATE would actually be typed by the user as add burger /2021-11-11.

:bulb: - This icon refers to tips that can help you make the most out of Fridget.

:exclamation: - This icon refers to warnings to help you avoid mistakes when using Fridget.


Quick Start

  1. Ensure that you have Java 11 or above installed on your computer.
  2. Download the latest Fridget.jar from here.
  3. Copy the file into the folder you want to store Fridget’s data.
  4. Launch the terminal in that same folder on your computer. You can refer to this website on how to launch the terminal on your specific OS (Windows/Mac/Linux).
  5. Type in java -jar Fridget.jar into the terminal to launch the app.
  6. Type your command in the command box and press Enter to execute it.
    • Some example commands you can try:
      • help: lists all commands and input format.
      • reset: prompts the user for confirmation to clear all data.
      • exit: closes the app.
  7. Congratulations! You should be good to go!

:bulb: You can type java -version into your terminal to check your version of java.

This guide has been arranged according to the features offered by Fridget. You can see the list of features in the Features section below.


Features

Feature Command Format
Add an item add ITEM_NAME /EXPIRY_DATE
Remove an item remove ITEM_NAME
Update the quantity of an item update ITEM_NAME
Get help help
Reset item list reset
Reset shopping list shopreset
List all items list -OPTIONAL_SORT_TYPE
List items in shopping list shoplist
Find an item find KEYWORD
List expiring items expiring
See notifications notifs
Exit Fridget exit

Command Syntax

As you use this guide, you may see some commands with specific punctuation or parameters. This guide explains what they mean, and how you should use them.

For simplicity’s sake, the number 2147483647 shall be referred to henceforth as INT_MAX.

Command Option Description
ITEM_NAME The ITEM_NAME can be any series of characters or digits of less than length INT_MAX. Additionally, ITEM_NAME should not include the following terms: ;,/, or |.

More explanation can be found here.
EXPIRY_DATE The EXPIRY_DATE must be of the format YYYY-MM-DD.
OPTIONAL_SORT_TYPE We recommend that you insert a - before OPTIONAL_SORT_TYPE. However, we do accommodate inputs without a - in front. Additionally, we also accept uppercase inputs.
KEYWORD This KEYWORD can be the exact same as the name of the item you are trying to remove. You can also input a KEYWORD that is contained within the item you are trying to remove.
Y|N Some commands may prompt you to type a Y to signify that you would like to proceed with the command. Do take note that these commands will also take y as consent.

Add an item into Fridget: add

Use this command if you want to add your items into Fridget.

Format: add ITEM_NAME /EXPIRY_DATE

Steps:

  1. Type the item you want to add in the following format: add ITEM_NAME /EXPIRY_DATE.
  2. Fridget will prompt you for the quantity of the item that you want to add. You can feel free to type in the quantity you prefer. This is illustrated in Figure 1.1
  3. Do ensure that this quantity is less than INT_MAX. The value forINT_MAX can be found in the Command Syntax.

Constraints:

:exclamation: The EXPIRY_DATE must be in the YYYY-MM-DD format.

:exclamation: The EXPIRY_DATE should not be earlier than the current day.

Example of usage:

If you are adding an item not in Fridget:

Figure 1.1

USER INPUT: add burger /2021-11-11
__________________________________________
What quantity of [burger | 2021-11-11] would you like to add?
__________________________________________
USER INPUT: 1
__________________________________________
You have successfully added:
    burger | Qty: 1 | 11 Nov 2021
__________________________________________

If you are adding an item already in Fridget:

Figure 1.2

USER INPUT: add burger /2021-11-11
__________________________________________
What quantity of [burger | 2021-11-11] would you like to add?
__________________________________________
USER INPUT: 9
__________________________________________
You have successfully increased the quantity of:
    burger | Qty: 1->10 | 11 Nov 2021
__________________________________________


:bulb: For advanced users

If you want to add multiple items at the same time, separate each item with a semicolon: ;.

For example:

Figure 1.3

USER INPUT: add burger /2021-11-11; chicken /2023-11-11
__________________________________________
What quantity of [burger | 2021-11-11] would you like to add?
__________________________________________
USER INPUT: 1
__________________________________________
You have successfully increased the quantity of:
    burger | Qty: 10->11 | 11 Nov 2021
__________________________________________
What quantity of [chicken | 2023-11-11] would you like to add?
__________________________________________
USER INPUT: 1
__________________________________________
You have successfully added:
    chicken | Qty: 1 | 11 Nov 2023
__________________________________________

Remove an item from Fridget: remove

Use this command if you want to remove items from Fridget.

Format: remove ITEM_NAME

Steps:

  1. Type the item you want to remove in the following format: remove ITEM_NAME.
  2. If there are multiple items with similar names, Fridget will prompt you to pick one by number. Do pick the number that is beside your item of choice. This is illustrated in the Figure 2.3 below.
  3. Afterwards, if there is more than 1 of your chosen item, Fridget will prompt you for the quantity of the item that you want to remove. You can feel free to type in the quantity you prefer. This is illustrated in Figure 2.2 below.

:exclamation: The ITEM_NAME should be the same as the name of the item you are trying to remove.

:exclamation: The ITEM_NAME can also be a part of the name of the item.

Example of usage:

If there is only one item that exactly matches your ITEM_NAME:

Figure 2.1

USER INPUT: remove burger
__________________________________________
There are 11 items, how many would like to remove?
__________________________________________
USER INPUT: 1
__________________________________________
You have successfully removed:
    burger | Qty: 1 | 11 Nov 2021
__________________________________________

If there is only one item with a similar spelling (different capitalization / has more letters) to your ITEM_NAME:

Figure 2.2

USER INPUT: remove Burger
__________________________________________
Did you mean: burger? [Y/N]
__________________________________________
USER INPUT: y
__________________________________________
There are 10 items, how many would like to remove?
__________________________________________
USER INPUT: 1
__________________________________________
You have successfully removed:
burger | Qty: 1 | 11 Nov 2021
__________________________________________

If there are multiple items with similar names to your ITEM_NAME:

Figure 2.3

USER INPUT: remove burger
__________________________________________
Which item would you like to be removed? Type the index of the item below.
    1. burger | Qty: 1 | 11 Nov 2021
    2. burger | Qty: 1 | 23 Sep 2021
    3. burger a | Qty: 2 | 23 Sep 2022
__________________________________________
USER INPUT: 1
__________________________________________
You have successfully removed:
    burger | Qty: 1 | 11 Nov 2021
__________________________________________

If you remove an item, and there are no items left with the same name in Fridget:

:bulb: Our shopping list will prompt you to add depleted items to your shopping list.

Figure 2.4

USER INPUT: remove burger
__________________________________________
You have successfully removed:
    burger | Qty: 1 | 23 Sep 2021
__________________________________________
You have ran out of burger. Would you like to add it to your shopping list? (Y/N)
__________________________________________
USER INPUT: Y
__________________________________________
How many items would you like to buy?
__________________________________________
USER INPUT: 1
__________________________________________
You have successfully added:
    burger | Qty: 1
__________________________________________

Update the quantity of an item in Fridget: update

Use this command if you want to update the quantity of items currently in Fridget.

Format: update ITEM_NAME

Steps:

  1. Type the item you want to update in the following format: update ITEM_NAME.
  2. If there are multiple items with similar names, Fridget will prompt you to pick one by number. Do pick the number that is beside your item of choice. This is illustrated in Figure 3.3 below.
  3. Fridget will prompt you for the quantity of the item that you want to update. You can feel free to type in the quantity you prefer. This is illustrated in Figure 3.1 below.
  4. Do ensure that this quantity is less than INT_MAX. The value forINT_MAX can be found in the Command Syntax.

:exclamation: The ITEM_NAME should be the same as the name of the item you are trying to remove.

:exclamation: The ITEM_NAME can also be a part of the name of the item.

Example of usage:

If there is only one item that exactly matches your ITEM_NAME::

Figure 3.1

USER INPUT: update burger
__________________________________________
How many of burger do you have left?
__________________________________________
USER INPUT: 5
__________________________________________
Quantity of burger is now 5.
__________________________________________

If there is only one item with a similar spelling (different capitalization / has more letters) to your ITEM_NAME::

Figure 3.2

USER INPUT: update Burger
__________________________________________
Did you mean: burger? [Y/N]
__________________________________________
USER INPUT: Y
__________________________________________
How many of burger do you have left?
__________________________________________
USER INPUT: 8
__________________________________________
Quantity of burger is now 8.
__________________________________________

If there are multiple items with similar names to your ITEM_NAME:

Figure 3.3

USER INPUT: update burger
__________________________________________
Which item would you like to overwrite quantity? Type the index of the item below.
1. cheese burger | Qty: 8 | 11 Nov 2022
2. fish burger | Qty: 80 | 12 Dec 2022
3. fish burger | Qty: 30 | 13 Dec 2023
If you've changed your mind, simply type 'quit'.
__________________________________________
USER INPUT: 2
__________________________________________
How many of fish burger do you have left?
__________________________________________
USER INPUT: 32
__________________________________________
Quantity of burger is now 32.
__________________________________________

If you choose to update the quantity of an item to zero:

:bulb: Fridget will prompt you to check if you meant to completely remove the item.

:bulb: Fridget will further prompt you to add depleted items to your shopping list.

Figure 3.4

USER INPUT: update burger
__________________________________________
How many of burger do you have left?
__________________________________________
USER INPUT: 0
__________________________________________
You have input "0". This will remove all 32 burger from your list. 
Do you still wish to proceed? [Y/N]
__________________________________________
USER INPUT: Y
__________________________________________
You have successfully removed:
    burger | Qty: 32 | 12 Dec 2022
__________________________________________
You have ran out of burger. Would you like to add it to your shopping list? (Y/N)
__________________________________________
USER INPUT: Y
__________________________________________
How many items would you like to buy?
__________________________________________
USER INPUT: 2
__________________________________________
You have successfully added:
    burger | Qty: 2
__________________________________________

Get help: help

Use this command if you want to see the list of commands from within Fridget.

Format: help

Steps:

  1. Type help. A list of commands will be shown.

Example of usage:

Figure 4.1

USER INPUT: help
__________________________________________
List of commands available:

add ITEM_NAME /EXPIRY_DATE(format: yyyy-mm-dd) [eg. add bacon /2022-11-11]
-> Adds an item and its expiry date to the item list. Input quantity after being prompt.

find KEYWORD [eg. find bacon]
-> Find and print all item associated with keyword.

remove ITEM_NAME [eg. delete bacon]
-> Removes the item from the item list.

list -e
-> List out all the items starting with earliest expiry date.

list -r
-> List out all the items based on the order added.

list
-> List out all the items in alphabetical order.

shoplist
-> List out all the items in the shopping list in alphabetical order.

expiring
-> Prints out items that have expired or are expiring within a week.

update ITEM_NAME [eg. update egg]
-> Prompts a quantity change for the specified item name.

notifs
-> Toggle the notification on or off depending on previous state. Default mode is on.

reset
-> Deletes all the previous item entries from the reader.

shopreset
-> Deletes all the previous item entries in the shopping list.

exit
-> Exits the program.

For more information about each command please visit our User Guide.
Link: https://ay2122s1-cs2113t-w12-4.github.io/tp/UserGuide.html
__________________________________________

Reset all items: reset

Use this command if you want to reset all the items in your fridge.

Format: reset

Steps:

  1. Type reset. Fridget will prompt you to confirm that you want to reset all the items in your fridge.
  2. Type Y if you want to reset everything. Type N if you would like to abort.

Example of usage:

If you decide to not reset in the end:

Figure 5.1

USER INPUT: reset
__________________________________________
Are you sure you want to reset everything in the fridge? (Y/N)
__________________________________________
USER INPUT: N
__________________________________________
Shutting down the command...
__________________________________________

If you are sure you want to reset:

Figure 5.2

USER INPUT: reset
__________________________________________
Are you sure you want to reset everything in the fridge? (Y/N)
__________________________________________
USER INPUT: Y
__________________________________________
Item list has been reset successfully.
__________________________________________

Reset all items in shopping list: shopreset

Use this command if you want to reset all the items in your shopping list.

Format: shopreset

Steps:

  1. Type shopreset. Fridget will prompt you to confirm that you want to reset all the items in your shopping list.
  2. Type Y if you want to reset everything. Type N if you would like to abort.

Example of usage:

If you decide to not reset in the end:

Figure 6.1

USER INPUT: shopreset
__________________________________________
Are you sure you want to reset everything in the shopping list? (Y/N)
__________________________________________
USER INPUT: N
__________________________________________
Shutting down the command...
__________________________________________

If you are sure you want to reset:

Figure 6.2

USER INPUT: shopreset
__________________________________________
Are you sure you want to reset everything in the shopping list? (Y/N)
__________________________________________
USER INPUT: Y
__________________________________________
Shopping list has been reset successfully.
__________________________________________

List all items in Fridget: list

Use this command if you want to list all items in Fridget, in the order that you prefer.

Format: list -OPTIONAL_SORT_TYPE

Steps:

  1. Type list to list all items in Fridget. You can optionally choose to add an ` -OPTIONAL_SORT_TYPE` to decide how the list should be sorted. More details can be found below.

Example of usage:

If you want to list items in alphabetical order:

Figure 7.1

USER INPUT: list
__________________________________________
List sorted by item name:
    1. fish Cake | Qty: 2 | 12 Dec 2020
    2. frozen duck | Qty: 1 | 10 Oct 2022
    3. Yoghurt cake | Qty: 1 | 15 Oct 2021
__________________________________________

If you want to list items in ascending order of expiry dates:

Figure 7.2

USER INPUT: list -e
__________________________________________
List sorted by expiry date:
    1. fish Cake | Qty: 2 | 12 Dec 2020
    2. Yoghurt cake | Qty: 1 | 15 Oct 2021
    3. frozen duck | Qty: 1 | 10 Oct 2022
__________________________________________

If you want to list items in order of how recently they were added:

Figure 7.3

USER INPUT: list -r
__________________________________________
List sorted by earliest added:
    1. fish Cake | Qty: 2 | 12 Dec 2020
    2. Yoghurt cake | Qty: 1 | 15 Oct 2021
    3. frozen duck | Qty: 1 | 10 Oct 2022
__________________________________________

List items in shopping list: shoplist

Use this command if you want to list all the items in your shopping list.

Format: shoplist

Steps:

  1. Type shoplist to list all items in your shopping list.

Example of usage:

Figure 8.1

USER INPUT: shoplist
__________________________________________
List sorted by item name:
    1. Burger | Qty: 1
    2. Chicken | Qty: 3
    3. Fish | Qty: 2
__________________________________________

Find items stored in Fridget: find

Use this command if you want to easily find an item in Fridget by name.

Format: find KEYWORD

Steps:

  1. Type find KEYWORD into Fridget to get all item(s) in Fridget that match your chosen KEYWORD.

:exclamation: The KEYWORD should be the same as the name of the item you are trying to remove.

:exclamation: The KEYWORD can also be a part of the name of the item.

Example of usage:

Figure 9.1

USER INPUT: find burger
__________________________________________
These are the matching items:
    1. burger | Qty: 1 | 23 Sep 2030
__________________________________________
USER INPUT: find apple
__________________________________________
No matching item found!
__________________________________________

List all items expiring soon: expiring

Use this command if you want to get a list of all expiring or expired items in Fridget.

:bulb: Only items expiring within 7 days will be shown. Expired items will be shown too.

Format: expiring

Steps:

  1. Type expiring. Fridget will display a list of all expiring or expired items.

Example of usage:

Figure 10.1

USER INPUT: expiring
__________________________________________
Expiring/Expired Items:
    1. fish Cake | Qty: 2 | 12 Dec 2020
    2. Yoghurt cake | Qty: 1 | 15 Oct 2021
__________________________________________

See notifications: notifs

Use this command if you want to toggle notifications on or off. There are a total of 2 reminders, health and expiry.

:bulb: Notifications are scheduled by default to be displayed every 4 hours, if turned on.

Format: notifs

Steps:

  1. Type notifs. This will toggle the notifications in Fridget on or off. Fridget will display the current status of the notifications after your command.

Example of usage:

Figure 11.1

USER INPUT: notifs
__________________________________________
Turning notification off!
__________________________________________
USER INPUT: notifs
__________________________________________
Turning notification on!
__________________________________________

Example of health reminder notice:

Figure 11.2

 ___________________________________________________
|                      HEALTH!                      |
|===================================================|
|      ___            _         __        ______    |
|     / _ \___ __ _  (_)__  ___/ /__ ____/ / / /    |
|    / , _/ -_)  ' \/ / _ \/ _  / -_) __/_/_/_/     |
|   /_/|_|\__/_/_/_/_/_//_/\_,_/\__/_/ (_|_|_)      |
|   ---------------------------------------------   |
|                                                   |
|    "If you don't take time to take care of your   |
|    health now, you're gonna have to make time     |
|    for feeling sick and tired later."             |
|                                                   |
|            Always remember to eat more            |
|              Fruits and Vegetables!               |
|___________________________________________________|

Example of expiry reminder notice:

Figure 11.3

__________________________________________
 ___________________________________________________
|                      EXPIRY!                      |
|===================================================|
|      ___            _         __        ______    |
|     / _ \___ __ _  (_)__  ___/ /__ ____/ / / /    |
|    / , _/ -_)  ' \/ / _ \/ _  / -_) __/_/_/_/     |
|   /_/|_|\__/_/_/_/_/_//_/\_,_/\__/_/ (_|_|_)      |
|___________________________________________________|
 >> Items expired! Please discard ASAP:
     1. apple | Qty: 1 | 01 Nov 2021
     2. chicken | Qty: 1 | 03 Nov 2021
 --------------------------------------------------- 
 >> Please use them before they expire:
     1. bacon | Qty: 1 | 11 Nov 2021
|___________________________________________________|
__________________________________________

Stop Fridget: exit

Use this command when you are done using Fridget. Fridget will help you to remember everything you did.

Steps:

  1. Type exit. Fridget will display a shutdown message and save all data from your current session. You can see the above-mentioned in Figure 12.1

Format: exit

Example of usage:

Figure 12.1

USER INPUT: exit
__________________________________________
We'll help you remember everything you told us :)
See you again!~~
__________________________________________

Things to Note

:bulb: Details about how the shopping list works


:bulb: For commands help, expiring, reset, shopreset, shoplist, list, and notifs, adding a space and random text behind will still trigger the command.

Examples:

Figure 13.1

USER INPUT: notifs ajsdfasf
__________________________________________
Turning notification off!
____________________________________________
USER INPUT: reset jadfgasgdka
__________________________________________
Are you sure you want to reset everything in the item list? (Y/N)
__________________________________________

:bulb: If no item is recorded, Fridget will prompt you to use the help command.

Figure 13.2

USER INPUT: find a
__________________________________________
You currently have nothing in your fridge.
Input "help" to get started!
__________________________________________
USER INPUT: expiring
__________________________________________
You currently have nothing in your fridge.
Input "help" to get started!
__________________________________________

:exclamation: All numerical inputs are limited between 0 to 2147483647. Numbers outside this range are invalid inputs.

This is done to reduce the memory that Fridget uses on your computer.


:exclamation: When adding multiple items, any error will invalidate the entire input. No items will be added.

This is done to ensure no incorrect items are added into Fridget accidentally. In your input is wrong, you can copy the previous input, fix the errors, and run the command again.


:exclamation: Do not tamper with the files created in the fridgetData directory.

Please feel free to read and copy the content from the files. However, do not edit the files, as this may cause the program to load erroneously. If any item is detected to be corrupted, all items following it in savedItem.txt will be removed for the user’s safety.


Thank You

We hope you found this user guide useful to help you push Fridget to its limits!

If you find any issues, do let us know here.

:bulb: You will need a GitHub account to access the above link.

All the best, and have fun!