APS-Networks / APS-One-touch

12 stars 9 forks source link

All path in config file are relative to user home directory #9

Closed ralfkundel closed 3 years ago

ralfkundel commented 3 years ago

Hi, while trying to install a tofino in /opt/bf-sde-9.3.0/... i found out that this is not possible easily.

The reason is: all path configurations in the yaml are relative to the current users home director ("get_path_relative_to_user_home").

Idea: if a path in the config file starts with a backslash("\") --> don't use the users home directory. In all other cases, i think it would be fine.

kamalkrbh commented 3 years ago

@ralfkundel Have you tried setting PATH_PREFIX in settings.yaml ? For your case if you set PATH_PREFIX to /opt/ or just '/' and give rest of the paths accordingly the get_path_relative_to_user_home function will append value of PATH_PREFIX instead of USER_HOME.

ralfkundel commented 3 years ago

Totally overseen. Thanks ;-)