{"id":23760,"date":"2023-05-10T02:27:16","date_gmt":"2023-05-10T02:27:16","guid":{"rendered":"https:\/\/www.booksofall.com\/de\/?post_type=product&#038;p=23760"},"modified":"2023-05-10T02:27:32","modified_gmt":"2023-05-10T02:27:32","slug":"git-notes-for-professionals","status":"publish","type":"product","link":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/","title":{"rendered":"Git\u00ae &#8211; Notes for Professionals"},"content":{"rendered":"<h2>Chapter 1: Getting started with Git<\/h2>\n<h4>Section 1.1: Create your first repository, then add and commit files<\/h4>\n<p>At the command line, first verify that you have Git installed:<\/p>\n<p>On all operating systems:<\/p>\n<p><b>git<\/b>\u00a0&#8211;version<\/p>\n<p>On <a href=\"https:\/\/en.wikipedia.org\/wiki\/Unix\">UNIX<\/a>-like operating systems:<\/p>\n<p><b>which<\/b>\u00a0<b>git<\/b><\/p>\n<p>If nothing is returned, or the command is not recognized, you may have to install Git on your system by downloading and running the installer. See the <a href=\"https:\/\/git-scm.com\/book\/en\/v2\/Getting-Started-Installing-Git\">Git homepage<\/a> for exceptionally clear and easy installation instructions.<\/p>\n<p>After installing Git, configure your username and <a href=\"https:\/\/mailchimp.com\/resources\/most-used-email-service-providers\/\">email address<\/a>. Do this before making a commit.<\/p>\n<p>Once Git is installed, navigate to the directory you want to place under version control and create an empty Git repository:<\/p>\n<p><b>git init<\/b><\/p>\n<p>This creates a hidden folder, .git, which contains the plumbing needed for Git to work.<\/p>\n<p>Next, check what files Git will add to your new repository; this step is worth special care:<\/p>\n<p><b>git status<\/b><\/p>\n<p>Review the resulting list of files; you can tell Git which of the files to place into version control (avoid adding files with confidential information such as passwords, or files that just clutter the repo):<\/p>\n<p><b>git add<\/b>\u00a0<b>&lt;<\/b>file<b>\/<\/b>directory name\u00a0<i>#1&gt; &lt;file\/directory name #2&gt; &lt; &#8230; &gt;<\/i><\/p>\n<p>If all files in the list should be shared with everyone who has access to the repository, a single command will add everything in your current directory and its subdirectories:<\/p>\n<p><b>git add<\/b>\u00a0.<\/p>\n<p>This will &#8220;stage&#8221; all files to be added to version control, preparing them to be committed in your first commit.<\/p>\n<p>For files that you want never under version control, create and populate a file named .gitignore before running the add command.<\/p>\n<p>Commit all the files that have been added, along with a commit message:<\/p>\n<p><b>git commit<\/b>\u00a0-m &#8220;Initial commit&#8221;<\/p>\n<p>This creates a new commit with the given message. A commit is like a save or snapshot of your entire project. You can now push, or upload, it to a remote repository, and later you can jump back to it if necessary. If you omit the -m parameter, your default editor will open and you can edit and save the commit message there.<\/p>\n<p>Adding a remote<\/p>\n<p>To add a new remote, use the\u00a0<b>git remote<\/b>\u00a0add command on the terminal, in the directory your repository is stored at.<\/p>\n<p>The\u00a0<b>git remote<\/b>\u00a0add command takes two arguments:<\/p>\n<ol>\n<li>A remote name, for example, origin<\/li>\n<li>A remote URL, for example, https:<b>\/\/&lt;<\/b>your-git-service-address<b>&gt;\/<\/b>user<b>\/<\/b>repo.git<\/li>\n<\/ol>\n<p><b>git remote<\/b>\u00a0add origin https:<b>\/\/&lt;<\/b>your-git-service-address<b>&gt;\/<\/b>owner<b>\/<\/b>repository.git<\/p>\n<p>NOTE: Before adding the remote you have to create the required repository in your git service, You&#8217;ll be able to push\/pull commits after adding your remote.<\/p>\n<h4>Section 1.2: Clone a repository<\/h4>\n<p>The\u00a0<a href=\"https:\/\/git-scm.com\/docs\/git-clone\"><b>git clone<\/b>\u00a0<\/a>command is used to copy an existing Git repository from a server to the local machine.<\/p>\n<p>For example, to clone a GitHub project:<\/p>\n<p><b>cd<\/b>\u00a0<b>&lt;<\/b>path where you would like the clone to create a directory<b>&gt;<br \/>\ngit clone<\/b>\u00a0https:<b>\/\/<\/b>github.com<b>\/<\/b>username<b>\/<\/b>projectname.git<\/p>\n<p>To clone a BitBucket project:<\/p>\n<p><b>cd<\/b>\u00a0<b>&lt;<\/b>path where you would like the clone to create a directory<b>&gt;<br \/>\ngit clone<\/b>\u00a0https:<b>\/\/<\/b>yourusername<b>@<\/b>bitbucket.org<b>\/<\/b>username<b>\/<\/b>projectname.git<\/p>\n<p>This creates a directory called projectname on the local machine, containing all the files in the remote Git repository. This includes source files for the project, as well as a .git sub-directory which contains the entire history and configuration for the project.<\/p>\n<p>To specify a different name of the directory, e.g. MyFolder:<\/p>\n<p><b>git clone<\/b>\u00a0https:<b>\/\/<\/b>github.com<b>\/<\/b>username<b>\/<\/b>projectname.git MyFolder<\/p>\n<p>Or to clone in the current directory:<\/p>\n<p><b>git clone<\/b>\u00a0https:<b>\/\/<\/b>github.com<b>\/<\/b>username<b>\/<\/b>projectname.git .<\/p>\n<p>Note:<\/p>\n<ol>\n<li>When cloning to a specified directory, the directory must be empty or non-existent.<\/li>\n<li>You can also use the\u00a0<b>ssh<\/b> version of the command:<\/li>\n<\/ol>\n<p><b>git clone<\/b>\u00a0<b>git@<\/b>github.com:username<b>\/<\/b>projectname.git<\/p>\n<p>The https version and the\u00a0<b>ssh<\/b>\u00a0version are equivalent. However, some hosting services such as GitHub recommend that you use https rather than\u00a0<b>ssh<\/b>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p><iframe style=\"width: 100%; height: 750px; border: none;\" src=\"https:\/\/online.visual-paradigm.com\/share\/book\/gitnotesforprofessionals-1cmyxeej61?p=1\" frameborder=\"0\" allowfullscreen=\"allowfullscreen\"><\/iframe><\/p>\n","protected":false},"featured_media":23764,"template":"","meta":{"_yoast_wpseo_title":"","_yoast_wpseo_metadesc":"Git is a distributed version control system for tracking changes to source code during the software development process. Learn more about it with this book!"},"product_brand":[],"product_cat":[386],"product_tag":[],"class_list":{"0":"post-23760","1":"product","2":"type-product","3":"status-publish","4":"has-post-thumbnail","6":"product_cat-version-control-systems","8":"first","9":"instock","10":"shipping-taxable","11":"product-type-simple"},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Git\u00ae - Notes for Professionals - BooksOfAll German<\/title>\n<meta name=\"description\" content=\"Git is a distributed version control system for tracking changes to source code during the software development process. Learn more about it with this book!\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/\" \/>\n<meta property=\"og:locale\" content=\"de_DE\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Git\u00ae - Notes for Professionals - BooksOfAll German\" \/>\n<meta property=\"og:description\" content=\"Git is a distributed version control system for tracking changes to source code during the software development process. Learn more about it with this book!\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/\" \/>\n<meta property=\"og:site_name\" content=\"BooksOfAll German\" \/>\n<meta property=\"article:modified_time\" content=\"2023-05-10T02:27:32+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:image\" content=\"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg\" \/>\n<meta name=\"twitter:label1\" content=\"Gesch\u00e4tzte Lesezeit\" \/>\n\t<meta name=\"twitter:data1\" content=\"3\u00a0Minuten\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/\",\"url\":\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/\",\"name\":\"Git\u00ae - Notes for Professionals - BooksOfAll German\",\"isPartOf\":{\"@id\":\"https:\/\/www.booksofall.com\/de\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg\",\"datePublished\":\"2023-05-10T02:27:16+00:00\",\"dateModified\":\"2023-05-10T02:27:32+00:00\",\"description\":\"Git is a distributed version control system for tracking changes to source code during the software development process. Learn more about it with this book!\",\"breadcrumb\":{\"@id\":\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#breadcrumb\"},\"inLanguage\":\"de\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"de\",\"@id\":\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#primaryimage\",\"url\":\"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg\",\"contentUrl\":\"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg\",\"width\":\"827\",\"height\":\"1169\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.booksofall.com\/de\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Categories\",\"item\":\"https:\/\/www.booksofall.com\/de\/categories\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Git\u00ae &#8211; Notes for Professionals\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.booksofall.com\/de\/#website\",\"url\":\"https:\/\/www.booksofall.com\/de\/\",\"name\":\"BooksOfAll German\",\"description\":\"Biggest IT eBooks library and learning resources - Free eBooks for programming, computing, artificial intelligence and more.\",\"publisher\":{\"@id\":\"https:\/\/www.booksofall.com\/de\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.booksofall.com\/de\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"de\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.booksofall.com\/de\/#organization\",\"name\":\"BooksOfAll German\",\"url\":\"https:\/\/www.booksofall.com\/de\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"de\",\"@id\":\"https:\/\/www.booksofall.com\/de\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2022\/06\/booksofall-logo-2.png\",\"contentUrl\":\"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2022\/06\/booksofall-logo-2.png\",\"width\":166,\"height\":30,\"caption\":\"BooksOfAll German\"},\"image\":{\"@id\":\"https:\/\/www.booksofall.com\/de\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Git\u00ae - Notes for Professionals - BooksOfAll German","description":"Git is a distributed version control system for tracking changes to source code during the software development process. Learn more about it with this book!","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/","og_locale":"de_DE","og_type":"article","og_title":"Git\u00ae - Notes for Professionals - BooksOfAll German","og_description":"Git is a distributed version control system for tracking changes to source code during the software development process. Learn more about it with this book!","og_url":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/","og_site_name":"BooksOfAll German","article_modified_time":"2023-05-10T02:27:32+00:00","og_image":[{"url":"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg","type":"","width":"","height":""}],"twitter_card":"summary_large_image","twitter_image":"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg","twitter_misc":{"Gesch\u00e4tzte Lesezeit":"3\u00a0Minuten"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/","url":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/","name":"Git\u00ae - Notes for Professionals - BooksOfAll German","isPartOf":{"@id":"https:\/\/www.booksofall.com\/de\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#primaryimage"},"image":{"@id":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#primaryimage"},"thumbnailUrl":"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg","datePublished":"2023-05-10T02:27:16+00:00","dateModified":"2023-05-10T02:27:32+00:00","description":"Git is a distributed version control system for tracking changes to source code during the software development process. Learn more about it with this book!","breadcrumb":{"@id":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#breadcrumb"},"inLanguage":"de","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/"]}]},{"@type":"ImageObject","inLanguage":"de","@id":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#primaryimage","url":"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg","contentUrl":"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2023\/05\/Git-Notes-for-Professionals.jpg","width":"827","height":"1169"},{"@type":"BreadcrumbList","@id":"https:\/\/www.booksofall.com\/de\/git-notes-for-professionals\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.booksofall.com\/de\/"},{"@type":"ListItem","position":2,"name":"Categories","item":"https:\/\/www.booksofall.com\/de\/categories\/"},{"@type":"ListItem","position":3,"name":"Git\u00ae &#8211; Notes for Professionals"}]},{"@type":"WebSite","@id":"https:\/\/www.booksofall.com\/de\/#website","url":"https:\/\/www.booksofall.com\/de\/","name":"BooksOfAll German","description":"Biggest IT eBooks library and learning resources - Free eBooks for programming, computing, artificial intelligence and more.","publisher":{"@id":"https:\/\/www.booksofall.com\/de\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.booksofall.com\/de\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"de"},{"@type":"Organization","@id":"https:\/\/www.booksofall.com\/de\/#organization","name":"BooksOfAll German","url":"https:\/\/www.booksofall.com\/de\/","logo":{"@type":"ImageObject","inLanguage":"de","@id":"https:\/\/www.booksofall.com\/de\/#\/schema\/logo\/image\/","url":"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2022\/06\/booksofall-logo-2.png","contentUrl":"https:\/\/www.booksofall.com\/de\/wp-content\/uploads\/sites\/9\/2022\/06\/booksofall-logo-2.png","width":166,"height":30,"caption":"BooksOfAll German"},"image":{"@id":"https:\/\/www.booksofall.com\/de\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/www.booksofall.com\/de\/wp-json\/wp\/v2\/product\/23760","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.booksofall.com\/de\/wp-json\/wp\/v2\/product"}],"about":[{"href":"https:\/\/www.booksofall.com\/de\/wp-json\/wp\/v2\/types\/product"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.booksofall.com\/de\/wp-json\/wp\/v2\/media\/23764"}],"wp:attachment":[{"href":"https:\/\/www.booksofall.com\/de\/wp-json\/wp\/v2\/media?parent=23760"}],"wp:term":[{"taxonomy":"product_brand","embeddable":true,"href":"https:\/\/www.booksofall.com\/de\/wp-json\/wp\/v2\/product_brand?post=23760"},{"taxonomy":"product_cat","embeddable":true,"href":"https:\/\/www.booksofall.com\/de\/wp-json\/wp\/v2\/product_cat?post=23760"},{"taxonomy":"product_tag","embeddable":true,"href":"https:\/\/www.booksofall.com\/de\/wp-json\/wp\/v2\/product_tag?post=23760"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}