GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing docs.github.com — Deploying code - GitHub Docs Deploying codeValidate pre-deployment checks, choose merge strategies, and manage branches effectively when deploying code. In this articleThe final step for a pull request is to get finished work into the deployment branch. This usually means merging your changes into the release or main branch. Before that happens, you will need to confirm that the change meets the project's requirements. Validating pre-deployment checksBefore you merge, you will confirm that the change is safe to deploy. Status checks show whether commits meet the conditions set for the repository, such as continuous integration builds, tests, code scanning, or deployment checks. They help you and reviewers understand whether a pull request is ready to merge. Repositories often require certain conditions before a pull request can merge, including:
Protected branches enforce these requirements so deployment branches stay stable. Not all checks are the same. Rich checks created by products like GitHub Actions can report detailed logs and annotations, while simpler commit statuses can be posted by a variety of connected systems. Understanding these helps you interpret why a pull request is or isn't ready. Merging code into the release or main branchWhen the requirements are met, you merge the pull request to bring its commits into the base branch. You can also automate merging so a pull request merges as soon as its requirements are met. Pull requests offer different merge strategies depending on how you want the repository history to look:
The best strategy depends on how much detail your team wants to preserve. Enforcing requirements at scaleAs merging gets busier, teams add controls to keep merges safe and predictable:
Note Pull request merge queues are available in any public repository owned by an organization, or in private repositories owned by organizations using GitHub Enterprise Cloud. See GitHub's plans. Connecting merges to deploymentMerging is often the trigger that ships code. GitHub Actions can run deployment workflows when a pull request merges into a release or main branch. Deployment environments add another layer of pre-deployment safety: you can require specific reviewers, wait timers, or branch restrictions before a deployment proceeds, and these are surfaced alongside your other checks. Recovering after a mergeEven with checks in place, some merges need to be undone. You can revert a merged pull request to create a new pull request that reverses the changes. Be aware, a pull request can be marked as merged indirectly on rare occasions, if its commits reach the base branch through another path. This can bypass the protections on that specific pull request. See Reverting a pull request and Pull request merges. Closing pull requests that won't be mergedNot every pull request should merge. If a change is no longer needed or is superseded by other work, you can close the pull request without merging it. Closing keeps the discussion and history for reference while signaling that the change will not move forward. After a pull request is merged or closed, its head branch is often no longer needed. Deleting unused branches keeps the repository easier to navigate. Further reading |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |