20,39 €
If you are a software developer with little or no experience of versioning systems, or are familiar with other centralized versioning systems, then this book is for you. If you have some experience working with command lines or using Linux admin or just using Unix and want to know more about Git, then this book is ideal for you.
Das E-Book können Sie in Legimi-Apps oder einer beliebigen App lesen, die das folgende Format unterstützen:
Seitenzahl: 163
Veröffentlichungsjahr: 2015
Copyright © 2015 Packt Publishing
All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.
Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this book.
Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.
First published: April 2015
Production reference: 1240415
Published by Packt Publishing Ltd.
Livery Place
35 Livery Street
Birmingham B3 2PB, UK.
ISBN 978-1-78528-790-9
www.packtpub.com
Author
Ferdinando Santacroce
Reviewers
Fabrizio Donina
Giovanni Giorgi
Giovanni Toraldo
Commissioning Editor
Edward Gordon
Acquisition Editor
Meeta Rajani
Content Development Editor
Samantha Gonsalves
Technical Editor
Siddhesh Ghadi
Copy Editors
Hiral Bhat
Karuna Narayanan
Alpha Singh
Project Coordinator
Kinjal Bari
Proofreaders
Simran Bhogal
Safis Editing
Paul Hindle
Bernadette Watkins
Indexer
Tejal Daruwale Soni
Graphics
Jason Monteiro
Abhinash Sahu
Production Coordinator
Nilesh R. Mohite
Cover Work
Nilesh R. Mohite
Occasionally, in the IT industry, some inventions are made whose value is far beyond their merely technical merit. Git is one of them.
Git is immensely faster and more convenient than SVN, CVS, and TFS. It is fast becoming the defacto standard mainly because there are no tools as powerful and versatile as it is; it is a wonderful masterpiece of code. Behind the success of Git lies much more: it is a revolutionary approach to writing code. Git houses an inherently collaborative component in its DNA. It is no coincidence then that the GitHub's tagline is Social Coding.
If Linus Torvalds goes down in history, it will perhaps be not only for Linux and his genius in writing C, but above all, for the social impact that Git has had on the IT community. Just like the invention of the Web and HTTP have enabled humanity to build a network of communication and collaboration previously unthinkable, Git is the very tool that enables us to transform code development into a social activity. As a matter of fact, Git has started a new era in IT.
Git is also a very well documented tool. If you want to learn the syntax of its 155 commands, you don't need this book; the man pages, which are available for free on the web, are certainly more exhaustive.
However, the heart of Git does not lie in the list of its command options. Just like reading the syntax of the class and interface keywords will hardly make you grasp the deeper meaning of object-oriented programming, in the same way, the essence of Git won't emerge easily from its man pages.
The hardest part of Git is the paradigm shift that it requires. Honestly, very few books that I've read are able to explain Git and the universe that revolves around it, in a simpler way than the one you're holding in your hands.
This book covers not only all the main topics you can find on the man pages with simplicity and synthesis (such as the commit, stash, rebase, and management of remote), but also has the merit of being one of the few books to give you a 360-degree overview of the ecosystem that every pragmatic programmer should master. It explains how to set up a local server, teaches you the theory and practice behind GitHub and pull requests in a simple and practical way, and even contains a step-by-step guide to migrate from SVN to Git.
Git Essentials has another merit: it is built like a huge tutorial, and is a step-by-step journey through the Git universe. It's not an academic paper; on the contrary, it's full of concrete examples, is written by a programmer, and targeted at other programmers.
It is a book that values code much more than words.
Arialdo Martini
Solutions Architect at Aduno Gruppe
At the time of writing this (April 2015), Git has just crossed the historical 10th anniversary since its inception. It is crazy for me to think it's already been 10 years.
Owing not in a small part to the innovative concepts that Git and some earlier DVCS solutions brought about, a huge chunk of the modern software development world has been turned upside down due to it. Teams that have adopted it have been greatly empowered on many fronts.
You can branch off and start working on some experimental features without bothering your colleagues. You can also keep your stable branches stable and only merge completed features. Git will also allow you to explore an entire project while on a plane without sending a single network request.
I went back and looked at my first repository and it appears I started using Git professionally in 2008. Thinking about it, I remember the initial struggle I had with some of the core concepts. Git is not particularly easy to pick up even though its user interface has improved consistently over time.
However, after so many years, we enthusiasts and early adopters have been fooled by our own reality tunnel. It's easy to fall into the perception that nowadays the entire world is already using Git and the transition has been completed. I know for a fact though, that I am mistaken!
During the course of my journey through Europe over the last two years, I have seen teams at all stages of Git adoption. I've noticed, for example, that Nordic countries, such as Sweden and Norway, have been working with Git for several years already, while in other countries, companies have only recently decided to make the transition. It's funny that just a few weeks ago somebody told me that they won't be transitioning to Git any time soon. The reason for this? They spent years migrating from CVS to SVN!
In addition to all that I've said, there is still a pressing need to educate teams all around the world about the usefulness of Git. So, I welcome Ferdinando's work with open arms and his efforts in developing a solid guide for people who want to add Git to their toolkit.
What will you gain from a good understanding of Git? It will forever change the way you write software. You'll be able to save your changes as many times as you want in an unpolished, raw form. You'll also be able to always go back and polish up everything before sharing your work with a rebase.
You will be able to work in isolation on a feature or bug fix without disturbing your teammates or lowering the quality of the master stable branch (refer to Chapter 2, Git Fundamentals – Working Locally, for this).
Finally, I can't emphasize enough how Git—and the concepts that are built on it, such as the idea of pull requests—have changed the way professional teams interact, thereby embedding a code review practice into the very texture of the software development process (refer to Chapter 5, Obtaining the Most – Good Commits and Workflows).
It's a great time to be adopting Git and reaping the benefits of this solid and efficient tool whether you are a hobbyist or a professional developer. Good luck!
Nicola Paolucci
Developer Advocate at Atlassian
Having first used CVS as a source version control more than a decade ago, I remember how easy it was to make the transition to using Subversion, which I thought was all I needed in a source version control tool. Then came Git, Bazaar, and Mercurial, the new kids on the block. I looked at them briefly, but initially, I couldn't see what advantage they could really have for me as a programmer over Subversion, as I was working mostly on my own projects. However, it became more and more evident that to facilitate collaboration, I would have to become much more familiar with these new tools. Very soon it seemed, Git became the first choice and I started using it in earnest. I remember feeling that the tutorials I read seemed needlessly complicated, spending too much time on what I felt were unnecessary details. When I read the first draft of Git Essentials, my first thought was, "This is the book I wish I had when I first learned about Git."
Instead of jumping right away into detailed descriptions of the intricacies of dealing with multiple copies of some software shared by multiple programmers—one of the strengths of distributed source version control software such as Git—Ferdinando Santacroce, the author of Git Essentials, took a different approach, focusing on you first as a potentially lone programmer wishing to use Git.
After going through the basics of installing Git in the first chapter, Ferdinando devotes the following chapter to using it locally, that is, without working with an external repository. This allows you to focus on the basics of Git without the unnecessary complication of dealing with the added concept of an external repository. This is not the way I have seen Git being introduced usually—yet, it is definitely the right way. From this point on, there is a logical progression with important concepts highlighted in a progressive manner. Ferdinando postpones the added complication of working with a remote repository until Chapter 3, Git Fundamentals – Working Remotely, using GitHub as an example. Since GitHub has become the most widely used Git repository in the world, this choice is very logical. Yet, the concepts explained in this chapter are just as applicable to other similar sites, such as GitLab or Bitbucket.
There is so much that could be covered when describing how to use Git that it can be a challenge to focus on the essentials, as the title of the book implies. However, Ferdinando has achieved to do just that by making a very judicious use of references to easily accessible external references. The basic topics are well-presented, and pointers to find out more information are added just at the right time. My favorite example of this, which is something I learned from Ferdinando, is to write commit messages before writing the code. Ferdinando mentions this in Chapter 5, Obtaining the Most – Good Commits and Workflows, which briefly explains the rationale and includes a reference to a detailed blog post written by Arialdo Martini on this topic. Current Subversion users, who are considering starting using Git, will find Chapter 6, Migrating to Git, particularly useful.
Git Essentials is definitely not your traditional dry technical document. Ferdinando's writing style is not only that of a friendly conversation with a friend—one who is passionate about his or her favorite topic and eager to help you learn it—but also that of a friend who knows how to restrain his or her enthusiasm and teach you just enough to enable you to do what you need to do. He does this while giving you useful pointers in case you want to know more.
Dr. André Roberge
Former President and Vice-Chancellor of Université Sainte-Anne
Ferdinando Santacroce is a developer, author, and teacher who loves learning new things.
As a software developer, Ferdinando mainly works on the .NET platform using C#, which bridges the gaps between oldstyle systems and new technologies. Over the span of his career, he has allowed COBOL applications to talk with remote services, databases, and electronic devices, such as cash handlers, scanners, and electronic shelf labels. At the moment, he's focusing on continuously improving the Agile Movement, which he follows with great care, in conjunction with XP foundations and lean manufacturing.
While working as a teacher, he developed the first web-based school register in a school of his district, which allowed parents to take a look at grades and absences on a regular basis.
Ferdinando loves to teach people, everyone from children to grandpas, and introduces them to the use of computers, the Internet, and new mobile devices.
He enjoys writing too; after a hiatus of a few years, he started blogging again about his work and passions, which, according to him, is more or less the same thing.
Most of what he's learned over the years has been with the help of his friends and colleagues. This has encouraged him to read books and attend inspiring conferences, such as XP Conference, Italian Agile Day, Codemotion, and others, that help his growth by working on the same code with him.
Fabrizio Donina is 34 years old. For 14 years, he worked at a steel plant. He has been involved in the management of industrial automation systems. He first gained experience on platforms, such as Siemens SCADA Cube, Access Database, and Oracle 8i. In recent years, he has had the opportunity to use different development environments, such as SCADA, FactoryTalk by Rockwell, iFix, and WinCC flexible by Siemens. Currently, he's programming PLC Siemens S7 300/400, performing diagnostics and fault searches. Over the years, he has been able to develop software with the help of VB6.0 and Oracle Forms and interface Oracle - > SAP, by implementing Oracle stored procedures for exchanging data. In recent years, he started programming the MES system, which is now in operation at the plant he's working in.
This is the first time he's been asked to review a book. So far, he's always read manuals that have already been published.
I would like to thank Ferdinando Santacroce who got me involved in this great experience.
Giovanni Giorgi is an IT professional with a strong cultural background, and is currently living in Milan, Italy.
Giovanni works for NTT Data and is involved in the IT banking and financial sectors; he's had more then 15 years of experience in Java-based solutions.
Born in 1974, he grew up with Mazinga Z, Daitarn 3, and 8-bit computers by Commodore.
In college, he studied Latin and Greek, along with Turbo Pascal and C programming language as a hobby.
He then started university in September 1993. After one year, he fell in love with the GNU open source philosophy and the Emacs text editor.
Giovanni got a master's degree in information technology from DSI in Milan, Italy, in 2000, and specialized in UML and design pattern integration.