Your SlideShare is downloading. ×
You're doing it wrong! Git it right!
Upcoming SlideShare
Loading in...5

Thanks for flagging this SlideShare!

Oops! An error has occurred.

Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

You're doing it wrong! Git it right!


Published on

Source code management and version control are absolutely essential to a successful software and web development project, especially when working with a team of developers. If your development …

Source code management and version control are absolutely essential to a successful software and web development project, especially when working with a team of developers. If your development workflow does not include Git, you're doing it wrong! Git it right! Git was first developed in 2005 by Linus Torvalds (yes, THE Linus Torvalds) as a distributed system for managing the development of the Linux kernel. Today, Git is used by companies and organizations large and small. According to the official Git webiste (, Git is used Google, Micorosoft, Facebook, Twitter, and LinkedIn, just to name a few. Even the Joomla CMS and Joomla Platform teams now use Git.

In this presentation, Cory Webb discusses Git and how his company uses Git to manage their web development workflow. He will go over some basic Git commands that every developer should know, as well as cover some popular tools for using Git locally and for hosting Git repositories. He will also open a discussion about how to overcome the limitations of Git, primarily when it comes to managing changes in the database between development and production servers.

Published in: Technology
  • Be the first to comment

No Downloads
Total Views
On Slideshare
From Embeds
Number of Embeds
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

No notes for slide


  • 1.
  • 2. Who am I?● Working with Joomla/Mambo since 2003● Founded Manos (formerly Cory Webb Media, LLC) in 2008● Author of Beginning Joomla Website Development (Wrox 2009)
  • 3. Who are you?● Developers/Programmers● Designers● Integrators
  • 4. Agenda● Why version control?● Intro to Git● Git Basics● Git Clients● Git Repository Hosting● Using Git for Joomla Projects● Questions
  • 5. Why version control?● Less of this: “Im going to be working on template.css today, so nobody touch it!”● More of this: “Lets all work on template.css today and use our version control system to merge our changes at the end of the day!”
  • 6. Why version control?● Easier to work as a team● Snapshots of your code at various stages of development● Branching, staging and experimentation● Ability to revert back to previous versions
  • 7. Intro to Git● Off cial website: i● Distributed version control system● Enables team collaboration● Free and open source (GPLv2 license)● Used by Joomla, Google, Facebook, Microsoft, Twitter, LinkedIn, Netf ix, etc.... l● Seamlessly branch and merge code changes● Work locally
  • 8. Intro to Git● Multiple backups● Custom workflows● Data assurance● Code staging
  • 9. Git Basics | Commands● git clone● git init● git status● git add .● git commit -m “Comment about commit”● git push● git pull● git merge
  • 10. Git Basics | git clone● Clone an existing Git repository● Creates an exact copy of the repository● Changes can be shared between the original and the clone●
  • 11. Git Basics | git init● Initialize a new git repository● Create a new project from scratch●
  • 12. Git Basics | git status● Returns the current status of the repository● Displays list of new, modified, and deleted files● Displays list of changes staged for commit●
  • 13. Git Basics | git add● Add changes to the staging area● Stage modifications (new files and changed files) to be committed to the repository●
  • 14. Git Basics | git commit● Commits staged changes to the repository● Add a comment using -m “Comment”● Stage changes using -a after git commit●
  • 15. Git Basics | git push● Updates remote repositories with local repository●
  • 16. Git Basics | git pull● Fetches a remote repository or local branch and merges changes with the local repository into the current branch●
  • 17. Git Basics | git merge● Merges 2 or more development histories together●
  • 18. Git Basics | .gitignore● File that specifies files within your project that Git should ignore● Using the git status command will not list files from the .gitignore file● Files listed will never be staged for commit or committed●
  • 19. Git Clients | Mac● GitHub for Mac - Free -● Tower - $59 -● Gitbox - $9.99 / Free -● GitX - Free -● SourceTree - Free -● Git-Cola - Free -● SmartGit - $79 / Free -
  • 20. Git Clients | Windows● GitHub for Windows - Free -● Git Extensions - Free -● Git-Cola - Free -● SmartGit - $79 / Free -● TortoiseGit - Free -
  • 21. Git Clients | Linux● Git-Cola - Free -● SmartGit - $79 / Free -
  • 22. Git Repository Hosting●●●●●●● – RoR Git repo hosting app
  • 23. Using Git for Joomla Projects● Getting started● Establish your workflow● Deployment● Database issues
  • 24. Git for Joomla | Getting Started● Initialize the root directory of your Joomla project with git init in your local web server (MAMP)● Install Joomla● Set up your .gitignore file to specify files you dont want to track● Add your files to the repository with git add .● Commit your new files to the repository with git commit -m “Initial commit”
  • 25. Git for Joomla | Getting Started● Set up remote hosting for your repository● Push your local repository to the remote hosting● Each developer clones the repository to their local systems● TIP: Ignore the configuration.php file and let that be specific to each developers local repo.
  • 26. Git for Joomla | Establish workflow● Subversion-style Workflow Image from
  • 27. Git for Joomla | Establish workflow● Integration Manager Workflow Image from
  • 28. Git for Joomla | Establish workflow● Dictator and Lieutenants Workflow Image from
  • 29. Git for Joomla | Deployment● enables easy deployment to development, staging, and production servers● Overwrite existing code files with the master repository once it is deemed ready for deployment
  • 30. Git for Joomla | Database Issues● Git does not track changes to a MySQL database● Probably using different databases for each developer, the development server, staging server and the production server● Development usually involves changing the database (adding articles, menu items, modules, etc. in Joomla)● How do we deal with changes across so many different databases?
  • 31. Git for Joomla | Database Issues● Option 1: Point all instances of Joomla to the same remote database.● Option 2: Manually track changes.● Option 3: Use a database synchronization tool such as● Solution may vary depending on the details of your project
  • 32. Questions?@corywebb @jlleblanc