-
Notifications
You must be signed in to change notification settings - Fork 2
Mepo Commands
- Overview
-
Commands
- branch create
- branch delete
- branch list
- changed-files
- checkout
- checkout-if-exists
- clone
- commit
- compare
- config delete
- config get
- config print
- config set
- develop
- diff
- fetch
- init
- list
- pull
- pull-all
- push
- reset
- restore-state
- save
- stage
- stash apply
- stash list
- stash pop
- stash push
- stash show
- status
- tag create
- tag delete
- tag list
- tag push
- unstage
- whereis
mepo provides many different commands for working with a multi-repository fixture.
Create branch in component
mepo branch create [-h] branch-name comp-name [comp-name ...]
branch-name Name of branch
comp-name Component to create branches in
-h, --help show this help message and exit
Delete branch in component
mepo branch delete [-h] [--force] branch-name comp-name [comp-name ...]
branch-name Name of branch
comp-name Component to delete branches in
-h, --help show this help message and exit
--force Delete branch even if it has not been fully merged
List local branches. If no component is specified, runs over all components
mepo branch list [-h] [-a] [comp-name ...]
comp-name Component to list branches in
-h, --help show this help message and exit
-a, --all list all (local+remote) branches
List files that have changes versus the state. By default runs against all components.
mepo changed-files [-h] [--full-path] [comp-name ...]
comp-name Component to list branches in
-h, --help show this help message and exit
--full-path Print with full path
Switch to branch/tag branch-name
in component comp-name
. If no components listed, checkout from all. Specifying -b
causes the branch branch-name
to be created and checked out.
mepo checkout [-h] [-b] [-q] [--detach] branch-name [comp-name ...]
branch-name Name of branch
comp-name Components to checkout branch in
-h, --help show this help message and exit
-b create the branch
-q, --quiet Suppress prints
--detach Detach upon checkout
Switch to branch or tag ref-name
in any component where it is present.
mepo checkout-if-exists [-h] [-q] [--detach] [-n] ref-name
ref-name Name of branch or tag
-h, --help show this help message and exit
-q, --quiet Suppress prints
--detach Detach on checkout
-n, --dry-run Dry-run only (lists repos where branch exists)
Clone repositories.
mepo clone [-h] [--branch [name]] [--config [config-file]] [--style [style-type]] [--allrepos] [--partial [partial-type]] [URL] [directory]
URL URL to clone
directory Directory to clone into (Only allowed with URL!)
-h, --help show this help message and exit
--branch [name], -b [name]
Branch/tag of URL to initially clone (Only allowed with URL!)
--config [config-file]
Configuration file (ignored if init already called)
--style [style-type] Style of directory file, default: prefix, allowed options: naked, prefix, postfix (ignored if init already called)
--allrepos Must be passed with -b/--branch. When set, it not only checkouts out the branch/tag for the fixture, but for all the subrepositories as well.
--partial [partial-type]
Style of partial clone, default: None, allowed options: blobless, treeless. Note that blobless means cloning with --filter=blob:none and treeless means cloning with --filter=tree:0. NOTE: We do *not* recommend using "treeless" as
it is very aggressive and will cause problems with many git commands.
Commit staged files in the specified components
mepo commit [-h] [-a] [-m message] comp-name [comp-name ...]
comp-name Component to commit file in
-h, --help show this help message and exit
-a, --all Stage all tracked files and then commit
-m message, --message message
Message to commit with
Compare current and original states of all components. Will only show differing repos unless --all is passed in
mepo compare [-h] [--all] [--nocolor] [--wrap]
-h, --help show this help message and exit
--all Show all repos, not only differing repos
--nocolor Tells command to not display colors.
--wrap Tells command to ignore terminal size and wrap
Delete config entry
in .mepoconfig
. Note this uses gitconfig style where entry
is of the form section.option
. So to delete an alias
st
You would run mepo config delete alias.st
mepo config delete [-h] entry
entry Entry to delete.
-h, --help show this help message and exit
Get config entry
in .mepoconfig
. Note this uses gitconfig style where entry
is of the form section.option
. So to get an alias
st
You would run mepo config get alias.st
mepo config get [-h] entry
entry Entry to display.
-h, --help show this help message and exit
Print contents of .mepoconfig
mepo config print [-h]
-h, --help show this help message and exit
Set config entry
to value
in .mepoconfig
. Note this uses gitconfig style where entry
is of the form section.option
. So to set an alias
for status
of st
You would run mepo config set alias.st status
mepo config set [-h] entry value
entry Entry to set.
value Value to set entry to.
-h, --help show this help message and exit
Checkout current version of 'develop' branches of specified components
mepo develop [-h] [-q] comp-name [comp-name ...]
comp-name Component(s) to checkout development branches
-h, --help show this help message and exit
-q, --quiet Suppress prints
Diff all components
mepo diff [-h] [--name-only] [--name-status] [--ignore-permissions] [--staged] [-b] [comp-name ...]
comp-name Component to list branches in
-h, --help show this help message and exit
--name-only Show only names of changed files
--name-status Show name-status of changed files
--ignore-permissions Tells command to ignore changes in file permissions.
--staged Show diff of staged changes
-b, --ignore-space-change
Ignore changes in amount of whitespace
Download objects and refs from in component comp-name
. If no components listed, fetches from all
mepo fetch [-h] [--all] [-p] [-t] [-f] [comp-name ...]
comp-name Components to fetch in
-h, --help show this help message and exit
--all Fetch all remotes.
-p, --prune Prune remote branches.
-t, --tags Fetch tags.
-f, --force Force action.
Initialize mepo based on config-file
mepo init [-h] [--config [config-file]] [--style [style-type]]
-h, --help show this help message and exit
--config [config-file]
default: components.yaml
--style [style-type] Style of directory file, default: prefix, allowed options: naked, prefix, postfix
List all components that are being tracked
mepo list [-h]
-h, --help show this help message and exit
Pull branches of specified components
mepo pull [-h] [-q] comp-name [comp-name ...]
comp-name Components to pull in
-h, --help show this help message and exit
-q, --quiet Suppress prints
Pull branches of all components (only those in non-detached HEAD state)
mepo pull-all [-h] [-q]
-h, --help show this help message and exit
-q, --quiet Suppress prints
Push local commits to remote for specified component. Use mepo tag push to push tags
mepo push [-h] comp-name [comp-name ...]
comp-name Component to push to remote
-h, --help show this help message and exit
Reset the current mepo clone to the original state. This will delete all subrepos and does not check for uncommitted changes! Must be run in the root of the mepo clone.
mepo reset [-h] [-f] [--reclone] [-n]
-h, --help show this help message and exit
-f, --force Force action.
--reclone Reclone repos after reset.
-n, --dry-run Dry-run only
Restores all components to the last saved state.
mepo restore-state [-h]
-h, --help show this help message and exit
Save current state in a yaml config file
mepo save [-h] [config-file]
config-file default: components-new.yaml
-h, --help show this help message and exit
Stage modified & untracked files in the specified component(s)
mepo stage [-h] [--untracked] comp-name [comp-name ...]
comp-name Component to stage file in
-h, --help show this help message and exit
--untracked Stage untracked files as well
apply stash in component
mepo stash apply [-h] comp-name [comp-name ...]
comp-name Component to apply stash in
-h, --help show this help message and exit
List local stashes of all components
mepo stash list [-h]
-h, --help show this help message and exit
Pop stash in component
mepo stash pop [-h] comp-name [comp-name ...]
comp-name Component to pop stash in
-h, --help show this help message and exit
Push (create) stash in component
mepo stash push [-h] [-m message] comp-name [comp-name ...]
comp-name Component to push stash in
-h, --help show this help message and exit
-m message, --message message
Message for the stash
show stash in component
mepo stash show [-h] [-p] comp-name [comp-name ...]
comp-name Component to show stash in
-h, --help show this help message and exit
-p, --patch Message for the stash
Check current status of all components
mepo status [-h] [--ignore-permissions] [--nocolor] [--hashes]
-h, --help show this help message and exit
--ignore-permissions Tells command to ignore changes in file permissions.
--nocolor Tells status to not display colors.
--hashes Print the exact hash of the HEAD.
Create tag in component . If no component is specified, runs over all components
mepo tag create [-h] [-a] [-m message] tag-name [comp-name ...]
tag-name Name of tag
comp-name Component to create tags in
-h, --help show this help message and exit
-a, --annotate Make an annotated tag
-m message, --message message
Message for the tag
Delete tag in component . If no component is specified, runs over all components
mepo tag delete [-h] tag-name [comp-name ...]
tag-name Name of tag
comp-name Component to delete tags in
-h, --help show this help message and exit
List tags. If no component is specified, runs over all components
mepo tag list [-h] [comp-name ...]
comp-name Component to list tags in
-h, --help show this help message and exit
Push tag in component . If no component is specified, runs over all components
mepo tag push [-h] [-f] [-d] tag-name [comp-name ...]
tag-name Name of tag
comp-name Component to push tags in
-h, --help show this help message and exit
-f, --force Force push (be careful!)
-d, --delete Delete (be careful!)
Un-stage staged files. If a component is specified, files are un-staged only for that component.
mepo unstage [-h] [comp-name ...]
comp-name Component to unstage in
-h, --help show this help message and exit
Get the location of component comp-name
relative to my current location. If comp-name
is not present, get the relative locations of ALL components.
mepo whereis [-h] [-i] [comp-name]
comp-name Component to get location of
-h, --help show this help message and exit
-i, --ignore-case Ignore case for whereis