chore: mac specific fixes
parent
16a5456fd7
commit
73e9243bec
|
|
@ -1,15 +1,18 @@
|
||||||
#!/bin/env bash
|
#!/bin/env bash
|
||||||
|
|
||||||
export LINUX_BREW_PATH="/home/linuxbrew/.linuxbrew";
|
export LINUX_BREW_PATH="/home/linuxbrew/.linuxbrew";
|
||||||
|
export MAC_BREW_PATH="/usr/local/Homebrew";
|
||||||
|
|
||||||
if ! [[ -d "${LINUX_BREW_PATH}" ]]; then
|
if [[ ! -d "${LINUX_BREW_PATH}" && ! -d "${MAC_BREW_PATH}" ]]; then
|
||||||
|
echo "Installing brew";
|
||||||
curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh -o /tmp/brew_install.sh;
|
curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh -o /tmp/brew_install.sh;
|
||||||
chmod +x /tmp/brew_install.sh;
|
chmod +x /tmp/brew_install.sh;
|
||||||
/tmp/brew_install.sh;
|
/tmp/brew_install.sh;
|
||||||
rm -rf /tmp/brew_install.sh;
|
rm -rf /tmp/brew_install.sh;
|
||||||
fi
|
fi
|
||||||
|
|
||||||
[[ -f "${LINUX_BREW_PATH}/bin/brew" ]] && eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)";
|
[[ -f "${LINUX_BREW_PATH}/bin/brew" ]] && eval "$(${LINUX_BREW_PATH}/bin/brew shellenv)";
|
||||||
|
[[ -f "${MAC_BREW_PATH}/bin/brew" ]] && eval "$(${MAC_BREW_PATH}/bin/brew shellenv)";
|
||||||
|
|
||||||
[[ -f "$(brew --prefix bash-completion)/etc/bash_completion" ]] || brew install bash-completion
|
[[ -f "$(brew --prefix bash-completion)/etc/bash_completion" ]] || brew install bash-completion
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -96,7 +96,7 @@ function targz() {
|
||||||
# Usage: `json '{"foo":42}'` or `echo '{"foo":42}' | json`
|
# Usage: `json '{"foo":42}'` or `echo '{"foo":42}' | json`
|
||||||
function json() {
|
function json() {
|
||||||
if [ -t 0 ]; then # argument
|
if [ -t 0 ]; then # argument
|
||||||
python -mjson.tool <<< "$*" | pygmentize -l javascript;
|
python -mjson.tool < "$*" | pygmentize -l javascript;
|
||||||
else # pipe
|
else # pipe
|
||||||
python -mjson.tool | pygmentize -l javascript;
|
python -mjson.tool | pygmentize -l javascript;
|
||||||
fi;
|
fi;
|
||||||
|
|
@ -120,7 +120,7 @@ function gitio() {
|
||||||
}
|
}
|
||||||
|
|
||||||
# list files
|
# list files
|
||||||
alias ll='ls -hGla --color'
|
alias ll='ls -hGla'
|
||||||
|
|
||||||
#git
|
#git
|
||||||
alias gs='git status'
|
alias gs='git status'
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ set nocompatible
|
||||||
|
|
||||||
"color schemes
|
"color schemes
|
||||||
"colorscheme torte
|
"colorscheme torte
|
||||||
"colorscheme jellybeans
|
colorscheme jellybeans
|
||||||
"colorscheme molokai
|
"colorscheme molokai
|
||||||
"colorscheme wombat256i
|
"colorscheme wombat256i
|
||||||
"colorscheme dragon-energy
|
"colorscheme dragon-energy
|
||||||
|
|
@ -373,4 +373,4 @@ au GUIEnter * set vb t_vb=
|
||||||
if has('gui_running')
|
if has('gui_running')
|
||||||
set go =mt
|
set go =mt
|
||||||
set guifont=Literation\ Mono\ for\ Powerline:h12,Literation_Mono_for_Powerline:h12,Inconsolata\ for\ Powerline:h10,Ubuntu\ Mono:h26,Consolas:h12,Courier:h12
|
set guifont=Literation\ Mono\ for\ Powerline:h12,Literation_Mono_for_Powerline:h12,Inconsolata\ for\ Powerline:h10,Ubuntu\ Mono:h26,Consolas:h12,Courier:h12
|
||||||
endif
|
endif
|
||||||
|
|
@ -55,9 +55,9 @@ if [[ -d "${FILES_USER_CONFIG}/vim" ]]; then
|
||||||
|
|
||||||
vim_setup() {
|
vim_setup() {
|
||||||
! [[ -f ${HOME}/.vimrc ]] && ln -sf ${VIM}/.vimrc ${HOME}/.vimrc;
|
! [[ -f ${HOME}/.vimrc ]] && ln -sf ${VIM}/.vimrc ${HOME}/.vimrc;
|
||||||
mkdir -p ${VIM}/backups;
|
mkdir -p ${VIM}/backups;
|
||||||
mkdir -p ${VIM}/swaps;
|
mkdir -p ${VIM}/swaps;
|
||||||
mkdir -p ${VIM}/undo;
|
mkdir -p ${VIM}/undo;
|
||||||
|
|
||||||
vim_setup_config;
|
vim_setup_config;
|
||||||
vim_setup_runtime;
|
vim_setup_runtime;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue