52
Using GitHub for Enterprise and Open Source Documentation Lynda O’Leary LavaCon, May 2017 @olearylynda

O'Leary - Using GitHub for Enterprise and Open Source Documentation

  • Upload
    lavacon

  • View
    92

  • Download
    0

Embed Size (px)

Citation preview

Page 1: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Using GitHub for Enterprise and Open Source Documentation

Lynda O’LearyLavaCon, May 2017

@olearylynda

Page 2: O'Leary - Using GitHub for Enterprise and Open Source Documentation

About me

@olearylynda

Page 3: O'Leary - Using GitHub for Enterprise and Open Source Documentation

AgendaIntroduction to Git and GitHub

Adapting your documentation workflow

Contributing to open source documentation

Q&A

Page 4: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Environment

Page 5: O'Leary - Using GitHub for Enterprise and Open Source Documentation

What do we need?Small chunks

Topic orientated

Single-source

Various outputs

Technical reviews

Peer reviews

Maintain quality

Page 6: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Collaborative Tools

MadCap Flare MadCap Flare

SVN Git

Planning tool

Page 7: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Why Git?Lightweight branching

● Isolate workspace

Decentralized model

● Perform VCS operations with no remote connection.

Page 8: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Git versus Traditional VCS

GIT Traditional VCS

● Snapshot of a miniature filesystem

● Distributed version control system

● Perform commits and merges on your local

● Push changes to central server

● Set of files● Centralized version control

system ● Changes made to each file

over time

Page 9: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Install Git● Command line - all platforms● Desktop client

1. Download Git https://git-scm.com/downloads.2. Set username and email address.3. Authentication - HTTPS/SSH

Page 10: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Why GitHub?● Fast ● Multiple users● Built in reviews● Powerful search● Secure● User Management● Issue tracker● Integrations

Page 11: O'Leary - Using GitHub for Enterprise and Open Source Documentation

GitHub➔ Hosts Git repositories ➔ Central point of collaboration

◆ clone other projects◆ submit pull requests

➔ Area for networking◆ build a profile◆ upload and share projects◆ connect with contributors

➔ Sign-up https://github.com/.

Page 12: O'Leary - Using GitHub for Enterprise and Open Source Documentation

TerminologyRepository - contains your project files.

Page 13: O'Leary - Using GitHub for Enterprise and Open Source Documentation
Page 14: O'Leary - Using GitHub for Enterprise and Open Source Documentation

ForkA copy of a repository.

Page 15: O'Leary - Using GitHub for Enterprise and Open Source Documentation

BranchUse branches to work on different versions of a repository at one time.

Page 16: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Commit● Save changes to your branch● Small commits● Shows history of work and commit message● Commit often● Commit completed work● Write good commit messages

Page 17: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Commit messages

Page 18: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Pull Request● Method of notifying project maintainers about your changes● Open at any time during development (get discussion started)

Page 19: O'Leary - Using GitHub for Enterprise and Open Source Documentation

MergeMerges changes into master.

Page 20: O'Leary - Using GitHub for Enterprise and Open Source Documentation

GitHub Flow➔ Fork the project you want to contribute to➔ Create a branch

◆ your own area◆ changes don’t affect master branch

➔ Add commits◆ changes to your branch (add, edit, or delete a file)◆ history of work and commit message

➔ Open a Pull Request◆ method of notifying project maintainers about your changes◆ open at any time during development (get discussion started)

➔ Discuss and Review PR➔ Merge PR to master

Page 21: O'Leary - Using GitHub for Enterprise and Open Source Documentation

CloneDownloads a copy to your local computer.

Page 22: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Useful commands➔ git status➔ git log➔ git blame➔ git bisect➔ git checkout <branch>➔ git branch➔ git rm <file>➔ git fetch➔ git push➔ git pull

Page 23: O'Leary - Using GitHub for Enterprise and Open Source Documentation

GitHub IntegrationsContinuous Integration

Communication

Editor

Page 24: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Markdown● Simple format● .md file● Text editor - Atom, Sublime

https://guides.github.com/features/mastering-markdown/

Page 25: O'Leary - Using GitHub for Enterprise and Open Source Documentation

