9fans archive / 2008 / 10 / 409 /    prev next

From: "Steve Simon" <steve@qui...>
Subject: Re: [9fans] @{cd ...} breaks completion with ctrl-f/ins; help needed
Date: Tue, 28 Oct 2008 10:04:57 +0000

> I issue
> ; @{cd lib}
> 
> then lc, pwd seems to be ok, lists/returns my home directory,

This makes sense to me - though I am not saying its "correct".

When you cd in interactive mode rc(1) writes the path to the
directory into /dev/wdir. This informs rio of your current dir
so it can do the filename completion (and also gives the directory
context to the plumber).

I guess the @{ } "execute in a subshell" code in rc could save and restore
the current directory, however this is only an issue in interactive mode.
I have never needed @{ } interactively so I have not had this problem.

probably the best way to get things back in sync is:

	cd `{pwd}

-Steve