merge to top
authorPeng Li <seudut@gmail.com>
Fri, 24 Jul 2015 01:56:56 +0000 (09:56 +0800)
committerPeng Li <seudut@gmail.com>
Fri, 24 Jul 2015 01:56:56 +0000 (09:56 +0800)
emacs.d/init.el
scripts/update_cpve.pl
vim/vimrc
zsh/zshrc

index db66bf7..ca3d88c 100644 (file)
 (require 'linum-relative)
 
 (custom-set-variables
- '(fringe-mode (quote (4 . 0)) nil (fringe)))
+ ;; custom-set-variables was added by Custom.
+ ;; If you edit it by hand, you could mess it up, so be careful.
+ ;; Your init file should contain only one such instance.
+ ;; If there is more than one, they won't work right.
+ '(fringe-mode (quote (4 . 0)) nil (fringe))
+ '(ggtags-split-window-function (quote split-window-vertically))
+ '(org-agenda-files (quote ("~/temp/org-note.org")))
+ '(powerline-text-scale-factor 0.85))
 
 ;; maybe better to fix the size of line number rather scaled 0.8
 ;; https://github.com/howardabrams/dot-files/blob/master/emacs.org
 (custom-set-faces
+ ;; custom-set-faces was added by Custom.
+ ;; If you edit it by hand, you could mess it up, so be careful.
+ ;; Your init file should contain only one such instance.
+ ;; If there is more than one, they won't work right.
  '(highlight-current-line-face ((t (:background "gray22"))))
  '(linum ((t (:background "#000000" :foreground "gray40" :height 0.8 :slant italic :weigth light))))
- '(linum-relative-current-face ((t (:inherit linum :foreground "Yellow" :weight light :height 0.8)))))
+ '(linum-relative-current-face ((t (:inherit linum :foreground "Yellow" :weight light :height 0.8))))
+ '(mode-line ((t (:foreground "#030303" :background "#bdbdbd" :box nil :family "Source Code Pro for Powerline" :height 100))))
+ '(mode-line-inactive ((t (:foreground "#f9f9f9" :background "#666666" :box nil :family "Source Code Pro for Powerline" :height 100)))))
 
 
 ;; enable linum-relative in programming mode
index ab2360a..6f55555 100755 (executable)
@@ -10,40 +10,43 @@ print "-n $options{n}\n" if defined $options{n};
 
 my $ip = (split / /, `ifconfig | grep "inet .*broadcast"`)[1];
 
+my $cpve_dir = '/Users/peli3/CPVE/cpve_trunk/';
+my $ecc_dir = '/Users/peli3/JCC/ecc-p2p/';
+
+
+#### 
 if($options{n})
 {
     print "==== don't build CPVE ======\n";
 }
 else 
 {    
-    print "building cpve\n";
-    chdir '/Users/peli3/CPVE/cpve_trunk' or die ": $!";
+    ## building CPVE
+    chdir $cpve_dir or die ": $!";
     !system "scons arch=x86_64 platform=darwin debug=True -j16 osxversion=10.10"    or die "building CPVE failed : $!";
 
-    chdir '/Users/peli3/JCC/ecc-p2p' or die ": $!";
-    print "remove cpve libs\n";
-    !system "rm -rf ./contrib/cpve/lib/darwin/x86_64/*"     or die "remove libs failed : $!";
+    ## remove old cpve libs and replace in ECC
+    !system "rm -rf $ecc_dir/contrib/cpve/lib/darwin/x86_64/*"     or die "remove libs failed : $!";
 
-    print "copy cpve libs\n";
-    !system "/bin/cp -r /Users/peli3/CPVE/cpve_trunk/target/dist/lib/darwin/x86_64/* ./contrib/cpve/lib/darwin/x86_64/"     or die "copy libs failed: $!";
+    !system "/bin/cp -r $cpve_dir/target/dist/lib/darwin/x86_64/* $ecc_dir/contrib/cpve/lib/darwin/x86_64/"     or die "copy libs failed: $!";
 
 }
 
-print "building ecc\n";
+#### building ecc
+chdir $ecc_dir or die ": $!";
 !system "python runSconsBuild.py JabberMac64Bit  -j 16  -t no --early_cpve"     or die " building ECC failed : $!";
 
 print "copy bin-s bin-c\n";
-###system "rm -rf bin-s binn-c";
-!system "/bin/cp -r out/bin ./bin-c" or die "$!";
-!system "/bin/cp -r out/bin ./bin-s" or die "$!";
+!system "rm -rf bin-s/* bin-c/*" or die "$!";
+!system "/bin/cp -r $ecc_dir/out/bin/* $ecc_dir/bin-c" or die "$!";
+!system "/bin/cp -r $ecc_dir/out/bin/* $ecc_dir/bin-s" or die "$!";
 
 print "copy config files\n";
-!system "/bin/cp ./sss.txt  ./bin-s/cucm-credentials.txt" or die ": $!";
-!system "/bin/cp ./ccc.txt  ./bin-c/cucm-credentials.txt" or die ": $!";
+!system "/bin/cp $ecc_dir/sss.txt  $ecc_dir/bin-s/cucm-credentials.txt" or die ": $!";
+!system "/bin/cp $ecc_dir/ccc.txt  $ecc_dir/bin-c/cucm-credentials.txt" or die ": $!";
 
 print "add p2p server ip\n";
-open CONF, ">>", './bin-c/cucm-credentials.txt' or  die "error $!";
-#print CONF "P2P_SERVER_IP=" . &get_local_ip . "\n";
+open CONF, ">>", "$ecc_dir/bin-c/cucm-credentials.txt" or  die "error $!";
 print CONF "P2P_SERVER_IP=" . $ip . "\n";
 close CONF;
 
@@ -56,3 +59,4 @@ print "####### DONE #######\n";
 ##    return @cc[1];
 #}
 
+#print CONF "P2P_SERVER_IP=" . &get_local_ip . "\n";
index 0ced4ca..2971615 100644 (file)
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -463,14 +463,14 @@ map ee <Plug>(easymotion-w)
 map el <Plug>(easymotion-lineforward)
 map eh <Plug>(easymotion-linebackward)
 
-map <SPACE>n <Plug>(easymotion-sn)
-map <SPACE>j <Plug>(easymotion-j)
-map <SPACE>k <Plug>(easymotion-k)
-map <SPACE>b <Plug>(easymotion-b)
-map <SPACE>w <Plug>(easymotion-w)
-map <SPACE>e <Plug>(easymotion-w)
-map <SPACE>l <Plug>(easymotion-lineforward)
-map <SPACE>h <Plug>(easymotion-linebackward)
+"map <SPACE>n <Plug>(easymotion-sn)
+"map <SPACE>j <Plug>(easymotion-j)
+"map <SPACE>k <Plug>(easymotion-k)
+"map <SPACE>b <Plug>(easymotion-b)
+"map <SPACE>w <Plug>(easymotion-w)
+"map <SPACE>e <Plug>(easymotion-w)
+"map <SPACE>l <Plug>(easymotion-lineforward)
+"map <SPACE>h <Plug>(easymotion-linebackward)
 
 "" }}}
 " vim-latex --------------------------------------------------------------- {{{
