Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

multipull

Package Overview
Dependencies
Maintainers
1
Versions
45
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

multipull

Pull multiple git repositories

  • 2.2.19
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-50%
Maintainers
1
Weekly downloads
 
Created
Source

Travis Build Status Codecov badge

multipull - Manage multiple git repositories

Install

npm i -g multipull

Configure

Add a .multipullrc file in your home directory containing a JSON with the following keys :

  • root : the absolute path where your repositories are located
  • repos : an array of repositories names (will use every folder that have a .git folder in root if not specified)
  • branches : the default branch in the repository if not main

Example:

{
  "root": "/your/workspace/root/path",
  "collaborators": "your,comma,separated,list,of,collaborators",
  "repos": ["an", "array", "of", "repositories", "in", "root"],
  "branches": {
    "my-repo1": "my-default-branch"
  },
  "issueTracker": {
    "issueIdPattern": "[0-9]{9}",
    "urlPrefix": "https://www.pivotaltracker.com/story/show/"
  }
}

Usage

Every command will always display a table summarizing the status at the end.

Any cell that is equal to the default will contain an empty value, and any line that only contains default values will be omitted.

ParameterDescription
RepoRepository's name
CurrentCurrent branch (if different from default one)
TrackingTracking branch (if different from default one)
PushedWhen using multipush: displays a confirmation or an reason for not doing so
MergedWhen using multimerge: displays a confirmation or an reason for not doing so
Pull RequestWhen using multistatus --pr: displays the link of an existing pull request on the current branch
MergeableIndicate GitHub's mergeable status (i.e no conflict)
BuildWhen using multistatus --ci: displays the build status on this branch (based on GitHub checks)
ReviewsIndicate the number of reviews and comment on GitHub's pull request
SNumber of stashes
??Number of untracked files
MNumber of modified files
DNumber of deleted files
ANumber of added files
CNumber of copied files
FilesWhen using multipull indicate the number of updated files
ChangesWhen using multipull indicate the number of changed lines
InsertionsWhen using multipull indicate the number of inserted lines
DeletionsWhen using multipull indicate the number of deleted lines
ErrorError message
EElapsed time

Note the Files section may contain:

  • a (n) suffix is added when native files are updated
  • a (p) suffix is added when a package.json file is updated

Commands overview

CommandDescription
multicheckoutgit checkout <branch>
multiexecrun command in each repos
multimergemerge pull request
multiprcreate pull request
multipullpull from remote branch
multipushpush to remote branch
multirebaserebase from remote branch
multistatussummarize repositories' status

Commands description

multicheckout

By default, multicheckout [branch] will run

  • git checkout branch if branch is provided
  • git checkout defaultRepositoryBranch otherwise (where defaultRepositoryBranch is provided in the configuration file)

in all the repositories specified in the configuration.

Notes:

  • if the repository doesn't have such a branch, nothing will happen ;
  • if a conflict/error happen during the checkout in one repository, the checkout of the branch in this repostory will be aborted.

multiexec

multiexec --exec=<command> will run the same command in each repository

multimerge

When on a branch different from the default branch, multimerge will merge any existing pull-request found related to this branch.

multipr

multipr will attempt to create a pull request in all the repositories that are on the same branch as the current repository.

Note that it will abort if the current branch is the default one (eg. main).

Parameter reviewers

A comma separated list of GitHub user ids can be provided to be added at the list of reviewers

eg.: multipr --reviewers=John,Jack

Note: a GitHub team can be assigned by prefixing its slug with team/:

eg.: multipr --reviewers=team/justice-league

Parameter collaborators

A comma separated list of GitHub user ids can be provided to be added at the list of collaborators. When creating a pull request, two ids will be picked randomly and added at the list of reviewers.

eg.: multipr --collaborators=John,Jack

Parameter m

Use this parameter to edit the pull request description

eg.: multipr --m

Parameter approve

Submit an APPROVE review on the current pull request.

multipull

Execute git pull all repositories.

eg. multipull

Notes:

  • will attempt to rebase if need be;
  • abort pulling of a remote branch if it would produce conflicts.

multipush

Execute git push in all repositories.

eg. multipush

Parameter force

Execute git push --force in all repositories.

eg. multipush --force

Notes:

  • will refuse to force-push on default branch;
  • will call git with --set-upstream origin if the current tracking branch is not set.

multirebase

Execute git rebase <orgin branch> in all repositories where the branch is different from the default one.

multistatus

Basic

Displays the status of the current repositories

eg. multistatus

With Pull Request (--pr)

On the repositories that are on a branch different from the default branch, and have an open Github pull request, multistatus --pr will output:

  • the pull request's mergability status (wether it conflicts with the destination branch) ;
  • Github's "checks" status ;
  • the number of "approved", "request for changes" and "comments".
Only Pull Requests URLs (--pr --list)

On the repositories that are on a branch different from the default branch, and have an open Github pull request, multistatus --pr --list will output the urls of each PRs.

Open Pull Requests URLs (--pr --open)

On the repositories that are on a branch different from the default branch, and have an open Github pull request, multistatus --pr --open will open the PRs URLs in the default system browser.

With Continous Integration Report (--ci)

On the repositories that are on a branch different from the default branch, multistatus --ci will output Github's "checks" status

FAQs

Package last updated on 18 Sep 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc