[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: to - Bookmark file system locations in bash on POSIX-like systems
From: |
Domingo Ignacio Galdos |
Subject: |
Re: to - Bookmark file system locations in bash on POSIX-like systems |
Date: |
Thu, 4 Apr 2013 21:05:20 -0400 |
Hn, I use a similar tool called ln
In all seriousness what value does or could a tool like this add above ln?
ln -s ~/some/long/path ~/bookmark
cd ~/bookmark
cd ~/bookmark/nested/tab/completion
rm ~/bookmark
Sorry I don't mean that in a snarly way I am curious if you can come up or
have with any additional new ideas that go beyond this...
-Domingo
On Apr 4, 2013 8:36 AM, "Mara Kim" <hacker.root@gmail.com> wrote:
> On Thu, Apr 4, 2013 at 4:27 AM, Chris Down <chris@chrisdown.name> wrote:
> > Hmm, that's interesting and potentially desirable (I think this is the
> first
> > time I've said that on this list!).
>
> It gets downright dangerous once you realize you can use the -p option to
> do things like
> $ vim $(to -p foo/bar.cpp)
>
> I've done a complete refresh of 'to' using symbolic links. Turns out, it's
> a lot simpler (yay!), and seems to mesh better with the conventions of the
> POSIX file system.
>
> Mara
>
>
> On Thu, Apr 4, 2013 at 4:27 AM, Chris Down <chris@chrisdown.name> wrote:
>
> > Hi Mara,
> >
> > On 2013-04-04 03:58, Mara Kim wrote:
> > > What is do you mean specifically by function vs [? Do you mean parens?
> > Is
> > > function a bash-ism?
> >
> > function is a bashism, yes. You can just omit it and your function
> > declarations
> > magically become POSIX.
> >
> > > I am really only enthusiastic about the interface of 'to'. While
> 'jump'
> > > has a faster running time, 'to' lets you move directly to
> subdirectories
> > of
> > > your bookmark. For example, '$ to foo/bar' moves you to the bar
> > directory
> > > under the foo bookmark, with tab completion!
> >
> > Hmm, that's interesting and potentially desirable (I think this is the
> > first
> > time I've said that on this list!).
> >
> > > You are right though, the implementation is a mess. I originally
> wanted
> > to
> > > have a stable filesystem representation of a user's bookmarks (thus,
> the
> > > bookmarks file) so that a user could directly edit the bookmarks, but
> > that
> > > has turned into a messy glob of sed statements. The concept itself is
> so
> > > simple that I think I'm going to reimplement it using a bookmarks
> folder
> > > with symlinks. That would solve all the problems related to filenames,
> > and
> > > most likely provide better running times as well. (*cough* git checkout
> > -b
> > > link)
> >
> > That is a good idea which for some reason slipped my mind. You probably
> > will
> > want to use cd -P.
> >
> > Will probably follow up with a jump implementation using symlinks, I like
> > it. It
> > certainly makes sense since we're dealing with paths anyway.
> >
> > Chris
> >
>
>
>
> --
> M
>
>
>
> --
> M
>
- Re: to - Bookmark file system locations in bash on POSIX-like systems, (continued)
RE: to - Bookmark file system locations in bash on POSIX-like systems, dnade.ext, 2013/04/10
Re: to - Bookmark file system locations in bash on POSIX-like systems, Mara Kim, 2013/04/04
- Re: to - Bookmark file system locations in bash on POSIX-like systems,
Domingo Ignacio Galdos <=
- Re: to - Bookmark file system locations in bash on POSIX-like systems, Chris Down, 2013/04/04
- Re: to - Bookmark file system locations in bash on POSIX-like systems, Mara Kim, 2013/04/04
- Re: to - Bookmark file system locations in bash on POSIX-like systems, Domingo Ignacio Galdos, 2013/04/05
- Re: to - Bookmark file system locations in bash on POSIX-like systems, Chris Down, 2013/04/05
- Re: to - Bookmark file system locations in bash on POSIX-like systems, Mara Kim, 2013/04/05
- Re: to - Bookmark file system locations in bash on POSIX-like systems, Chris Down, 2013/04/06
Re: to - Bookmark file system locations in bash on POSIX-like systems, Greg Wooledge, 2013/04/08