Skip to content
Prev 376896 / 398502 Next

Genuine relative paths with R

Actually there is a difference between:

  1.  Directly executing the file by the user by double clicking on the "physical" file (you can only do that from the directory where the file is located), without going through any terminal, and
  2.  Executing this file "remotely" by calling it through a terminal for instance.

________________________________
De : R-help <r-help-bounces at r-project.org> de la part de Olivier GIVAUDAN <olivier_givaudan at hotmail.com>
Envoy? : mercredi 10 octobre 2018 20:42
? : Duncan Murdoch; Jeff Newmiller
Cc : r-help at r-project.org
Objet : Re: [R] Genuine relative paths with R

Why are you not simply double-clicking on 'TestPWD' and choosing to execute the file (don't add anything)?
Are you executing the file from a terminal?
________________________________
De : Duncan Murdoch <murdoch.duncan at gmail.com>
Envoy? : mercredi 10 octobre 2018 20:17
? : Olivier GIVAUDAN; Jeff Newmiller
Cc : r-help at r-project.org
Objet : Re: [R] Genuine relative paths with R
On 10/10/2018 3:51 PM, Olivier GIVAUDAN wrote:
When I execute that, it prints my working directory.  Doesn't matter
where the TestPWD file is.  If I put it in directory "foo", and change
to foo's parent, then

   foo/TestPWD

prints the name of the parent directory, not the foo directory.  If I
then add foo to the PATH, and run

   TestPWD

I get the same thing.  I find it unbelievable that you are seeing
anything different from that on a Unix-alike.

Duncan Muroch
______________________________________________
R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Message-ID: <DB3PR0202MB33554654F5276A0D53C13A0DF5E00@DB3PR0202MB3355.eurprd02.prod.outlook.com>
In-Reply-To: <DB3PR0202MB3355EAB3948B25F5CC5A4DECF5E00@DB3PR0202MB3355.eurprd02.prod.outlook.com>

Thread (35 messages)

Jeff Newmiller Genuine relative paths with R Oct 7 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 William Dunlap Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Peter Claussen Genuine relative paths with R Oct 10 Duncan Murdoch Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Olivier GIVAUDAN Genuine relative paths with R Oct 10 Fritsch, Katharina (NNL) Genuine relative paths with R Oct 11 Duncan Murdoch Genuine relative paths with R Oct 11 Michael Friendly Genuine relative paths with R Oct 11 Olivier GIVAUDAN Genuine relative paths with R Oct 18 Olivier GIVAUDAN Genuine relative paths with R Oct 18 Olivier GIVAUDAN Genuine relative paths with R Oct 18 Olivier GIVAUDAN Genuine relative paths with R Oct 18 Fritsch, Katharina (NNL) Genuine relative paths with R Oct 19 Olivier GIVAUDAN Genuine relative paths with R Oct 19