changeset 465:74e54b6f183f

Updated files
author unexist
date Thu, 21 Dec 2017 16:12:18 +0100
parents c551e0e1e910
children f0ededb85e16
files .vimrc .zshalias .zshrc
diffstat 3 files changed, 39 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/.vimrc	Fri Mar 04 10:30:25 2016 +0100
+++ b/.vimrc	Thu Dec 21 16:12:18 2017 +0100
@@ -97,6 +97,11 @@
 nmap <silent> <A-h> :wincmd h<CR>
 nmap <silent> <A-l> :wincmd l<CR>
 
+" Disable ex mode
+nnoremap Q <Nop>
+
+" Select all
+map <C-a> <ESC>:%y+<CR>
 
 " Brackets
 "inoremap {      {}<Left>
--- a/.zshalias	Fri Mar 04 10:30:25 2016 +0100
+++ b/.zshalias	Thu Dec 21 16:12:18 2017 +0100
@@ -25,7 +25,9 @@
 
 # Bookmarks
 alias ssh_debian="ssh -X unexist@80.244.246.114 -p 10152"
+alias mosh_debian="mosh --ssh='ssh -X -p 10152' unexist@80.244.246.114"
 alias ssh_kufa="ssh -X kufa@kulturfabrik-krefeld.de"
+alias ssh_new="ssh -x unexist@46.4.209.181"
 
 # Sudo
 if [ -e /usr/bin/sudo ] ; then
@@ -34,16 +36,19 @@
   alias ntpd="sudo ntpdate -b pool.ntp.org"
   alias killjobs="sudo lprm -"
   alias s="sudo"
+  alias doch='sudo $(fc -ln -1)'
 
   # Based on dist
   if [ -e /usr/bin/pacman ] ; then
     alias p="packer --noedit"
     alias I="sudo pacman -S"
     alias R="sudo pacman -R"
+    alias S="pacman -Q"
   elif [ -e /usr/bin/apt-get ] ; then
     alias p="sudo apt-get"
     alias I="sudo apt-get install"
     alias R="sudo apt-get remove"
+    alias S="apt-cache search"
   fi
 fi
 
@@ -54,8 +59,8 @@
 fi
 
 # Calc
-if [ -e /usr/bin/calc ] ; then
-  alias calc='noglob calc'
+if [ -e /usr/bin/concalc ] ; then
+  alias calc='noglob concalc'
 fi
 
 # Mercurial
@@ -89,13 +94,13 @@
 
   if [ $? -eq 0 ] ; then
     alias chrome="$i &>/dev/null &!"
-    alias chromeunsafe="$i --disable-web-security &>/dev/null &!"
+    alias chromeunsafe="$i --disable-web-security --user-data-dir --allow-file-access-from-files --enable-unrestricted-ssl3-fallback --ignore-certificate-errors &>/dev/null &!"
   fi
 done
 
 # Xephyr
 if [ -e /usr/bin/Xephyr ] ; then
-  XEPHYR_OPTS="-ac -noreset -nodri +extension RANDR +xinerama"
+  XEPHYR_OPTS="-ac -noreset +extension RANDR +xinerama"
     #-keybd ephyr,,,xkbmodel=evdev,xkblayout=de"
   alias xeph1024="Xephyr $XEPHYR_OPTS -name xeph1024 -screen 1024x600 :2 &>/dev/null &!"
   alias xeph800="Xephyr $XEPHYR_OPTS -name xeph800 -screen 800x800 :2 &!"
@@ -115,7 +120,7 @@
 # Mplayer
 if [ -f /usr/bin/mplayer ] ; then
   alias dts="mplayer -ac hwdts,hwac3, -ao alsa:device=spdif"
-  alias mp="mplayer -vo x11 -nosound -zoom -fs"
+  alias mp="mplayer -vo x11 -no-audio -zoom -fs"
 fi
 
 # subtle
@@ -141,3 +146,6 @@
 if [ -e "/usr/lib/jvm/default-java" ] ; then
   export JAVA_HOME="/usr/lib/jvm/default-java"
 fi
+
+# PA
+alias louder="pactl -- set-sink-volume 0 "
--- a/.zshrc	Fri Mar 04 10:30:25 2016 +0100
+++ b/.zshrc	Thu Dec 21 16:12:18 2017 +0100
@@ -47,6 +47,7 @@
 unsetopt bang_hist #< Disable inline history
 setopt no_bang_hist
 #setopt menu_complete
+setopt promptsubst
 
 # History
 HISTSIZE=5000
@@ -94,6 +95,9 @@
 {
   for i in "$@"; do
     curl -s -F "image=@$i" -F "key=d159f6eac3eaf0205acbdb5a85ca3659" http://imgur.com/api/upload.xml | grep -E -o "<original_image>(.)*</original_image>" | grep -E -o "http://i.imgur.com/[^<]*"
+    curl -H "Authorization: Client-ID 3e7a4deb7ac67da" -F image=@$i \
+      https://api.imgur.com/3/upload | sed 's/.*http/http/; s/".*/\n/; s,\\/,/,g'
+
   done
 }
 
@@ -142,6 +146,10 @@
   PS1=%1~$'%{\e[36;1m%}%(1j.%%%j.)%{\e[34;1m%} ➤ %{\e[0m%}'
 fi
 
+PS1=$'${(r:$COLUMNS::\u2500:)}'$PS1
+#PS1=$'%{\e(0%}${(r:$COLUMNS::q:)}%{\e(B%}'$PS1
+#PS1=$'${(r:$COLUMNS::-:)}'$PS1
+
 umask 022
 
 # Fix broken locales in arch
@@ -187,7 +195,7 @@
 fi
 
 # Browser
-export BROWSER="/usr/bin/chromium-browser"
+export BROWSER="/usr/bin/chromium"
 
 # Update title
 case $TERM in
@@ -211,9 +219,18 @@
 fi
 
 # RVM
-[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"
+if [ -s "$HOME/.rvm/scripts/rvm" ] ; then
+  source "$HOME/.rvm/scripts/rvm"
 
-PATH=$PATH:$HOME/.rvm/bin # Add RVM to PATH for scripting
+  # Add RVM to PATH for scripting
+  PATH=$PATH:$HOME/.rvm/bin
+fi
+
+# Pebble
+if [ -d $HOME/projects/pebble ] ; then
+  # Add pebble to PATH for scripting
+  PATH=$PATH:$HOME/projects/pebble/pebble-sdk-4.3-linux64/bin
+fi
 
 # JAVA
-export JAVA_HOME="/usr/lib/jvm/java-7-openjdk-amd64"
+export JAVA_HOME="/usr/lib/jvm/java-8-openjdk-amd64"