Linear and GitHub together

Link Linear issues to GitHub branches and pull requests, let statuses update as PRs move, and copy branch names in a keystroke. A workflow that keeps both in sync.

On this page
  1. Turn on the integration
  2. Link pull requests to issues
  3. Copy the branch name
  4. Let statuses update automatically
  5. A day with both
  6. Common snags
  7. FAQs

Linear and GitHub work best together when every branch and pull request carries the Linear issue ID. With Linear's GitHub integration turned on, a branch named from the issue links the pull request automatically, and Linear can move the issue's status as the pull request opens, gets reviewed and merges. You copy the branch name from the issue, and the rest happens on its own.

Turn on the integration

A workspace admin connects GitHub in Linear's settings, under integrations, and chooses which repositories to link. After that, individual developers don't need to do anything special beyond naming branches and pull requests with the issue ID. Linear's documentation at linear.app/docs walks through the setup and options.

Linear links a pull request to an issue when the issue ID (such as ENG-123) appears in:

  • The branch name. The simplest route: use the branch name Linear suggests.
  • The pull request title.
  • The pull request description, for example with a phrase like "Fixes ENG-123", which can also tell Linear to close the issue when the pull request merges.

Once linked, the issue shows the pull request and its state, and the pull request links back to the issue.

Copy the branch name

Each Linear issue has a suggested git branch name that includes its ID. Copy it and start your branch:

  • In Linear: press ⇧⌘. with the issue selected or open.
  • In OneNotch: select the issue in My issues in the notch and press B, or use the copy branch name button in the issue view.

Then in your terminal, git checkout -b and paste. Your branch is linked from its first push.

Let statuses update automatically

Linear can move issues through your workflow based on pull request events, configured per team. A typical setup:

Pull request eventIssue moves to
Branch pushed or draft pull request openedIn Progress
Pull request opened or review requestedIn Review
Pull request mergedDone

Check your team's workflow settings in Linear to see or change what happens. Automation keeps statuses honest without anyone remembering to update them. For manual changes, see how to change an issue's status quickly.

A day with both

  1. Pick the next issue from your list. In OneNotch, My issues shows your in-progress work first.
  2. Press B to copy the branch name, create the branch, and start coding.
  3. Open a pull request. Linear links it and moves the issue along.
  4. Reviewers see the pull request in their queue. In OneNotch, the GitHub screen's To review tab lists pull requests waiting for your review, with check status, and A twice approves one that's ready.
  5. Merge on GitHub. The issue moves to Done.

Open the issue in OneNotch's notch (press Return) and its view lists linked pull requests alongside comments and sub-issues. See GitHub pull requests on Mac and the software engineer's notch workflow.

Common snags

  • Pull request didn't link. Check that the issue ID appears exactly in the branch, title or description, and that the repository is connected in Linear.
  • Status didn't move. Your team's automation may be configured differently; check team settings.
  • Wrong issue linked. Edit the pull request title or description to the correct ID.

FAQs

Do I need the GitHub integration to use Linear branch names?

You can copy and use branch names without it, but linking and automatic status changes need the integration.

What's the shortcut to copy a branch name in Linear?

⇧⌘. in Linear, or B on an issue in OneNotch.

Can one pull request close several issues?

Yes, by referencing several issue IDs in the description, depending on your settings.

No. Linking is done by Linear's GitHub integration. OneNotch shows linked pull requests on an issue and copies branch names.