Code collaboratively with GitHub Once you've learned the basics of coding the next step is to start sharing your expertise, learning from other coding pros, or working as a collaborative member of development teams. GitHub is the go-to community for facilitating coding collaboration, and GitHub For Dummies is the next step on your journey as a developer.
Written by a GitHub engineer, this book is packed with insight on how GitHub works and how you can use it to become a more effective, efficient, and valuable member of any collaborative programming team.
Store and share your work online with GitHub Collaborate with others on your team or across the international coding community Embrace open-source values and processes Establish yourself as a valuable member of the GitHub community From setting up GitHub on your desktop and launching your first project to cloning repositories, finding useful apps on the marketplace, and improving workflow, GitHub For Dummies covers the essentials the novice programmer needs to enhance collaboration and teamwork with this industry-standard tool.
, Phil Haack
John Wiley & Sons Inc
Country of Publication:
02 July 2019
Professional and scholarly
Introduction 1 About This Book 1 Foolish Assumptions 2 Icons Used in This Book 3 Beyond the Book 3 Where to Go from Here 4 Part 1: Getting Started with GitHub.Com 5 Chapter 1: Understanding the Git in GitHub 7 Introducing GitHub 7 Understanding Version Control 8 Git Version Control 8 Try simple Git on the terminal 9 Git branching by collaborator 14 Git branching by feature 15 Git branching for experimentation 16 Git's Place on GitHub 16 Signing Up for GitHub.com 17 Personalizing Your GitHub.com Account 18 Account 19 Emails 19 Notifications 21 Billing 21 SSH and GPG keys 22 Security 23 Sessions 23 Blocked users 23 Repositories 23 Organizations 23 Saved replies 24 Applications 24 Developer settings 25 Discovering Helpful Resources 25 Chapter 2: Setting Up Your Collaborative Coding Environment 27 Exploring GitHub.com 27 Understanding Your Profile 32 Getting to Know GitHub Desktop 33 Setting up GitHub Desktop 34 Introducing Atom 35 Part 2: Starting Your First Solo Project 39 Chapter 3: Introducing GitHub Repositories 41 Setting Up a Repository 41 Exploring Your Repository 44 Top information 44 Tabs 45 Code tab 46 Modifying README.md 48 Merging a Pull Request 53 Using Issues and Project Boards 56 Creating a project board and an issue 56 Closing an issue 60 Chapter 4: Setting Up a GitHub Website Repo 63 Introducing GitHub Pages 64 Turning a Project Repo into a Website 64 Setting Up a Personal Website Repo 66 Creating Issues for Your Website 69 Setting Up Your Local Environment 71 Cloning a repo in GitHub Desktop 71 Touring GitHub Desktop 72 Opening your repo in Atom 74 Touring Atom 74 Finding Resources for GitHub Pages 76 Chapter 5: Creating a Website with GitHub Pages 77 Jumping into an Existing GitHub Project 77 Accessing the GitHub.com repo 78 Verifying your permissions for the repo 79 Orienting yourself with the project 80 Preparing Your Contribution 83 Creating a branch for your contribution 83 Confirming your branch is published 86 Building Your Personal Website 91 Modifying the title and tagline 91 Adding sections to your website 91 Creating a blog 92 Linking project repos 93 Part 3: Contributing to Your First Project 95 Chapter 6: Forking GitHub Repositories 97 Introducing Forking 97 Cloning, Forking, and Duplicating 98 Cloning a Repository 99 Forking a Repository 100 Fetching changes from upstream 103 Contributing changes to upstream 104 Getting unstuck when cloning without forking 107 Chapter 7: Writing and Committing Code 113 Creating a Repository 113 Writing Code 114 Creating a Commit 116 Staging changes 117 Committing a file 118 Committing multiple file: 119 Writing a Good Commit Message 120 Committing Code with GitHub Desktop 122 Tracking a repository in Desktop 123 Publishing a repository in Desktop 124 Committing in Desktop 125 Using GitHub Conventions in Commit Messages 129 Emojis 129 Issue references 129 Giving credit to coauthors 130 Committing Code from Your Editor 132 Chapter 8: Working with Pull Requests 133 Understanding a Pull Request 133 Pushing Code to GitHub 134 Opening a Pull Request 135 Describing the pull request 138 Adding reviewers 138 Specifying assignees 139 Specifying labels 139 Specifying projects and milestones 139 Creating the pull request 139 Writing a Great Pull Request 140 Knowing your audience 140 Making the purpose clear 141 Keeping it focused 141 Explaining the why 142 A picture is worth a thousand words 142 Including a call to action 143 Reviewing a Pull Request 144 Reviewing the Conversation tab 145 Reviewing the changed files 146 Commenting on code 146 Suggesting changes 148 Finishing the review 150 Reading More About Pull Requests 151 Part 4: Manage and Contribute to Large Projects 153 Chapter 9: Exploring and Contributing to OSS 155 Exploring GitHub 156 Exploring the headline section 156 Discovering repositories 157 Trending repositories 157 Exploring topics 158 Exploring Marketplace apps 160 Exploring Events 160 Exploring collections 160 Getting by with help from your friends 161 Finding Places to Contribute 161 Surveying a Project for Contribution 164 Reading the CONTRIBUTING guide 164 Reading the contributing code guide 164 Reading the code of conduct 165 Setting Contributor Expectations 166 They won't fix every issue 166 They won't merge every pull request 166 They don't owe you anything 167 Keeping Tabs on a Project 167 Chapter 10: Starting Your Own OSS 169 Creating an Open Source Repository 169 Adding a license 170 Adding contributor guidelines 173 Adding a code of conduct 173 Making a Repository Public 173 Enforcing a Code of Conduct 175 Responding with kindness 175 Leveraging the ban hammer 175 Blocking users 176 Writing a README.md File 178 Writing Good Documentation 178 Managing Issues 179 Labeling issues 179 Triaging issues 180 Issue templates 181 Saved replies 183 Ending Your Project 185 Archiving a project 185 Transferring ownership 186 Chapter 11: Inner-Source Your Code on GitHub 189 Why Code in Private? 189 Using GitHub Organizations 190 Creating a GitHub organization 190 Inviting members to your GitHub organization 191 Viewing repositories for your organization 192 Managing members of your organization 193 Creating teams within your organization 195 Using project boards within your organization 196 Setting organization settings 197 Making the Most of Your Teams 199 Creating parent/child teams 199 Discussing teams 200 Assigning CODEOWNERS 201 Best Practices for Inner-Sourcing 204 Repository insights 204 Milestones for larger projects 207 Part 5: Make GitHub Work for You 209 Chapter 12: Collaborating Outside of GitHub 211 Chatting it Up 212 Installing the GitHub app for Slack 212 Subscribing to a repository in a Slack channel 214 Trying out the GitHub Slack integration 217 Getting Trello and GitHub Integrated 219 Installing the GitHub power-up 220 Using the GitHub power-up 222 Managing Notifications with Octobox 225 Chapter 13: GitHub Workflow Integrations 229 Using GitHub for Atom 229 Viewing, checking out, and creating pull requests 230 Viewing issues 233 Following the GitHub package for Atom 235 Using GitHub for Visual Studio Code 235 Interacting with pull requests in VS Code 237 Following the GitHub for VS Code pull requests extension 238 Using GitHub for Unity 239 Using GitHub for Unity in Unity 240 Following the GitHub for Unity extension 242 Using GitHub for Visual Studio 243 Viewing, creating, and reviewing pull requests in Visual Studio 244 Following the GitHub for Visual Studio extension 246 Using GitHub for XCode 246 Using GitHub for IntelliJ 248 Chapter 14: Personalizing GitHub 251 Using Browser Extensions 251 Refining GitHub 252 Taking a GitHub selfie 254 GitHub Apps and Probot 255 Introducing Probot 255 Hosting the app 256 Introducing Glitch 256 Creating a Probot Glitch app 256 Customizing the app 257 Installing the app 259 Taking Action with GitHub Actions 260 Creating a GitHub action workflow 260 Testing a GitHub Action 262 Part 6: The GitHub Ecosystem 263 Chapter 15: Exploring the GitHub Marketplace 265 Introducing the GitHub Marketplace 265 Billing made easy 266 The Marketplace vetting process 267 Listing Your App on the Marketplace 268 Considering Common Apps to Install 270 Continuous integration 271 Code quality 271 Localization 272 Monitoring 272 Dependency management 273 Testing 273 Learning 274 Chapter 16: GitHub and You 275 Understanding Your GitHub Profile 275 Profile picture 277 Status message 277 Personal info and Bio 277 Pinned repositories 278 Contribution graph 279 Contribution activity 281 Starring Repositories 281 Following Users 282 Chapter 17: Attending Events 285 Exploring Types of Events 286 Meet-ups and user groups 286 Regional conferences 286 Hackathons 287 Major conferences 288 Knowing What to Expect at Events 288 Keynotes 289 Conference session tracks 289 Hallway tracks 290 After-hour conference events 290 A respectful professional environment 290 Becoming Familiar with GitHub Events 291 GitHub Universe 291 GitHub Satellite 291 GitHub Constellation 292 Git Merge 292 Speaking at Events 292 Everyone has a story to tell 292 Benefits of being a speaker 293 Finding Funding for Events 293 Part 7: The Parts of Tens 295 Chapter 18: Ten Ways to Level Up on GitHub 297 Trial and Error 297 GitHub Help Docs 298 GitHub Learning Labs 300 GitHub In-Person Training 301 Project-Specific Documentation 302 External Community Places 304 Online Coding Tutorials 304 Online Courses and Tutorials 305 Blogs and Twitter 306 Community Forum 307 Chapter 19: Ten Ways to Improve Your Development Workflow 309 Drafting Pull Requests 309 Git Aliases 311 Run Tests Automatically 311 Take Breaks 312 Prototype User Interfaces 313 Scaffold Apps with Yeoman 313 Chrome Web Developer Tools 314 StackOverflow 315 Code Analysis Tools 315 Project Boards 316 Chapter 20: Ten Tips for Being an Effective Community Member 317 Be Respectful and Kind 317 Report Bad Behavior 318 Write Good Bug Reports 318 Be Responsive 320 Submit Pull Requests to Correct Documentation 320 Document Your Own Code 321 Give Credit Where It's Due 321 Help Get the Word Out 322 Be Proactive and Mentor Others 322 Contribute Outside of GitHub 323 Index 325
Sarah Guthals, PhD is a social software engineer, entrepreneur, and former engineering manager at GitHub. She is coauthor of Helping Kids with Coding For Dummies. Phil Haack is a former engineering director at GitHub and senior program manager at Microsoft. He is author of a number of books on ASP.NET.