1 |
That works yes. |
2 |
A bit much to typw though. Don't know if I'd save much time from first doing |
3 |
a locate and the manually typing the cd [result] string :) |
4 |
|
5 |
Martin S |
6 |
|
7 |
2007/5/11, Neil Bothwick <neil@××××××××××.uk>: |
8 |
> |
9 |
> On Fri, 11 May 2007 14:34:44 +0200, Martin S wrote: |
10 |
> |
11 |
> > Just recently tried using |
12 |
> > |
13 |
> > locate foo.conf | cd |
14 |
> > |
15 |
> > to automagically move to the directory in which I've saved foo.conf |
16 |
> > Of course it didn't work as you can't cd to /bar/foo.conf |
17 |
> > |
18 |
> > I didn't find a way to dropping the actual file name from the result of |
19 |
> > locate. |
20 |
> |
21 |
> cd $(dirname $(locate foo.conf)) |
22 |
> |
23 |
> -- |
24 |
> Neil Bothwick |
25 |
> |
26 |
> WinErr 010: Reserved for future mistakes by our developers |
27 |
> |
28 |
> |
29 |
|
30 |
|
31 |
-- |
32 |
Regards, |
33 |
|
34 |
Martin S |