@@ -517,6 +517,10 @@ autocmd FileType vim setlocal foldmethod=marker |
        \ setlocal formatoptions-=c formatoptions-=r formatoptions-=o |
     \ let b:AutoClosePairs = AutoClose#DefaultPairsModified("", "{} \"")
 
+autocmd FileType perl setlocal foldmethod=syntax |
+    \ let b:AutoClosePairs = AutoClose#DefaultPairsModified("\"", "{}") |
+       \ inoremap <buffer> { {<CR>}<ESC>kA<CR>
+
 autocmd Filetype markdown setlocal textwidth=80
 
 autocmd CmdwinEnter * map <buffer> q :q<CR>
@@ -629,7 +633,7 @@ nnoremap \d :call DiffToggle()<CR>
 " }}}
 
 "nnoremap <silent> <Space> @=(foldlevel('.')?'za':"\<Space>")<CR>
-nnoremap <silent> <Space> @=(foldlevel('.')?'za':"\<Space>")<CR>
+nnoremap <silent> <cr> @=(foldlevel('.')?'za':"\<Space>")<CR>
 "noremap <Leader>d     @=(&diff)?':diffoff':":VCSVimDiff"<CR><CR>
 
 " https://bitbucket.org/sjl/dotfiles/src/tip/vim/vimrc
index 518238f..b0e3857 100644 (file)
--- a/zsh/zshrc
+++ b/zsh/zshrc
@@ -211,3 +211,5 @@ export ZSHHOME="$HOME/.zsh"
 [[ -s `brew --prefix`/etc/autojump.sh ]] && . `brew --prefix`/etc/autojump.sh
 
 alias emacs='TERM=xterm-256color emacs -nw'
+
+alias tw='open -a /Applications/TextWrangler.app/'