From de34995d880c0018212ed04e71020bdee49df590 Mon Sep 17 00:00:00 2001 From: Recolic Keghart <root@recolic.net> Date: Thu, 9 May 2019 01:58:51 -0700 Subject: [PATCH] working --- on_gnome_start.sh | 29 ----------------------------- 1 file changed, 29 deletions(-) delete mode 100644 on_gnome_start.sh diff --git a/on_gnome_start.sh b/on_gnome_start.sh deleted file mode 100644 index c72cdce..0000000 --- a/on_gnome_start.sh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/bash -# This script should be run after gnome being started. - -_my_path="$0" -secret_file="$1" - -[[ "$secret_file" = '' ]] && echo "Usage: $0 <secret_file>" && exit 1 - -function where_is_him () { - SOURCE="$1" - while [ -h "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink - DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )" - SOURCE="$(readlink "$SOURCE")" - [[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE" # if $SOURCE was a relative symlink, we need to resolve it relative to the path where the symlink file was located - done - DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )" - echo -n "$DIR" - } - -function where_am_i () { - where_is_him "$_my_path" -} - -cd `where_am_i` && -gpg --decrypt "$secret_file" | bin/unlock_keyrings --secret-file - # --quiet - -exit $? - - -- GitLab