Package: paul-mclendahand
Tool for combining GitHub pull requests.Code:https://github.com/willkg/paul-mclendahandIssues:https://github.com/willkg/paul-mclendahand/issuesLicense:MPL v2Documentation:this READMEInstall(Recommended) Withpipx:pipx install paul-mclendahandWith pip from PyPI:pip install paul-mclendahandWith pip from GitHub main branch:pip install https://github.com/willkg/paul-mclendahand/archive/main.zipWith pip from a clone of the repository with dev dependencies:pip install -r requirements-dev.txtQuick startConfigure pmacpmac needs to know the GitHub user and GitHub project.You can set configuration in thepyproject.tomlfile:[tool.paul-mclendahand]
github_user = "user"
github_project = "project"
main_branch = "git-main-branch-name"Or you can set configuration in thesetup.cfgfile:[tool:paul-mclendahand]
github_user=user
github_project=project
main_branch=git-main-branch-nameYou can override the configuration variables with environment variables:PMAC_GITHUB_USER=user
PMAC_GITHUB_PROJECT=project
PMAC_MAIN_BRANCH=git-main-branch-nameOptionalYou can also use a GitHub personal access token. You set it in thePMAC_GITHUB_API_TOKENenvironment variable.For example:PMAC_GITHUB_API_TOKEN=abcdef0000000000000000000000000000000000 pmac listprsNoteIf you find pmac stops working because it’s getting rate-limited by GitHub,
you should use a personal access token.Using pmacAfter you’ve configured git, then you can usepmaclike this:Create a new branch:git checkout <MAIN-BRANCH>
git checkout -b update-prsList open PRs:pmac listprsCombine some pull requests into it:pmac add 5100 5101 5102Use the same pull requests numbers as on GitHub.Internally,pmacusesgit amto apply commits from pull requests. If
you hit agit amconflict,pmacwill tell you. You can edit the file
in another terminal to manually resolve the conflict. Then do:git add FILE
git commit
git am --continueAfter that, you can continue withpmac.When you’re done, push the branch to GitHub and create a pull request.pmaccan help with the PR description:pmac prmsgpmacUsage: pmac [OPTIONS] COMMAND [ARGS]...

  GitHub pull request combiner tool.

  pmac uses a "[tool:paul-mclendahand]" section in setup.cfg to set
  configuration variables. You can override these using PMAC_VARNAME environment
  variables.

  Additionally, if you want to use a GitHub personal access token, you need to
  provide the "PMAC_GITHUB_API_TOKEN" variable in the environment set to the
  token.

  For issues, see: https://github.com/willkg/paul-mclendahand/issues

Options:
  --version  Show the version and exit.
  --help     Show this message and exit.

Commands:
  add      Combine specified PRs into this branch.
  listprs  List available PRs for the project.
  prmsg    Print out summary of commits suitable for a PR msg.pmac listprsUsage: pmac listprs [OPTIONS]

  List available PRs for the project.

Options:
  --labels / --no-labels  List labels
  --format [table|tab]
  --help                  Show this message and exit.pmac addUsage: pmac add [OPTIONS] PR...

  Combine specified PRs into this branch.

Options:
  --help  Show this message and exit.pmac prmsgUsage: pmac prmsg [OPTIONS]

  Print out summary of commits suitable for a PR msg.

Options:
  --help  Show this message and exit.Why does this project exist?Two main reasons.First, GitHub doesn’t support combining pull requests. There is a forum post
about it here:https://github.community/t/feature-request-combine-pull-requests/2250Second, dependabot (also owned by GitHub) doesn’t support grouping dependency
updates into a single pull request. If you have 50 dependency updates, it
creates 50 pull requests (sometimes more!). I have a lot of projects and lack
of grouping updates makes monthly maintenance miserable. There’s an issue for
this:https://github.com/dependabot/dependabot-core/issues/1190