-
Notifications
You must be signed in to change notification settings - Fork 0
/
hgrc
67 lines (56 loc) · 1.99 KB
/
hgrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
[ui]
username = Dennis Vermeulen <[email protected]>
merge = Kaleidoscope
ignore = ~/.hgignore_global
[merge-tools]
Kaleidoscope.executable = /usr/local/bin/ksdiff
Kaleidoscope.args = --merge --output $output --base $base -- $local $other
[extensions]
graphlog =
color =
progress =
fetch =
extdiff =
hggit =
rebase =
shelve =
prompt = ~/Src/hg-prompt/prompt.py
[color]
custom.rev = red
custom.bm = yellow
custom.date = green
custom.author = blue
[diff]
git = True
[extdiff]
cmd.ksdiff = /usr/local/bin/ksdiff
opts.ksdiff = --changeset --wait --filelist
[alias]
fe = fetch -m "Automatic merge"
lg = log -G --template "{label('custom.rev',node|short)} - {if(bookmarks,'(')}{label('custom.bm',bookmarks)}{if(bookmarks,') ')}{desc|firstline} ({label('custom.date',date|age)}) <{label('custom.author',author|person)}>" -b .
# Kaleidoscope
# Mnemonics: "kaleidoscope diff" and "kaleidoscope show"
kd = !/usr/local/bin/hg ksdiff $@
ks = !/usr/local/bin/hg ksdiff -c $@
# Run hg commands on all subrepos at once.
subs = !"$HG" debugsub | grep '^path' | cut -d' ' -f2 | xargs -n1 -I SUB $HG -R "`$HG root`/SUB" $@
psubs = !"$HG" debugsub | grep '^path' | cut -d' ' -f2 | parallel -j10 -I SUB $HG -R "`$HG root`/SUB" $@
# Run shell commands on all subrepos at once.
subscmd = !"$HG" debugsub | grep '^path' | cut -d' ' -f2 | xargs -n1 -I SUB sh -c "cd `$HG root`/SUB && $@"
psubscmd = !"$HG" debugsub | grep '^path' | cut -d' ' -f2 | parallel -j10 -I SUB sh -c "cd `$HG root`/SUB && $@"
# Run a command on a subrepo:
#
# hg sub SUBREPO_REGEX ...command and arguments...
#
# The SUBREPO_REGEX should be a regex that will let grep match one and only one of
# the subrepos in .hgsub. For example:
#
# $ cat .hgsub
# bundled/foo = ...
# bundled/bar = ...
#
# $ hg sub fo root
# .../bundled/foo
# $ hg sub ar status -m
# M lol.py
sub = !grep = "`$HG root`/.hgsub" | cut -d' ' -f1 | grep "$1" | tr -d '\n ' | xargs -0 -I SUB $HG -R SUB $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 $12 $13 $14 $15 $16 $17 $18 $19 $20