powsybl / powsybl-core

A framework to build power system oriented software
https://www.powsybl.org
Mozilla Public License 2.0
123 stars 39 forks source link

Make itools compatible with MacOS #1558

Open mathbagu opened 3 years ago

mathbagu commented 3 years ago

Currently, we get the bin directory in our linux scripts using installBinDir=$(dirname $(readlink -f $0)). The -f option of readlink doesn't exist on MacOS. This options aims to follow recursively the symbolic links. I think the main use-cases are:

I think no user have a link to the itools itself. Eventually, a user could have a link to an intermediate folder:

itools-v3.7.0
itools-v3.8.0
latest -> itools-v3.8.0

In that case, the user could run itools using ~/itools/latest/bin/itools.

For these reasons, I propose to remove the -f option that should solve the issue.

mathbagu commented 3 years ago

In the same time, I propose to fix also powsyblsh and the install.sh script (see #734)