summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorRasmus Steinke2017-09-07 17:40:12 +0200
committerRasmus Steinke2017-09-07 17:40:12 +0200
commit97fc3d9f90d8650880e151ca2163757a3e81d251 (patch)
tree5b7321c22b73f5479efd3b3b484a73886b430882
parent4d3fc6db1f0123c721ad2db784f141ff603bb51d (diff)
downloadaur-97fc3d9f90d8650880e151ca2163757a3e81d251.tar.gz
add clerk_setup script. add perl-module-install make dependency
-rw-r--r--clerk-git.install8
-rwxr-xr-xclerk_setup15
2 files changed, 23 insertions, 0 deletions
diff --git a/clerk-git.install b/clerk-git.install
index b9860b14de69..969a4296723d 100644
--- a/clerk-git.install
+++ b/clerk-git.install
@@ -3,6 +3,14 @@ post_install() {
echo '
to use clerk you need to copy /usr/share/doc/clerk/clerk.conf and clerk.tmux to $HOME/.config/clerk/
and edit it to your needs.
+You can also run clerk_setup to create a default config for your user.
'
}
+
+post_upgrade() {
+echo '
+Keep in mind, that clerk-git now installs the perl version which comes with its own config.
+Copy /usr/share/doc/clerk/clerk.tmux and /usr/share/doc/clerk/clerk.conf to $HOME/.config/clerk
+and edit them to your needs.
+Or run clerk_setup (as user) to automate these steps.
#post_install
diff --git a/clerk_setup b/clerk_setup
new file mode 100755
index 000000000000..2334c246fdcb
--- /dev/null
+++ b/clerk_setup
@@ -0,0 +1,15 @@
+#!/usr/bin/env bash
+
+read -e -p "Create configuration for clerk? (Y/n) > " install
+install=${install:-y}
+case $install in
+ [Yy]) cp clerk $path;
+ if [[ ! -d "${HOME}/.config/clerk" ]]
+ then
+ mkdir "${HOME}/.config/clerk"
+ fi
+ cp /usr/share/doc/clerk/clerk.tmux /usr/share/doc/clerk/clerk.conf "${HOME}/.config/clerk"
+ sed -i "s@PLACEHOLDER@"$HOME"@" "${HOME}/.config/clerk/clerk.conf"
+ ;;
+ *) exit;
+esac