Skip to content

support setting symlinks on macos. - #4

Open
realtimeprojects wants to merge 1 commit into
python-ffmpegio:mainfrom
realtimeprojects:symlinksmac
Open

realtimeprojects wants to merge 1 commit into
python-ffmpegio:mainfrom
realtimeprojects:symlinksmac

Conversation

@realtimeprojects

Copy link
Copy Markdown
Contributor

on macos, the perfered location for the symlinks is the directory where the ffdl binary is installed, since

~/.local/bin is not supported by default.

I did not want to change the behaviour on linux systems as well as anyway reuse the linux version of set_symlinks since it works file on mac, too.

@realtimeprojects realtimeprojects changed the title support setting symlings on macos. Dec 9, 2022
@tikuma-lsuhsc

Copy link
Copy Markdown
Contributor

@realtimeprojects - I'm OK to expand on your suggestion, but I'm not sure if setting path.dirname(sys.executable) is a good generic option. I'd like to set the default location of symlinks to be somewhere which (1) is inside user's directory and (2) typically contains other binary file symlinks. I could not find such location in macos. Therefore, I left it NotImplementedError (though I forgot to update the help text).

Back to path.dirname(sys.executable), I have two issues with this: (1) this default poses a possibility of adding symlinks to a venv folder, and I prefer not to add symlinks to a folder which is under control of other program and (2) it makes ffdl to make symlinks in a system folder (thus requiring preceding sudo) which infringes with the 1st condition above.

All this being said, introducing a --symlink_dir to allow user to specify a destination (i.e., to provide target argument of the set_symlinks() in your PR) is a viable solution. If you could modify the PR towards this direction, please do. Otherwise, I'll come back to it later when I have time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants