Closed rrthomas closed 1 year ago
I used this to to ensure that the current working dir is the hpmor base.
If there is a more elegant way to do it, I am happy to change it.
Alternatively, instead of cd to that dir, I could perform a check for the presence of "chapters/" dir in current dir and exit if not found.
I think the simplest change here is the "more elegant way" I suggest in number 2 above; does that work for you? It should be correct, but I wonder why a more complicated command was used before…
Thanks for pointing this out, fix is proposed in https://github.com/rrthomas/hpmor/pull/136
Thanks, this fixes things for me, closing.
The ebook scripts contain the idiom:
There are two problems here:
script_dir
used as a prefix to paths where needed.cd
outputs text to stdout when it matches an entry inCDPATH
. I have.
in myCDPATH
, so most times I usecd
, there is output. This breaks the script. It would of course be possible just to unsetCDPATH
, but is there some reason why the line above can't be replaced with just:? (WFM!)