1 |
On Wed, 2002-02-06 at 09:56, Peter Foley wrote: |
2 |
> Hello, |
3 |
> |
4 |
> Just a quick question. I havent done much shell scripting but I was curious |
5 |
> if this line |
6 |
> |
7 |
> (Taken from CVS : /gentoo-src/rc-scripts/init.d/net.et0) |
8 |
> ********** |
9 |
> if [ -n "$gateway" ] && [ "${gateway%/*}" = "$IFACE" ] |
10 |
> ********** |
11 |
> |
12 |
> Checks to see if the gateway variable has two items in it like |
13 |
> |
14 |
> (Taken from CVS : /gentoo-src/rc-scripts/etc/conf.d/net) |
15 |
> ********** |
16 |
> #gateway="eth0/192.168.0.1" |
17 |
> ********** |
18 |
> |
19 |
> and if it does not have two items does it default to the current device in |
20 |
> the net file. |
21 |
> |
22 |
> Ie. if it is net.eth0 then it would default to "dev eth0" and if it was in |
23 |
> the net.eth1 file then it would default to "dev eth1" |
24 |
> |
25 |
|
26 |
Only problem i see with this, is that most people these days |
27 |
have more than one eth?, so that approach (which we had by the |
28 |
way), set it more than once. |
29 |
|
30 |
And come on ... it is 4 more letters to type :) |
31 |
|
32 |
> Peter. |
33 |
> |
34 |
-- |
35 |
|
36 |
Martin Schlemmer |
37 |
Gentoo Linux Developer, Desktop Team Developer |
38 |
Cape Town, South Africa |