Skip to content
This repository was archived by the owner on Jul 23, 2024. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ In order to set this up, clone this repository somewhere,
run the `git submodule init` and then `git submodule update`
command, and add your clone to $PATH.

Some commands require `python2`. If using mozilla-build on windows, `python2`
might be missing, but `python` exists and is actually python 2 (check by running
`python -V`). On such case, you can create a copy of `python.exe` as `python2.exe`
at the same location - probably at `<mozilla-build>/python/`.

Many of these tools rely on a notion of your current branch's "upstream
branch". For example, `git push-to-try` pushes to try all patches in your
current branch that aren't upstream. See the `git-tracks` section below for
Expand Down
14 changes: 13 additions & 1 deletion git-push-to-hg
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
#!/bin/bash
set -e

if ! hash python2 2> /dev/null; then
echo "'python2' is required but not found. Aborting."
if hash python 2> /dev/null; then
echo "'python' found at '$(which python)'."
echo "If using mozilla-build, you can copy it to 'python2.exe' at the same location."
echo "See README.markdown for more information."
fi
fi

# Push some commits from git to the git-temp qqueue in a given hg repository.
# Note that this nukes the git-temp qqueue, if it exists.
#
Expand All @@ -16,7 +25,10 @@ if [[ $OSTYPE == "msys" ]]; then
# based on cygwin (which uses "c:/somedir") - but markh *actually* sees
# "c:/somedir\filename" - which upsets most $0 usage.
# So fix it up and store the result in $this
this="/${this/:/}" # change "c:" to "/c/"
# git-for-windows 2+ uses the same convension as msys(1) in mozilla-build: /c/
if [[ ${this:1:1} == ":" ]]; then
this="/${this/:/}" # change e.g. "c:" to "/c"
fi
this="${this/\\//}" # change "\" to "/"
fi

Expand Down