1

I have a collection of scripts setting in a directory. These scripts have relative paths that when run from this directory work correctly. I've been asked to gather these up and put them into a new directory.

These scripts execute a command to run Matlab (an engineering analysis/simulation too) that relies on the relative paths. Is there a way to alter the script so that when the Matlab executable is run and the relative paths are maintained?

Thanx in advance.

1
  • If you moved everything (scripts and sub directories) I suppose it would work. IMO it is best to move your scripts to /usr/local/ , /usr/local/bin should be on your path for example, and to use the full path in your scripts. Should be easy to do with sed or similar. IMHO any files outside your home should be owned by root .
    – Panther
    Jan 9, 2018 at 2:35

0

You must log in to answer this question.

Browse other questions tagged .