What did I learn?● Agree on a workflow● Implement in stages● Collaboration increased● Easier to track issues● Same tools made it easier for reviews● Treated docs like code● Visibility

Page 26: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Storing your content● Repo only for docs● Store docs in with code

○ Standardize docs folder in project

● Include Readme file● Include .gitignore file● Only migrate the content you need● Add wikis to your repo https://github.com/showcases/projects-with-great-wikis

Page 27: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Using branches● Work in your own workspace without disruption● Define branch naming● Short lived● Branch > tag > roll back

Page 28: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Reviewing content● @mention● Never merge your own PR● Be respectful● Follow the defined workflow● Reward people for their work

Page 29: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Publishing your content● Release tagging● Discuss a workflow that works for your team● Automate

Page 30: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Managing your work● Use gists● Use project boards● Add milestones● Look at metrics

Page 31: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Using issuesTrack updates

Report changes

Suggest improves

Monitor progress

Page 32: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Creating labelsColor code

Identify level of difficulty

Include area of work

Add issue type

Page 33: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Reviewing MetricsWho is contributing?

Page 34: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Reviewing MetricsTimeline of commits

Page 35: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Reviewing MetricsCode Frequency and traffic

Page 36: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Increasing the feedback cycleIssues - create and review

Labels - create meaningful names for all levels

@mention - provide clear feedback, comment in conversations

Add to backlog and implement changes

Page 37: O'Leary - Using GitHub for Enterprise and Open Source Documentation

What do we need to improve?Localization - working with siloed teams?

Peer reviews - where to fit in?

Doc workflow - intent to deliver but sometimes fall behind?

Software/doc workflow - alignment to deliver on time.

Page 38: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Examples of best practice and contributing guideshttps://symfony.com/doc/current/contributing/documentation/overview.html

https://help.github.com/articles/setting-guidelines-for-repository-contributors/

Page 39: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Cultural Change

Page 40: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Continuous Integration/Continuous DeliveryNext steps to ensure quality:

● Automate Builds ● Automate Tests● Automate Deploy

Page 41: O'Leary - Using GitHub for Enterprise and Open Source Documentation

GitHub Pages● Static site hosting service● Hosted from your GitHub repo● username.github.io● Select a theme● Add custom domain

More information: https://pages.github.com/

Page 42: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Contributing to open source● Wide variety of projects● Range of tools● Difficult to find easy issues for beginners● New method of communicating● Uncertainty of the process

Page 43: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Open source is for everyone➔ Triage➔ Technical Writers➔ QA➔ Community Managers➔ UX experts➔ Software Engineers➔ Recruitment

Page 44: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Benefits of contributing to open source➔ Visibility to employers➔ History of your work➔ Shows you have an interest➔ Learn new skills

Page 45: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Your GitHub profile is more important than your LinkedIn profile, to companies you actually want

to work for

Page 46: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Your GitHub Profile is your public portfolio

Page 47: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Search for a project➔ Aligns to your interests ➔ Communicate with the community ➔ Read the guidelines➔ Respect contributors➔ Volunteer to help

Page 48: O'Leary - Using GitHub for Enterprise and Open Source Documentation

How to start contributing?● Find a small project● Read the Readme file

a. information about the projectb. Contributors Guidec. Code of Conduct

● Claim the issue ● Edit this page link

Page 49: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Communicate with contributors➔ IRC Cloud

◆ join the project channel◆ chat to contributors

➔ Twitter➔ Slack

Page 50: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Resources➔ Git for All Platforms http://git-scm.com➔ Emoji cheat sheet http://www.emoji-cheat-sheet.com/➔ IRCCloud https://www.irccloud.com➔ GitHub Guides https://guides.github.com/➔ Git cheat sheet

https://training.github.com/kit/downloads/github-git-cheat-sheet.pdf➔ LavaCon Tutorial https://github.com/lyndaoleary/lavacon

Page 51: O'Leary - Using GitHub for Enterprise and Open Source Documentation

FAQsWhere do I add my docs?

When should I delete a branch?

When would you restore a branch?

What is the difference between fork and clone?

What is the difference between clone and download?

What happens if 2 people working on same content?

Can I commit directly to master?

Page 52: O'Leary - Using GitHub for Enterprise and Open Source Documentation

Thank you!

@olearylynda