Day Two At General Assembly: Learning Git and Github
Today in my Back-End Web Development course we went over git, github, and loops in ruby.
Again, this was mostly review for me, except for the github part. Treehouse has a pretty good course on version control and git, and skims over github. I knew I had to have one, and that I could store stuff there, and other people could contribute, but there was a lot of finer details that were lost on me.
Ex: forking a repository to have your own version, and committing to that, but being able to still pull from the original repository you forked from. I think I can use this to help me compile my cat bot for github. My catbot, the end result of which is found on twitter @NikkisCats, forked a twitter bot. This original twitter bot would create tweets from your own twitter archive. But I wanted a bot that would tweet random pictures. So I forked it to my respository, and then downloaded it and added new code to have it pull a random picture from the bucket i had on AWS, then tweet it. I've been confused on how to properly attribute the original repository and still have my own code available. I think the things I learned today would help me compile everything neatly and get that up this weekend.
For those who don't know, git is a way to do version control. Have you ever gotten an email with an attachment that is named "Important_document_final_with_PRs_edits_PLUS_approval_for_real_final_version_NO_REALLY"? Cause I get that one a lot. Then, of course, while you are editing the afore mentioned document, someone else starts to edit it, too? and you end up with two totally different versions? git is a cool way handle that problem when doing development.
gitHub is a graphical user interface laid overtop of git. Most of git is done in the command line. You create a local folder, and point it toward a repository. Other people can then check out what you "pushed" to the repository, but "pulling" a copy down from the repository. They can then edit it, and push the edit's back up. git will check which files were added, which were changed, and merge those changes. If there is a conflict, it will let you know. This all happens in the command line. gitHub gives you a more visual way of checking what is in the repository, who has made edits, what those edits where, and other information. gitHub also allows you to edit stuff right there in the browser.
This is meant for informational purposes only, and is not an endorsement of gitHub. I encourage my readers to research the business and hiring practices of gitHub and examine them from a feminist lens.
We then learned about while and if loops in Ruby. While and if loops are an extension of some logic, if this, do that, else, if that, do this. While this, keep doing that. You can check out some of the exercises we did in class here and here.
(Yes, jdax as in Jadzia Dax, as in, the best Dax.)
Again, most of this was review for me, but I firmly believe the more times you are exposed to a concept or an idea, the more you understand it and the easier it is.