summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorManuel Amago <mamago@gmail.com>2016-08-10 17:32:47 +0100
committerManuel Amago <mamago@gmail.com>2016-08-10 17:32:47 +0100
commit04770be267d79757426ace930b563e94210a35dc (patch)
treeea7edbd1fc1f69cedc78920a0363166a8b14c3e9
parentabc2509e9205306305a9d098abaaaaf351274de0 (diff)
downloaddotfiles-04770be267d79757426ace930b563e94210a35dc.tar.gz
dotfiles-04770be267d79757426ace930b563e94210a35dc.zip
Add install script
Creates home directory dot file symlinks to the repository files.
-rw-r--r--dot-emacs5
-rw-r--r--dot-profile9
-rwxr-xr-xinstall.sh22
3 files changed, 27 insertions, 9 deletions
diff --git a/dot-emacs b/dot-emacs
index b4837d6..0291c63 100644
--- a/dot-emacs
+++ b/dot-emacs
@@ -23,6 +23,11 @@
(define-key key-translation-map (kbd "£") "#") ; hash
(define-key key-translation-map (kbd "H-3") (kbd "£")) ; pound
+;; Disable C-z - background process
+;; Unbind Pesky Sleep Button
+(global-unset-key [(control z)])
+(global-unset-key [(control x)(control z)])
+
;; IDO for auto-completion
(ido-mode 1)
(setq ido-enable-flex-matching t)
diff --git a/dot-profile b/dot-profile
index d6d3e87..08e60cd 100644
--- a/dot-profile
+++ b/dot-profile
@@ -24,12 +24,3 @@ alias egrep='egrep --color=auto'
alias ll='ls -alF'
alias la='ls -A'
alias l='ls -CF'
-
-##
-# Your previous /Users/mamago/.profile file was backed up as /Users/mamago/.profile.macports-saved_2014-11-02_at_10:11:49
-##
-
-# MacPorts Installer addition on 2014-11-02_at_10:11:49: adding an appropriate PATH variable for use with MacPorts.
-export PATH="/opt/local/bin:/opt/local/sbin:$PATH"
-# Finished adapting your PATH environment variable for use with MacPorts.
-
diff --git a/install.sh b/install.sh
new file mode 100755
index 0000000..7d1d2fe
--- /dev/null
+++ b/install.sh
@@ -0,0 +1,22 @@
+#!/usr/bin/env bash
+
+# Adapted from https://github.com/torvald/dotfiles
+
+# Create symlinks for all dotfiles
+# Use -f to overwrite existing dotfiles
+
+DOTFILES=$(ls -1 -d $PWD/dot-*)
+
+LN_OPTS="-s"
+if [[ "$1" == "-f" ]]; then
+ LN_OPTS="$LN_OPTS -f"
+fi
+
+for DOTFILE in $DOTFILES; do
+ BASENAME=$(basename $DOTFILE)
+ TARGET="$HOME/${BASENAME/dot-/.}"
+ echo ln $LN_OPTS $DOTFILE $TARGET
+ ln $LN_OPTS $DOTFILE $TARGET
+done
+
+exit $?