changeset 4:2c7cac745457

* Add git config * Add SSH public key
author IBBoard <dev@ibboard.co.uk>
date Sat, 27 Jul 2013 20:32:10 +0100
parents 2a6d32a03c0e
children 17c094cc54e3
files gitconfig setup.sh
diffstat 2 files changed, 32 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gitconfig	Sat Jul 27 20:32:10 2013 +0100
@@ -0,0 +1,18 @@
+[user]
+	name = IBBoard
+	email = dev@ibboard.co.uk
+[branch]
+	autosetupmerge = true
+[diff]
+[merge]
+	tool = meld
+[mergetool "meld"]
+	cmd = meld \\\"$BASE\\\" \\\"$LOCAL\\\" \\\"$REMOTE\\\"
+[diff]
+	tool = meld
+[difftool "meld"]
+	cmd = meld \"\" \"\"
+[difftool]
+	prompt = false
+[push]
+	default = simple
--- a/setup.sh	Sat Jul 27 20:19:21 2013 +0100
+++ b/setup.sh	Sat Jul 27 20:32:10 2013 +0100
@@ -14,7 +14,20 @@
 	#Else it already existed but was correct
 }
 
+add_content() {
+	if [ -e $2 ]; then
+		grep -F -q "$1" $2 2>&1
+	else
+		false
+	fi
+	if [ $? -ne 0 ]; then
+		echo "$1" >> $2
+	fi
+}
+
 create_symlink tmux.conf ~/.tmux.conf
 create_symlink hgrc ~/.hgrc
 create_symlink bashrc ~/.bashrc
-create_symlink /usr/lib/python*/site-packages/hgext/hgview.py ~/.hgview.py
\ No newline at end of file
+create_symlink /usr/lib/python*/site-packages/hgext/hgview.py ~/.hgview.py
+create_symlink gitconfig ~/.gitconfig
+add_content "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC2c3IUHY02FAJotQKs3x+uGZ+5XpuKbWUENevjTOF1bAGwGqKNSSg5SlsL5C9aHcu6O/eBKWJNpvUa0vcXXP18ddoILq1DvZfQHDylrweGbaRviSCpRZvSKiNREQd+yAQPwGnsfkpQe5RxXjRTsk7B0VKP2LFL5seDuQfQxtGc6AgjF0TMpBoKD3UkUlfqRX7Q0tQwfTgXTNxYyQOgG61bWeUsz0XSZelF1MHsXxLwUUFuZAigwiv9YUlBSAAEwWySyN8RdsJadunKYHbxr9cJfj4T5soKVeDi2n94AScFuokAyDf3MFvJ1PYZ0p4rFzNF2zrOK3rqvA3aGg4Bi+wx ssh@ibboard.co.uk" ~/.ssh/authorized_keys
\ No newline at end of file