search for: derectory

Displaying 1 result from an estimated 1 matches for "derectory".

2009 Mar 24
3
How to find the path or the current file?
...cated in the directory 'conf', a sibling of 'bin'. I can have somethings like readLines('../conf/terms.conf') in search.R, but this work only if search.R is executed from bin, when getwd is 'bin'. But when search.R calls from the parent as bin/search.R or any other derectory then R complains that it could not find the file '../conf/terms.conf'. So my questions is: how can the file search.R, when executied, discover its own location and load terms.conf from <location of search.R>/../conf/terms.conf? the location of search.R can be unrelated to the curre...