1 |
Is there any way to make "pushd" and "popd" (Bash built-ins) silent? As |
2 |
it is, when the execute, the directory is echoed to the output, making |
3 |
it difficult to use the commands in a script. For example: |
4 |
|
5 |
OLD_VER=$(pushd /boot; ls kernel-* | sort | head -1; popd) |
6 |
echo $OLD_VER |
7 |
/boot ~ kernel-2.6.22-gentoo-r2 ~ |
8 |
|
9 |
The /boot and the tildes are returned by pushd and popd and mess up the |
10 |
script. |
11 |
|
12 |
There doesn't seem to be any options to turn off the echo off and shopt |
13 |
has nothing in it. |
14 |
|
15 |
Tony |
16 |
|
17 |
-- |
18 |
Those who would give up essential Liberty, to purchase a little temporary Safety, deserve neither Liberty nor Safety. |
19 |
-- Benjamin Franklin |
20 |
|
21 |
-- |
22 |
gentoo-user@g.o mailing list |