From f94ca833c7bb10d545a9f20ba3fd7cc560f50ed4 Mon Sep 17 00:00:00 2001 From: KrashKart Date: Thu, 7 Nov 2024 21:46:32 +0800 Subject: [PATCH 1/4] Modify UG to warn for redo and undo --- docs/UserGuide.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/UserGuide.md b/docs/UserGuide.md index 6c717530aa6..b3ab69bb151 100644 --- a/docs/UserGuide.md +++ b/docs/UserGuide.md @@ -143,7 +143,7 @@ Format: `edit INDEX [n/NAME] [p/PHONE] [e/EMAIL] [t/TAG]…​` * When editing tags, the existing tags of the person will be removed, i.e. adding of tags is not cumulative. * You can remove all the person’s tags by typing `t/` without specifying any tags after it. -* After editing the person, there should be no duplicate contact in the campus connect. +* After editing the person, there should be no duplicate contact in CampusConnect. * Two contacts are considered duplicates if they share the same name, email, or phone number. Examples: @@ -259,7 +259,7 @@ Format: `undo` * Reverts the state of CampusConnect to the one before the most recent command, if any. * When the oldest version of CampusConnect is reached, `undo` command will cause an exception to be thrown -* Only the command that modify the data of CampusConnect can be undone. Commands such as `list` and `find` will not be undone. +* Only commands that modify the data of CampusConnect can be undone. Commands such as `list` and `find` will not be undone. ### Redo a command: `redo` @@ -268,7 +268,7 @@ Reapplies a command that was previously undone by `undo`. Format: `redo` * Advances CampusConnect to the state it was in before the most recent `undo` command, if any. -* Only the command that modify the data of CampusConnect can be redone. Commands such as `list` and `find` will not be redone. +* Only commands that modify the data of CampusConnect can be redone. Commands such as `list` and `find` will not be redone. * Note: If a new command (excluding `redo` or `undo`) is executed after an `undo`, the redo history is cleared, and further `redo` will not be possible. ### Clearing all entries : `clear` From 6dad28fb1a4871ac85247eb29696dfea79a8f416 Mon Sep 17 00:00:00 2001 From: KrashKart Date: Thu, 7 Nov 2024 21:46:59 +0800 Subject: [PATCH 2/4] Change "campus connect" to "CampusConnect" --- src/main/java/seedu/address/logic/Logic.java | 2 +- src/main/java/seedu/address/logic/commands/AddCommand.java | 6 +++--- .../java/seedu/address/logic/commands/ClearCommand.java | 4 ++-- .../java/seedu/address/logic/commands/DeleteCommand.java | 2 +- src/main/java/seedu/address/logic/commands/EditCommand.java | 4 ++-- src/main/java/seedu/address/logic/commands/ExitCommand.java | 2 +- src/main/java/seedu/address/logic/commands/ListCommand.java | 2 +- src/main/java/seedu/address/logic/commands/RedoCommand.java | 2 +- src/main/java/seedu/address/logic/commands/UndoCommand.java | 2 +- src/main/java/seedu/address/model/CampusConnect.java | 6 +++--- src/main/java/seedu/address/model/ModelManager.java | 2 +- 11 files changed, 17 insertions(+), 17 deletions(-) diff --git a/src/main/java/seedu/address/logic/Logic.java b/src/main/java/seedu/address/logic/Logic.java index 60e9a496398..256f58e11f3 100644 --- a/src/main/java/seedu/address/logic/Logic.java +++ b/src/main/java/seedu/address/logic/Logic.java @@ -38,7 +38,7 @@ public interface Logic { ObservableList getListOfCurrentTags(); /** - * Returns the user prefs' campus connect file path. + * Returns the user prefs' CampusConnect file path. */ Path getCampusConnectFilePath(); diff --git a/src/main/java/seedu/address/logic/commands/AddCommand.java b/src/main/java/seedu/address/logic/commands/AddCommand.java index 6bd99269fb6..1f8e0658e66 100644 --- a/src/main/java/seedu/address/logic/commands/AddCommand.java +++ b/src/main/java/seedu/address/logic/commands/AddCommand.java @@ -13,13 +13,13 @@ import seedu.address.model.person.Person; /** - * Adds a person to the campus connect. + * Adds a person to CampusConnect. */ public class AddCommand extends Command { public static final String COMMAND_WORD = "add"; - public static final String MESSAGE_USAGE = COMMAND_WORD + ": Adds a person to the campus connect. " + public static final String MESSAGE_USAGE = COMMAND_WORD + ": Adds a person to CampusConnect. " + "Parameters: " + PREFIX_NAME + "NAME " + PREFIX_PHONE + "PHONE " @@ -33,7 +33,7 @@ public class AddCommand extends Command { + PREFIX_TAG + "owesMoney"; public static final String MESSAGE_SUCCESS = "New person added: %1$s"; - public static final String MESSAGE_DUPLICATE_PERSON = "This person already exists in the campus connect"; + public static final String MESSAGE_DUPLICATE_PERSON = "This person already exists in CampusConnect"; private final Person toAdd; diff --git a/src/main/java/seedu/address/logic/commands/ClearCommand.java b/src/main/java/seedu/address/logic/commands/ClearCommand.java index 62bb47378be..52bc8ddee19 100644 --- a/src/main/java/seedu/address/logic/commands/ClearCommand.java +++ b/src/main/java/seedu/address/logic/commands/ClearCommand.java @@ -6,12 +6,12 @@ import seedu.address.model.Model; /** - * Clears the campus connect. + * Clears CampusConnect */ public class ClearCommand extends Command { public static final String COMMAND_WORD = "clear"; - public static final String MESSAGE_SUCCESS = "Campus Connect has been cleared!"; + public static final String MESSAGE_SUCCESS = "CampusConnect has been cleared!"; @Override diff --git a/src/main/java/seedu/address/logic/commands/DeleteCommand.java b/src/main/java/seedu/address/logic/commands/DeleteCommand.java index 2ab7bf76f14..a4933d7e92b 100644 --- a/src/main/java/seedu/address/logic/commands/DeleteCommand.java +++ b/src/main/java/seedu/address/logic/commands/DeleteCommand.java @@ -12,7 +12,7 @@ import seedu.address.model.person.Person; /** - * Deletes a person identified using it's displayed index from the campus connect. + * Deletes a person identified using it's displayed index from CampusConnect.S */ public class DeleteCommand extends Command { diff --git a/src/main/java/seedu/address/logic/commands/EditCommand.java b/src/main/java/seedu/address/logic/commands/EditCommand.java index f600716c731..90b6d067792 100644 --- a/src/main/java/seedu/address/logic/commands/EditCommand.java +++ b/src/main/java/seedu/address/logic/commands/EditCommand.java @@ -27,7 +27,7 @@ import seedu.address.model.tag.Tag; /** - * Edits the details of an existing person in the campus connect. + * Edits the details of an existing person in the CampusConnect. */ public class EditCommand extends Command { @@ -47,7 +47,7 @@ public class EditCommand extends Command { public static final String MESSAGE_EDIT_PERSON_SUCCESS = "Edited Person: %1$s"; public static final String MESSAGE_NOT_EDITED = "At least one field to edit must be provided."; - public static final String MESSAGE_DUPLICATE_PERSON = "This person already exists in the campus connect."; + public static final String MESSAGE_DUPLICATE_PERSON = "This person already exists in CampusConnect."; private final Index index; private final EditPersonDescriptor editPersonDescriptor; diff --git a/src/main/java/seedu/address/logic/commands/ExitCommand.java b/src/main/java/seedu/address/logic/commands/ExitCommand.java index 40b065cd9ac..bd6a923c678 100644 --- a/src/main/java/seedu/address/logic/commands/ExitCommand.java +++ b/src/main/java/seedu/address/logic/commands/ExitCommand.java @@ -9,7 +9,7 @@ public class ExitCommand extends Command { public static final String COMMAND_WORD = "exit"; - public static final String MESSAGE_EXIT_ACKNOWLEDGEMENT = "Exiting Campus Connect as requested ..."; + public static final String MESSAGE_EXIT_ACKNOWLEDGEMENT = "Exiting CampusConnect as requested..."; @Override public CommandResult execute(Model model) { diff --git a/src/main/java/seedu/address/logic/commands/ListCommand.java b/src/main/java/seedu/address/logic/commands/ListCommand.java index 2467b9e58c4..37f366cebb8 100644 --- a/src/main/java/seedu/address/logic/commands/ListCommand.java +++ b/src/main/java/seedu/address/logic/commands/ListCommand.java @@ -6,7 +6,7 @@ import seedu.address.model.Model; /** - * Lists all persons in the campus connect to the user. + * Lists all persons in CampusConnect to the user. */ public class ListCommand extends Command { diff --git a/src/main/java/seedu/address/logic/commands/RedoCommand.java b/src/main/java/seedu/address/logic/commands/RedoCommand.java index 3dab623775d..e0ba25d66ac 100644 --- a/src/main/java/seedu/address/logic/commands/RedoCommand.java +++ b/src/main/java/seedu/address/logic/commands/RedoCommand.java @@ -10,7 +10,7 @@ */ public class RedoCommand extends Command { public static final String COMMAND_WORD = "redo"; - public static final String MESSAGE_SUCCESS = "Campus Connect has gone back to the future!"; + public static final String MESSAGE_SUCCESS = "CampusConnect has gone back to the future!"; @Override public CommandResult execute(Model model) throws CommandException { diff --git a/src/main/java/seedu/address/logic/commands/UndoCommand.java b/src/main/java/seedu/address/logic/commands/UndoCommand.java index baf6cae8271..8353c0db256 100644 --- a/src/main/java/seedu/address/logic/commands/UndoCommand.java +++ b/src/main/java/seedu/address/logic/commands/UndoCommand.java @@ -10,7 +10,7 @@ */ public class UndoCommand extends Command { public static final String COMMAND_WORD = "undo"; - public static final String MESSAGE_SUCCESS = "Campus Connect has recovered!"; + public static final String MESSAGE_SUCCESS = "The previous command has been undone!"; @Override public CommandResult execute(Model model) throws CommandException { diff --git a/src/main/java/seedu/address/model/CampusConnect.java b/src/main/java/seedu/address/model/CampusConnect.java index 6d3592aa950..fc1e5019b1a 100644 --- a/src/main/java/seedu/address/model/CampusConnect.java +++ b/src/main/java/seedu/address/model/CampusConnect.java @@ -125,9 +125,9 @@ public void addPerson(Person p, int ind) { /** * Replaces the given person {@code target} in the list with {@code editedPerson}. - * {@code target} must exist in the campus connect. + * {@code target} must exist in CampusConnect. * The person identity of {@code editedPerson} must not be the same as - * another existing person in the campus connect. + * another existing person in CampusConnect. */ public void setPerson(Person target, Person editedPerson) { requireNonNull(editedPerson); @@ -137,7 +137,7 @@ public void setPerson(Person target, Person editedPerson) { /** * Removes {@code key} from this {@code CampusConnect}. - * {@code key} must exist in the campus connect. + * {@code key} must exist in CampusConnect */ public void removePerson(Person key) { persons.remove(key); diff --git a/src/main/java/seedu/address/model/ModelManager.java b/src/main/java/seedu/address/model/ModelManager.java index 748fd20f670..709b017dbbe 100644 --- a/src/main/java/seedu/address/model/ModelManager.java +++ b/src/main/java/seedu/address/model/ModelManager.java @@ -36,7 +36,7 @@ public class ModelManager implements Model { public ModelManager(ReadOnlyCampusConnect campusConnect, ReadOnlyUserPrefs userPrefs) { requireAllNonNull(campusConnect, userPrefs); - logger.fine("Initializing with campus connect: " + campusConnect + " and user prefs " + userPrefs); + logger.fine("Initializing CampusConnect: " + campusConnect + " and user prefs " + userPrefs); this.campusConnect = new CampusConnect(campusConnect); this.userPrefs = new UserPrefs(userPrefs); From 933f2dec035250cf85e899306b9c8a548b2a1cb3 Mon Sep 17 00:00:00 2001 From: KrashKart Date: Thu, 7 Nov 2024 22:23:14 +0800 Subject: [PATCH 3/4] Fix headers and link to sections --- docs/UserGuide.md | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/docs/UserGuide.md b/docs/UserGuide.md index b3ab69bb151..1683fc9c26b 100644 --- a/docs/UserGuide.md +++ b/docs/UserGuide.md @@ -82,17 +82,17 @@ any traditional point-and-click management app. Action | Format, Examples :--------:|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------: **[Add](#adding-a-person-add)** | `add n/NAME p/PHONE_NUMBER e/EMAIL [t/TAG]…​`
e.g., `add n/James Ho p/91231234 e/jamesho@example.com t/friend t/classmate` -**[Clear](#clearing-all-entries--clear)** | `clear` -**[Delete](#deleting-a-person--delete)** | `delete INDEX`
e.g., `delete 3` -**[Edit](#editing-a-person--edit)** | `edit INDEX [n/NAME] [p/PHONE_NUMBER] [e/EMAIL] [t/TAG]…​`
e.g.,`edit 2 n/James Lee e/jameslee@example.com` -**[Find by contact information](#locating-persons-by-contact-information-find)** | `find PREFIX/KEYWORD [PREFIX/MORE_KEYWORDS]…​`
e.g., `find n/James t/floorball` -**[Delete tag](#deleting-a-persons-tag--deltag)** | `deltag INDEX t/KEYWORD`
e.g. `deltag 1 t/friend` -**[Add tag](#adds-tags-to-a-specific-person--addtag)** | `addtag INDEX t/KEYWORD [t/MORE_TAGS]…​`
e.g. `addtag 1 t/friend t/classmate` -**[Categorize tag](#categorizing-a-tag--cattag)** | `cattag t/TAG [t/MORE_TAGS…​] CATEGORY`
e.g. `cattag t/floorball t/mahjong activity` -**[Undo action](#undo-a-command--undo)** | `undo` +**[Clear](#clearing-all-entries-clear)** | `clear` +**[Delete](#deleting-a-person-delete)** | `delete INDEX`
e.g., `delete 3` +**[Edit](#editing-a-person-edit)** | `edit INDEX [n/NAME] [p/PHONE_NUMBER] [e/EMAIL] [t/TAG]…​`
e.g.,`edit 2 n/James Lee e/jameslee@example.com` +**[Find by contact information](#finding-persons-by-contact-information-find)** | `find PREFIX/KEYWORD [PREFIX/MORE_KEYWORDS]…​`
e.g., `find n/James t/floorball` +**[Delete tag](#deleting-a-persons-tag-deltag)** | `deltag INDEX t/KEYWORD`
e.g. `deltag 1 t/friend` +**[Add tag](#adds-tags-to-a-specific-person-addtag)** | `addtag INDEX t/KEYWORD [t/MORE_TAGS]…​`
e.g. `addtag 1 t/friend t/classmate` +**[Categorize tag](#categorizing-a-tag-cattag)** | `cattag t/TAG [t/MORE_TAGS…​] CATEGORY`
e.g. `cattag t/floorball t/mahjong activity` +**[Undo action](#undo-a-command-undo)** | `undo` **[Redo action](#redo-a-command-redo)** | `redo` -**[List](#listing-all-persons--list)** | `list` -**[Help](#viewing-help--help)** | `help` +**[List](#listing-all-persons-list)** | `list` +**[Help](#viewing-help-help)** | `help` -------------------------------------------------------------------------------------------------------------------- @@ -106,7 +106,7 @@ When clicked, this hyperlink will show the help page. Format: `help` -### Adding a person: `add` +### Adding a person : `add` Adds a person to CampusConnect. @@ -150,7 +150,7 @@ Examples: * `edit 1 p/91234567 e/johndoe@example.com` Edits the phone number and email address of the 1st person to be `91234567` and `johndoe@example.com` respectively. * `edit 2 n/Betsy Crower t/` Edits the name of the 2nd person to be `Betsy Crower` and clears all existing tags. -### Locating persons by contact information: `find` +### Finding persons by contact information : `find` Finds persons whose names, email address, contact number, or tag contain any of the given keywords. @@ -261,7 +261,7 @@ Format: `undo` * When the oldest version of CampusConnect is reached, `undo` command will cause an exception to be thrown * Only commands that modify the data of CampusConnect can be undone. Commands such as `list` and `find` will not be undone. -### Redo a command: `redo` +### Redo a command : `redo` Reapplies a command that was previously undone by `undo`. From f0df8374ff9a49dfc4509f2ce23e1e8e0c619038 Mon Sep 17 00:00:00 2001 From: KrashKart Date: Thu, 7 Nov 2024 22:23:58 +0800 Subject: [PATCH 4/4] Fix typo --- src/main/java/seedu/address/logic/commands/DeleteCommand.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/seedu/address/logic/commands/DeleteCommand.java b/src/main/java/seedu/address/logic/commands/DeleteCommand.java index a4933d7e92b..6a5bc4ea660 100644 --- a/src/main/java/seedu/address/logic/commands/DeleteCommand.java +++ b/src/main/java/seedu/address/logic/commands/DeleteCommand.java @@ -12,7 +12,7 @@ import seedu.address.model.person.Person; /** - * Deletes a person identified using it's displayed index from CampusConnect.S + * Deletes a person identified using it's displayed index from CampusConnect. */ public class DeleteCommand extends Command {