diff options
-rwxr-xr-x | .local/bin/ref-unison.pl | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/.local/bin/ref-unison.pl b/.local/bin/ref-unison.pl new file mode 100755 index 0000000..680960d --- /dev/null +++ b/.local/bin/ref-unison.pl @@ -0,0 +1,39 @@ +#!/usr/local/bin/perl + +use strict; +use warnings; + +use constant { + UNISON_PATH => '/usr/local/bin/unison', + NOTIFY_SEND_PATH => '/usr/local/bin/notify-send' +}; + +sub main +{ + system( + NOTIFY_SEND_PATH, + 'unison', + '-u', + 'low', + 'Synchronizing files...' + ); + system( + UNISON_PATH, + '-ui', + 'text', + '/usr/home/jozan/.local/share/newsboat/cache.db', + 'ssh://root@jozanleclerc.xyz//root/unison/.local/share/newsboat/cache.db' + ); + system( + UNISON_PATH, + '-ui', + 'text', + '/usr/home/jozan/.abook/addressbook', + 'ssh://root@jozanleclerc.xyz//root/unison/.abook/addressbook' + ); + exit 0; +} + +main(); + +__END__ |