On Github chncdcksn / 01-git
For Intermediate Web
01-git.chncdcksn.com
(Press the S key to pull up my notes.)
Thai Cashew with Tofu 1. Fry tofu in a pan until it's golden brown. 2. Add cashews and veggies and fry until golden brown. 3. Add soy sauce. 4. Serve with jasmine rice.Here's your first (pretty awful) recipe. You post the recipe online and ask people to contribute suggestions. About a month later a suggestion appears in your inbox...
Your Thai Cashew with Tofu is one of the most disgusting dishes I have ever tasted. Where's the brown sugar, you f***ing donkey? With all love and respect, Chef Gordon RamsayHe does have a bit of a point. Thai food generally works off of a contrast of flavors. You update the recipe to add brown sugar to contrast the salty soy sauce.
Thai Cashew with Tofu 1. Fry tofu and brown sugar in a pan until it's golden brown. 2. Add cashews and veggies and fry until golden brown. 3. Add soy sauce. 4. Serve with jasmine rice.You, being an unexperienced chef, make the assumption he meant to add the brown sugar when you add the tofu. You updated it, and soon you get another suggestion.
You're supposed to add the brown sugar when you add the soy sauce. My gran is a better chef, and she's dead. With all love and respect, Chef Gordon RamseyNot exactly the nicest way to put it, but he has a point, it doesn't make much sense to fry something in sugary oil.
Thai Cashew with Tofu 1. Fry tofu in a pan until it's golden brown. 2. Add cashews and veggies and fry until golden brown. 3. Add soy sauce and brown sugar. 4. Serve with jasmine rice.You accept the semi-constructive criticism and update the recipe. You try it and it tastes pretty good.
Thai Cashew with Tofu 1. Fry tofu in a pan until it's golden brown. 2. Add cashews and veggies and fry until golden brown. -3. Add soy sauce. +3. Add soy sauce and brown sugar. 4. Serve with jasmine rice.With this, you can clearly see what lines are being changed. The minus sign at the front of the line means that the line is removed, and the plus sign means that a line is added (showing modified lines is not necessary since a modification can be indicated with a delete and an add in the same place).
# Thai Cashew with Tofu ## Ingredients * A half block of tofu * Coconut oil * Mixed veggies (recommended: cauliflower, broccoli, zucchini, carrots, bamboo shoots) * Soy sauce * Brown sugar * Water * Cornstarch * Bird's Eye Chili Powder ## Steps 1. Add 3 tbsp coconut oil to a pan on high heat. 2. Cut the block of tofu into 1" cubes and add to pan. Fry until golden brown. 3. Add cashews and veggies and fry until golden brown. 4. Combine 3 tbsp soy sauce, 2 tbsp brown sugar, 2 tbsp water, a pinch of cornstarch, and chili powder to taste. Add mixture to the pan. 5. Let sauce simmer with veggies for about two minutes. 6. Serve with jasmine rice.After patching the recipe a couple times with the patches people sent us, we end up with this recipe. We receive another suggestion, a bit nicer this time...
I tried adding just a little bit of lemon juice to the sauce and it turned out pretty good. It neutralized some of the saltiness of the soy sauce while keeping it's savory flavors. I've attached the patch.
# Thai Cashew with Tofu ## Ingredients * A half block of tofu * Coconut oil * Mixed veggies (recommended: cauliflower, broccoli, zucchini, carrots, bamboo shoots) * Soy sauce * Brown sugar +* Lemon Juice * Water * Cornstarch * Bird's Eye Chili Powder ## Steps 1. Add 3 tbsp coconut oil to a pan on high heat. 2. Cut the block of tofu into 1" cubes and add to pan. Fry until golden brown. 3. Add cashews and veggies and fry until golden brown. -4. Combine 3 tbsp soy sauce, 2 tbsp brown sugar, 2 tbsp water, - a pinch of cornstarch, and chili powder to taste. Add - mixture to the pan. +4. Combine 3 tbsp soy sauce, 2 tbsp brown sugar, 1 tbsp lemon + juice, 2 tbsp water, a pinch of cornstarch, and chili + powder to taste. Add mixture to the pan. 5. Let sauce simmer with veggies for about two minutes. 6. Serve with jasmine rice.So you notice an issue with the patch system you are using. The patch is bigger than the recipe, but it doesn't have to be. You don't have to include all the lines that haven't been changed. So, you make a few changes to diff, and...
@@ -8,2 +8,3 @@ * Brown sugar +* Lemon juice * Water @@ -17,5 +17,5 @@ 3. Add cashews and veggies and fry until golden brown. -4. Combine 3 tbsp soy sauce, 2 tbsp brown sugar, 2 tbsp water, - a pinch of cornstarch, and chili powder to taste. Add - mixture to the pan. +4. Combine 3 tbsp soy sauce, 2 tbsp brown sugar, 1 tbsp lemon + juice, 2 tbsp water, a pinch of cornstarch, and chili + powder to taste. Add mixture to the pan. 5. Let sauce simmer with veggies for about two minutes.Here's the new patch. The original patch was 25 lines, and the new patch is 13 lines — an almost 50% reduction! And even better, with the new patch system, it doesn't matter how large your original file is, the patch will only contain the changes made to the file. We end up getting another email, but it isn't a suggestion.
Hey! I'm loving your recipe! You seem to have updated it though, and I don't like the new recipe as much, but can't remember what you've changed. Do you still have the old recipe?So we have our original recipe and all the patches people have sent us. Instead of having to keep a copy of each version of the file, we can rebuild any version of the recipe from the patches!
So we learned a few things from this. We learned how to make some kick-ass Thai Cashew, and...
git was created by Linus Torvalds to manage his main project at the time, the Linux Kernel.
Linux is an operating system, like Windows or macOS, however it is free and open-source. Since it's open-source, anyone can contribute to the project. git was made to simplify his job of sifting through the changes he was sent. It is designed so that many people can work on the project at the same time with a limited amount of interference.