diff options
author | NeodarZ <neodarz@neodarz.net> | 2017-07-30 23:43:32 +0200 |
---|---|---|
committer | NeodarZ <neodarz@neodarz.net> | 2017-07-30 23:43:32 +0200 |
commit | f88eac462e3121e63363e877f763afbfb9d6dda8 (patch) | |
tree | 5dd3f9a9230bc79a16501c35089dac654e2d31eb /stow-services | |
parent | 2d92c02da3d760a0ded8e7612ef003a66e21f554 (diff) | |
download | dotfiles_ascii-f88eac462e3121e63363e877f763afbfb9d6dda8.tar.xz dotfiles_ascii-f88eac462e3121e63363e877f763afbfb9d6dda8.zip |
Add stow service
Diffstat (limited to 'stow-services')
-rwxr-xr-x | stow-services | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/stow-services b/stow-services new file mode 100755 index 0000000..23f1ed9 --- /dev/null +++ b/stow-services @@ -0,0 +1,11 @@ +serviceName=$(echo $1 | cut -d'/' -f'2') +if [[ $1 =~ "/" && $serviceName != "" ]]; then + if [ -f "$1" ]; then + sudo ln -s $(readlink -f $1) /usr/lib/systemd/user/$serviceName + else + echo "Warning ! You must be in the dotfile folder to execute this !" + echo "Sorry the file $1 not found !" + fi +else + echo "Syntax: services/<name of the service" +fi |