From 678d4ff80b7ed0583907ca4c1512e3714d8c9a7c Mon Sep 17 00:00:00 2001 From: Shawn Nguru Date: Tue, 14 Jan 2025 13:27:05 -0600 Subject: [PATCH 01/11] line thirteen --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 437e760..8c5af9a 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ An exercise for collaborating with git / GitHub. Please read the directions CARE This will tell git to perform fast forwards when possible, never rebase, and create merge commits when necessary. We will not cover the differences between these in-depth in class, but feel free on your own time to research them using search engines or AI if you're interested. Explore your curiosity! ## Setup project -1. Choose one partner to be Partner A, one partner to Partner B. +1. Choose one partner to be Partner A, one partner to Partner B. (Change made) 1. Have ONLY Partner A fork this repository. PARTNER B SHOULD NOT FORK. 1. Have Partner A add Partner B as a collaborator on their fork. Follow [these directions](https://docs.github.com/en/enterprise-server@3.10/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-access-to-your-personal-repositories/inviting-collaborators-to-a-personal-repository#inviting-a-collaborator-to-a-personal-repository). 1. Have the Partner A send the URL of their repository to Partner B. From 96b47af78f9dff3b283618b279c72c251b40e9a2 Mon Sep 17 00:00:00 2001 From: X BELL <194058603+bellxalli@users.noreply.github.com> Date: Tue, 14 Jan 2025 11:33:05 -0800 Subject: [PATCH 02/11] Test changes made --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 437e760..1e72fee 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ We will first practice making changes that do not trigger a merge conflict. In g ``` git pull ``` - 1. Make any change to the README and save it. + 1. Make any change to the README and save it. (Changes) 1. Check that the change shows up in red (shows as unstaged) when asking for the status. ``` git status From 48c0a278c6b5cca60f1923ff7f80f135133dc8f8 Mon Sep 17 00:00:00 2001 From: Shawn Nguru Date: Tue, 14 Jan 2025 13:48:25 -0600 Subject: [PATCH 03/11] I lied but this time it works! --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 8c5af9a..202ba90 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ An exercise for collaborating with git / GitHub. Please read the directions CARE ``` This will tell git to perform fast forwards when possible, never rebase, and create merge commits when necessary. We will not cover the differences between these in-depth in class, but feel free on your own time to research them using search engines or AI if you're interested. Explore your curiosity! -## Setup project +## Setup project (PLEASE WORK!) 1. Choose one partner to be Partner A, one partner to Partner B. (Change made) 1. Have ONLY Partner A fork this repository. PARTNER B SHOULD NOT FORK. 1. Have Partner A add Partner B as a collaborator on their fork. Follow [these directions](https://docs.github.com/en/enterprise-server@3.10/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-access-to-your-personal-repositories/inviting-collaborators-to-a-personal-repository#inviting-a-collaborator-to-a-personal-repository). From 36c2e3c230958854ad3340882da3cee08c54ecc7 Mon Sep 17 00:00:00 2001 From: Shawn Nguru Date: Tue, 14 Jan 2025 13:53:53 -0600 Subject: [PATCH 04/11] Change made --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 202ba90..ce46db6 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ An exercise for collaborating with git / GitHub. Please read the directions CARE ``` This will tell git to perform fast forwards when possible, never rebase, and create merge commits when necessary. We will not cover the differences between these in-depth in class, but feel free on your own time to research them using search engines or AI if you're interested. Explore your curiosity! -## Setup project (PLEASE WORK!) +## Setup project (PLEASE WORK!)(Another Change) 1. Choose one partner to be Partner A, one partner to Partner B. (Change made) 1. Have ONLY Partner A fork this repository. PARTNER B SHOULD NOT FORK. 1. Have Partner A add Partner B as a collaborator on their fork. Follow [these directions](https://docs.github.com/en/enterprise-server@3.10/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-access-to-your-personal-repositories/inviting-collaborators-to-a-personal-repository#inviting-a-collaborator-to-a-personal-repository). From 64ba51034e2bb2f364c7bdf3d446c690a8d6fe20 Mon Sep 17 00:00:00 2001 From: X BELL <194058603+bellxalli@users.noreply.github.com> Date: Tue, 14 Jan 2025 12:02:01 -0800 Subject: [PATCH 05/11] More Changes --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 70c1dd6..8537aa4 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ An exercise for collaborating with git / GitHub. Please read the directions CARE ``` This will tell git to perform fast forwards when possible, never rebase, and create merge commits when necessary. We will not cover the differences between these in-depth in class, but feel free on your own time to research them using search engines or AI if you're interested. Explore your curiosity! -## Setup project (PLEASE WORK!)(Another Change) +## Setup project (Another Change) 1. Choose one partner to be Partner A, one partner to Partner B. (Change made) 1. Have ONLY Partner A fork this repository. PARTNER B SHOULD NOT FORK. 1. Have Partner A add Partner B as a collaborator on their fork. Follow [these directions](https://docs.github.com/en/enterprise-server@3.10/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-access-to-your-personal-repositories/inviting-collaborators-to-a-personal-repository#inviting-a-collaborator-to-a-personal-repository). From 7abff8632b9f9b3a628bb3f929044c961fe20298 Mon Sep 17 00:00:00 2001 From: X BELL <194058603+bellxalli@users.noreply.github.com> Date: Tue, 14 Jan 2025 12:04:04 -0800 Subject: [PATCH 06/11] edits made --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 8537aa4..8c5623f 100644 --- a/README.md +++ b/README.md @@ -67,7 +67,7 @@ We will now artificially trigger a merge conflict. When we follow good git pract 1. Have BOTH Partner A and Partner B edit the below line. Each person should make it say something different. ``` - EDIT THIS LINE + EDIT THIS LINE!!!!!!! ``` 1. Have BOTH Partner A and Partner B add, commit, and push the changes. You can refer to the above steps for a refresher on how to add/commit/push. One of the partners will get an error saying that their changes can't be pushed. This is OK and expected. Today we are practicing how to resolve this error. 1. Have the error partner pull the other partner's changes: From 7f776dcfe786dff812695a1410cdacc8fc5e3d85 Mon Sep 17 00:00:00 2001 From: Shawn Nguru Date: Tue, 14 Jan 2025 14:04:33 -0600 Subject: [PATCH 07/11] edited line --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8537aa4..8af19b7 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ An exercise for collaborating with git / GitHub. Please read the directions CARE ``` This will tell git to perform fast forwards when possible, never rebase, and create merge commits when necessary. We will not cover the differences between these in-depth in class, but feel free on your own time to research them using search engines or AI if you're interested. Explore your curiosity! -## Setup project (Another Change) +## Setup project (Another Change) 1. Choose one partner to be Partner A, one partner to Partner B. (Change made) 1. Have ONLY Partner A fork this repository. PARTNER B SHOULD NOT FORK. 1. Have Partner A add Partner B as a collaborator on their fork. Follow [these directions](https://docs.github.com/en/enterprise-server@3.10/account-and-profile/setting-up-and-managing-your-personal-account-on-github/managing-access-to-your-personal-repositories/inviting-collaborators-to-a-personal-repository#inviting-a-collaborator-to-a-personal-repository). @@ -67,7 +67,7 @@ We will now artificially trigger a merge conflict. When we follow good git pract 1. Have BOTH Partner A and Partner B edit the below line. Each person should make it say something different. ``` - EDIT THIS LINE + Line Edited ``` 1. Have BOTH Partner A and Partner B add, commit, and push the changes. You can refer to the above steps for a refresher on how to add/commit/push. One of the partners will get an error saying that their changes can't be pushed. This is OK and expected. Today we are practicing how to resolve this error. 1. Have the error partner pull the other partner's changes: From 62eaf4437b5b667e06eeb5ef0f4d43cbfc15a393 Mon Sep 17 00:00:00 2001 From: X BELL <194058603+bellxalli@users.noreply.github.com> Date: Tue, 14 Jan 2025 12:18:56 -0800 Subject: [PATCH 08/11] Deer File added --- src/Deer.java | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src/Deer.java diff --git a/src/Deer.java b/src/Deer.java new file mode 100644 index 0000000..a46c7b4 --- /dev/null +++ b/src/Deer.java @@ -0,0 +1,18 @@ +class Deer implements Animal +{ + public String getAnimalArt() + { + return " \\ ( )\n" + + " \\ `--(_ _)--\'\n" + + " \\ Y-Y\n" + + " \\ /@@ \\\n" + + " \\ / \\\n" + + " `--\'. \\ ,\n" + + " | `.__________/)"; + } + + public String toString() + { + return "deer"; + } +} From 1f3c5d1ddbea43eab6a615bb30b164a55d47b510 Mon Sep 17 00:00:00 2001 From: Shawn Nguru Date: Tue, 14 Jan 2025 14:20:54 -0600 Subject: [PATCH 09/11] Dog Class added --- src/Dog.java | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 src/Dog.java diff --git a/src/Dog.java b/src/Dog.java new file mode 100644 index 0000000..d35217d --- /dev/null +++ b/src/Dog.java @@ -0,0 +1,36 @@ +/** + * The Dog class represents a dog and provides its ASCII art representation. + * This class implements the Animal interface and overrides the getAnimalArt + * and toString methods. + * + * dog art sourced from https://www.asciiart.eu/animals/birds-water + */ +class Dog implements Animal { + /** + * Returns the ASCII art representation of the dog. + * + * @return A string containing the ASCII art of the dog. + */ + @Override + public String getAnimalArt() + { +//By Maija Haavisto https://www.asciiart.eu/animals/dogs + +return " \\ .\n" + + " \\ ..^____/\n" + + " `-. ___ )\n" + + " || ||\n"; + } + + /** + * Returns the name of the animal ("Dog"). + * This method overrides the toString method to return the name of the dog. + * + * @return The string "dog" representing the name of the animal. + */ + @Override + public String toString() { + return "dog"; + } + } + \ No newline at end of file From 99c943ced6d858f2d713fb1b722888562e65701a Mon Sep 17 00:00:00 2001 From: X BELL <194058603+bellxalli@users.noreply.github.com> Date: Tue, 14 Jan 2025 12:23:08 -0800 Subject: [PATCH 10/11] Deer object added to SayApp --- src/SayApp.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/SayApp.java b/src/SayApp.java index 9d3bbf7..173cfa2 100644 --- a/src/SayApp.java +++ b/src/SayApp.java @@ -76,7 +76,7 @@ public static Animal getAnimalChoice(Scanner scanner) { * @return A list of Animal objects. */ public static List animalList() { - return Arrays.asList(new Cow(), new Duck()); + return Arrays.asList(new Cow(), new Duck(), new Deer()); } /** From faed54e69c3d4c79ab3d1a7dc2ac59b17284afc9 Mon Sep 17 00:00:00 2001 From: Shawn Nguru Date: Tue, 14 Jan 2025 14:26:10 -0600 Subject: [PATCH 11/11] Dog added --- src/Dog.java | 3 ++- src/SayApp.java | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Dog.java b/src/Dog.java index d35217d..e886061 100644 --- a/src/Dog.java +++ b/src/Dog.java @@ -5,7 +5,8 @@ * * dog art sourced from https://www.asciiart.eu/animals/birds-water */ -class Dog implements Animal { +class Dog implements Animal +{ /** * Returns the ASCII art representation of the dog. * diff --git a/src/SayApp.java b/src/SayApp.java index 173cfa2..7da051a 100644 --- a/src/SayApp.java +++ b/src/SayApp.java @@ -76,7 +76,7 @@ public static Animal getAnimalChoice(Scanner scanner) { * @return A list of Animal objects. */ public static List animalList() { - return Arrays.asList(new Cow(), new Duck(), new Deer()); + return Arrays.asList(new Cow(), new Duck(), new Deer(), new Dog()); } /**