| Hash | Commit message | Author | Date | Files | + | - |
1 | commit 072670721d3db78da128b132490d01bcbb99944e |
2 | Author: Connor Etherington <[email protected]> |
3 | Date: Tue May 16 17:45:13 2023 +0200 |
4 | |
5 | Auto-Commit Update - 20230516 |
6 | --- |
7 | PKGBUILD | 2 +- |
8 | usr/bin/snip | 8 ++++---- |
9 | 2 files changed, 5 insertions(+), 5 deletions(-) |
10 | |
11 | diff --git a/PKGBUILD b/PKGBUILD |
12 | index 127ed47..599a6c7 100644 |
13 | --- a/PKGBUILD |
14 | +++ b/PKGBUILD |
15 | @@ -1,7 +1,7 @@ |
16 | # Maintainer: Connor Etherington <[email protected]> |
17 | # --- |
18 | pkgname=snip |
19 | -pkgver=1.1.3 |
20 | +pkgver=1.1.4 |
21 | pkgrel=1 |
22 | pkgdesc="A simple snippet manager for your predefined Ultisnips Snippet Directory" |
23 | arch=(any) |
24 | diff --git a/usr/bin/snip b/usr/bin/snip |
25 | index 0b50e09..49db368 100755 |
26 | --- a/usr/bin/snip |
27 | +++ b/usr/bin/snip |
28 | @@ -6,7 +6,7 @@ |
29 | # Globals: |
30 | |
31 | TITLE=' ~ Snip Snippet Editor ~' |
32 | -SNIPDATA="${XDG_DATA_HOME:-$HOME/.local/share}/snip" |
33 | +SNIPDATA="${XDG_CONFIG_HOME:-$HOME/.config}/snip" |
34 | |
35 | err(){ echo -e "\n\n[-] ERROR:[0;1m ${*}" && exit 1 ; } |
36 | |
37 | @@ -75,10 +75,10 @@ firstRun(){ |
38 | SNIPDIR=$(dialog \ |
39 | --stdout \ |
40 | --title "$TITLE " \ |
41 | - --inputbox "\\n Please enter your local vim snippets directory (if you have one) :\\n\\n\\nNOTE: This will only be asked once, after which, can be changed by editing the config file located at '${SNIPDATA}/sniprc'\\n\\nLeave blank for default ( ~/.config/nvim/snippets ).\\n " 18 97 |
42 | + --inputbox "\\n Please enter your local Ultisnips snippets directory (if you have one) :\\n\\n\\nNOTE: This will only be asked once, after which, can be changed by editing the config file located at '${SNIPDATA}/sniprc'\\n\\nLeave blank for default ( ~/.config/snip/snippets ).\\n " 18 97 |
43 | ) || err "User Exited." |
44 | |
45 | -[[ -n "${SNIPDIR}" ]] || SNIPDIR="${XDG_CONFIG_HOME:-$HOME/.config}/nvim/snippets" |
46 | +[[ -n "${SNIPDIR}" ]] || SNIPDIR="${XDG_CONFIG_HOME:-$HOME/.config}/snip/snippets" |
47 | [ -d ${SNIPDIR} ] || mkdir -p ${SNIPDIR} || err "Please check you have sufficient premissions to create directory at $SNIPDIR " |
48 | |
49 | SNIPDIR="$(realpath ${SNIPDIR})" |
50 | @@ -127,7 +127,7 @@ checkNet(){ \ |
51 | |
52 | ## Prerequisites: |
53 | |
54 | -! cat ${XDG_DATA_HOME:-$HOME/.local}/snip/sniprc|grep -q SNIPDIR >/dev/null 2>&1 && ! firstRun && checkNet |
55 | +! cat ${SNIPDATA}/sniprc|grep -q SNIPDIR >/dev/null 2>&1 && ! firstRun && checkNet |
56 | |
57 | source ${SNIPDATA}/sniprc >/dev/null 2>&1 |
58 | |