{"id":243,"date":"2014-06-19T09:33:26","date_gmt":"2014-06-19T17:33:26","guid":{"rendered":"http:\/\/research.engineering.ucdavis.edu\/biosport\/?page_id=243"},"modified":"2014-06-19T09:33:26","modified_gmt":"2014-06-19T17:33:26","slug":"revision-control","status":"publish","type":"page","link":"https:\/\/research.engineering.ucdavis.edu\/biosport\/sample-page\/lab-meetings\/revision-control\/","title":{"rendered":"Revision Control"},"content":{"rendered":"<p>Synopsis of revision control basics and Git.<\/p>\n<p id=\"link-presentation\"><a href=\"http:\/\/biosport.ucdavis.edu\/lab-meetings\/revision-control\/presentation_view\" rel=\"nofollow\">Also available in presentation mode\u2026<\/a><\/p>\n<div id=\"parent-fieldname-text\">\n<h2>Revision Control<\/h2>\n<h3>Other names<\/h3>\n<ul>\n<li>\u00a0version control<\/li>\n<li>source control<\/li>\n<li>software configuration management<\/li>\n<\/ul>\n<h3>What is it?<\/h3>\n<p>A way to track changes to computer files, often with the capability of collaboration. It is used in software coding, word processors like google docs, wiki&#8217;s, content management, CAD, etc. It is basically a more advanced &#8220;undo&#8221; button. Most often used with human readable files but can be used with other types too.<\/p>\n<h3>Distributed vs Client-Server models<\/h3>\n<p>Collaborative work on the same file. How can two people open the file at the same time and work on it? This capibily has only just been introduced: google docs, google wave, the upcoming gedit, etc. So how has it traditionally been handled?<\/p>\n<div>\n<dl>\n<dt>Client server<\/dt>\n<dd>All the files are stored on a central server and must be either checked out leaving the file locked to others or many people can check them out and the changes must be merged after the edits. Merging is difficult with files that aren&#8217;t basic text.<\/dd>\n<dt><a href=\"http:\/\/en.wikipedia.org\/wiki\/Distributed_revision_control\">Distributed<\/a><\/dt>\n<dd>Everyone&#8217;s copy is a repository that can be copied by others. No central server, so the operations on the files are much faster.<\/dd>\n<\/dl>\n<\/div>\n<h2>Resources<\/h2>\n<div>\n<div>\n<ul>\n<li><a href=\"http:\/\/en.wikipedia.org\/wiki\/Revision_control\">Revision control on Wikipedia<\/a><\/li>\n<\/ul>\n<\/div>\n<h2>Software<\/h2>\n<div>\n<ul>\n<li>Wikipedia&#8217;s list:\u00a0<a href=\"http:\/\/en.wikipedia.org\/wiki\/List_of_revision_control_software\">http:\/\/en.wikipedia.org\/wiki\/List_of_revision_control_software<\/a><\/li>\n<\/ul>\n<\/div>\n<\/div>\n<h3>Open source<\/h3>\n<div>\n<ul>\n<li><a href=\"http:\/\/git-scm.com\/\">GIT<\/a><\/li>\n<li><a href=\"http:\/\/mercurial.selenic.com\/\">Mecurial<\/a><\/li>\n<li><a href=\"http:\/\/www.nongnu.org\/cvs\/\">CVS<\/a><\/li>\n<li><a href=\"http:\/\/subversion.apache.org\/\">SVN<\/a><\/li>\n<\/ul>\n<\/div>\n<h3>Proprietary<\/h3>\n<div>\n<div>\n<ul>\n<li><a href=\"http:\/\/www.bitkeeper.com\/\">Bitkeeper<\/a><\/li>\n<\/ul>\n<\/div>\n<h2>Git<\/h2>\n<div>Git was written to manage the\u00a0<a href=\"http:\/\/git.kernel.org\/\">Linux sourcecode<\/a>\u00a0after Bitkeeper wasn&#8217;t available to use anymore.<\/div>\n<h3>Features (from Version Control with Git by Jon Leoliger)<\/h3>\n<div>\n<ul>\n<li>Distributed development<\/li>\n<li>For thousands of developers<\/li>\n<li>Fast performance<\/li>\n<li>Data integrity<\/li>\n<li>Accountability<\/li>\n<li>Immutability<\/li>\n<li>Atomic transactions<\/li>\n<li>Encourage branched development<\/li>\n<li>Complete repositories<\/li>\n<li>Clean internal design<\/li>\n<li>Free, as in freedom<\/li>\n<\/ul>\n<\/div>\n<h3>Resources<\/h3>\n<div>\n<ul>\n<li><a href=\"http:\/\/github.com\/\">Github<\/a>\u00a0&#8211; Social coding website base base on Git<\/li>\n<li><a href=\"https:\/\/git.wiki.kernel.org\/index.php\/Gitweb\">Gitweb<\/a>\u00a0&#8211; Show your git repo to the world from your server<\/li>\n<li><a href=\"https:\/\/git.wiki.kernel.org\/index.php\/Main_Page\">Gitwiki<\/a>\u00a0&#8211; The Git project wiki<\/li>\n<li><a href=\"http:\/\/www-cs-students.stanford.edu\/~blynn\/gitmagic\/\">Gitmagic<\/a>\u00a0&#8211; Tutorial and documentation<\/li>\n<li><a href=\"http:\/\/oreillynet.com\/pub\/e\/1394\">Git Webcast<\/a>\u00a0by Scott Chacon &#8211; Introductiong to Git<\/li>\n<li><a href=\"http:\/\/oreilly.com\/catalog\/9780596520137\">Version Control with Git by Jon Leoliger<\/a>\u00a0&#8211; Great book<\/li>\n<li>Cheat sheets:\u00a0<a href=\"http:\/\/zrusin.blogspot.com\/2007\/09\/git-cheat-sheet.html\">One<\/a>,\u00a0<a href=\"http:\/\/github.com\/guides\/git-cheat-sheet\">Two<\/a>,\u00a0<a href=\"http:\/\/jan-krueger.net\/development\/git-cheat-sheet-take-two\">Three<\/a><\/li>\n<li><a href=\"http:\/\/marklodato.github.com\/visual-git-guide\">A visual git reference<\/a><\/li>\n<li><a href=\"http:\/\/library.edgecase.com\/git_immersion\/index.html\">http:\/\/library.edgecase.com\/git_immersion\/index.html<\/a><\/li>\n<\/ul>\n<\/div>\n<h3>Tutorial<\/h3>\n<div>\n<ul>\n<li>Concepts\n<ul>\n<li>Repos<\/li>\n<li>Object types: Blobs, Trees, Commits, Tags<\/li>\n<li>SHA1 Hash<\/li>\n<li>The index<\/li>\n<\/ul>\n<\/li>\n<li>Init and Clone<\/li>\n<li>Adding<\/li>\n<li>Commiting<\/li>\n<li>Branches<\/li>\n<li>Diff<\/li>\n<li>Merges<\/li>\n<li>Remote Repositories<\/li>\n<\/ul>\n<\/div>\n<h3>Example commands<\/h3>\n<div>\n<ul>\n<li>Three basic startup commands: init, add, commit<\/li>\n<li>find ., .git\/objects<\/li>\n<li>commit, commit -am &#8220;message&#8221;<\/li>\n<li>ls-files -s, &#8211;stage<\/li>\n<li>cat-file -p &lt;HASH&gt; &#8211; shows what the file is<\/li>\n<li>write-tree<\/li>\n<li>status<\/li>\n<li>log, log -1 &#8211;pretty=oneline<\/li>\n<li>show<\/li>\n<li>show-branch<\/li>\n<li>rm, mv<\/li>\n<li>blame<\/li>\n<li>checkout<\/li>\n<li>branch<\/li>\n<li>diff<\/li>\n<li>merge<\/li>\n<\/ul>\n<\/div>\n<h3>Git + Matlab<\/h3>\n<div>\n<ul>\n<li>Simply type: system(&#8216;command&#8217;) where &#8216;command&#8217; is the git command you would type in the shell.<\/li>\n<li><a href=\"http:\/\/manuraghavan.net\/?p=22\">http:\/\/manuraghavan.net\/?p=22<\/a><\/li>\n<\/ul>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Synopsis of revision control basics and Git. Also available in presentation mode\u2026 Revision Control Other names \u00a0version control source control software configuration management What is it? A way to track changes to computer files, often with the capability of collaboration. It is used in software coding, word processors like google \u2026 <a class=\"continue-reading-link\" href=\"https:\/\/research.engineering.ucdavis.edu\/biosport\/sample-page\/lab-meetings\/revision-control\/\"> Continue reading <span class=\"meta-nav\">&rarr; <\/span><\/a><\/p>\n","protected":false},"author":10,"featured_media":0,"parent":29,"menu_order":6,"comment_status":"closed","ping_status":"closed","template":"","meta":{"ngg_post_thumbnail":0,"footnotes":""},"class_list":["post-243","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/research.engineering.ucdavis.edu\/biosport\/wp-json\/wp\/v2\/pages\/243","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/research.engineering.ucdavis.edu\/biosport\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/research.engineering.ucdavis.edu\/biosport\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/research.engineering.ucdavis.edu\/biosport\/wp-json\/wp\/v2\/users\/10"}],"replies":[{"embeddable":true,"href":"https:\/\/research.engineering.ucdavis.edu\/biosport\/wp-json\/wp\/v2\/comments?post=243"}],"version-history":[{"count":0,"href":"https:\/\/research.engineering.ucdavis.edu\/biosport\/wp-json\/wp\/v2\/pages\/243\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/research.engineering.ucdavis.edu\/biosport\/wp-json\/wp\/v2\/pages\/29"}],"wp:attachment":[{"href":"https:\/\/research.engineering.ucdavis.edu\/biosport\/wp-json\/wp\/v2\/media?parent=243"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}