Skip to content

Create directory when no LaunchAgents directory doens't exist  #11

@tbille

Description

@tbille

When running the python install script on MacOs if the LaunchAgents doesn't exists yet the script fails.

https://github.com/ilyatbn/aws_alwayson/blob/master/aosvc-python/install_mac.sh#L4

➜  aosvc-python git:(master) ./install_mac.sh 
+ launch_config_dir=/Users/toto/Library/LaunchAgents
+ launch_config_path=/Users/toto/Library/LaunchAgents/com.github.ilyatbn.aws_alwayson.plist
+ service_path=/Users/toto/.local/share/aosvc/bin
++ id -u
+ user_uid=502
+ mkdir -p /Users/toto/.local/share/aosvc/bin
+ cp aosvc /Users/toto/.local/share/aosvc/bin
+ cp aosvc.plist /Users/toto/Library/LaunchAgents/com.github.ilyatbn.aws_alwayson.plist
cp: /Users/toto/Library/LaunchAgents/com.github.ilyatbn.aws_alwayson.plist: No such file or directory

The current fix is to manually create the directory and re-run the script.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions