DevNet Associate DEVASC 200-901 Official Certification Guide by Adrian Iliesiu (z-lib.org)

(andrew) #1
create mode 100644 Picture2.jpg
create mode 100644 Picture3.png

Working with Branches


Branches are an important workflow in software
development. Say you want to add a new feature to your
software or want to fix a bug. You can create a branch in
order to add a separate development workspace for your
project and prevent changes from destabilizing the main
project (the master branch in Git). Remember that Git
keeps a running history of every commit you make. This
history (called a snapshot in Git terminology) details all
the changes to the software over time and ensures the
integrity of this record by applying an SHA-1 hash. This
hash is a 40-character string that is tied to each and
every commit. Example 2-5 shows an example of three
commits with a hash, displayed using the git log
command.


Example 2-5 git log Command Output

Click here to view code image


#git log
commit 40aaf1af65ae7226311a01209b62ddf7f4ef88c2
(HEAD -> master, origin/master)
Author: Chris Jackson <[email protected]>
Date: Sat Oct 19 00:00:34 2019 -0500
Add files via upload
commit 1a9db03479a69209bf722b21d8ec50f94d727e7d
Author: Chris Jackson <[email protected]>
Date: Fri Oct 18 23:59:55 2019 -0500
Rename README.md to 2README.md
commit 8eb16e3b9122182592815fa1cc029493967c3bca
Author: Chris Jackson <[email protected]>
Date: Fri Oct 18 20:03:32 2019 -0500
first commit
Free download pdf