Show More
@@ -15,26 +15,6 b' ill-formed config' | |||||
15 | hg: parse error at * (glob) |
|
15 | hg: parse error at * (glob) | |
16 | [255] |
|
16 | [255] | |
17 |
|
17 | |||
18 | alias having an environment variable and set to use pager |
|
|||
19 |
|
||||
20 | $ rm $HGRCPATH |
|
|||
21 | $ cat >> $HGRCPATH <<'EOF' |
|
|||
22 | > [ui] |
|
|||
23 | > formatted = yes |
|
|||
24 | > [extensions] |
|
|||
25 | > pager = |
|
|||
26 | > [pager] |
|
|||
27 | > pager = sed -e 's/^/P/' |
|
|||
28 | > attend = printa |
|
|||
29 | > [alias] |
|
|||
30 | > printa = log -T "$A\n" -r 0 |
|
|||
31 | > EOF |
|
|||
32 |
|
||||
33 | $ A=1 chg printa |
|
|||
34 | P1 |
|
|||
35 | $ A=2 chg printa |
|
|||
36 | P2 |
|
|||
37 |
|
||||
38 | $ cp $HGRCPATH.orig $HGRCPATH |
|
18 | $ cp $HGRCPATH.orig $HGRCPATH | |
39 | $ cd .. |
|
19 | $ cd .. | |
40 |
|
20 |
@@ -189,3 +189,15 b' Pager works with shell aliases.' | |||||
189 | a |
|
189 | a | |
190 | $ hg --config pager.attend-echoa=yes echoa |
|
190 | $ hg --config pager.attend-echoa=yes echoa | |
191 | paged! 'a\n' |
|
191 | paged! 'a\n' | |
|
192 | ||||
|
193 | Pager works with hg aliases including environment variables. | |||
|
194 | ||||
|
195 | $ cat >> $HGRCPATH <<'EOF' | |||
|
196 | > [alias] | |||
|
197 | > printa = log -T "$A\n" -r 0 | |||
|
198 | > EOF | |||
|
199 | ||||
|
200 | $ A=1 hg --config pager.attend-printa=yes printa | |||
|
201 | paged! '1\n' | |||
|
202 | $ A=2 hg --config pager.attend-printa=yes printa | |||
|
203 | paged! '2\n' |
General Comments 0
You need to be logged in to leave comments.
Login now