Various updates
This commit is contained in:
parent
f1cbe81655
commit
f02cb843aa
9
aliases
9
aliases
|
@ -1,3 +1,8 @@
|
|||
#
|
||||
# Note: this may contain windows line ended. If you're going to use it in Linux then you'll need
|
||||
# to remove those with: sed -i 's/\r//' <file>
|
||||
#
|
||||
|
||||
# Handle the fact that this file will be used with multiple OSs
|
||||
platform=`uname`
|
||||
if [[ $platform == 'Linux' ]]; then
|
||||
|
@ -121,7 +126,8 @@ alias rcc='rclone copy'
|
|||
|
||||
function reload {
|
||||
if [[ $platform == 'Linux' || $platform == 'Darwin' ]]; then
|
||||
source ~/.zshrc
|
||||
#source ~/.zshrc
|
||||
test -f ~/.aliases && . ~/.aliases
|
||||
else
|
||||
test -f ~/.aliases && . ~/.aliases
|
||||
fi
|
||||
|
@ -347,6 +353,7 @@ alias gfix="git commit --amend -C HEAD"
|
|||
alias gfixx="git commit --amend -C HEAD ; gp -f"
|
||||
alias gfixs="git commit -S -a --amend -C HEAD" # signed
|
||||
alias gfo='git fetch origin'
|
||||
alias gfu='git fetch up'
|
||||
alias gfm='git fetch origin master'
|
||||
alias gfup='git fetch upstream'
|
||||
alias ggrep='git log --all --oneline | grep '
|
||||
|
|
|
@ -3,9 +3,6 @@
|
|||
# Unbreak broken, non-colored terminal
|
||||
export TERM=xterm-256color
|
||||
|
||||
# Don't use ^D to exit
|
||||
set -o ignoreeof
|
||||
|
||||
# For Windows setup
|
||||
test -f ~/.functions && . ~/.functions
|
||||
test -f ~/.aliases && . ~/.aliases
|
||||
|
@ -64,3 +61,27 @@ cd ~
|
|||
export NVM_DIR="$HOME/.nvm"
|
||||
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
|
||||
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
||||
|
||||
# Don't use ^D to exit
|
||||
set -o ignoreeof
|
||||
|
||||
# don't put duplicate lines or lines starting with space in the history.
|
||||
# See bash(1) for more options
|
||||
HISTCONTROL=ignoreboth
|
||||
|
||||
# append to the history file, don't overwrite it
|
||||
shopt -s histappend
|
||||
|
||||
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
|
||||
HISTSIZE=1000
|
||||
HISTFILESIZE=2000
|
||||
|
||||
# check the window size after each command and, if necessary,
|
||||
# update the values of LINES and COLUMNS.
|
||||
shopt -s checkwinsize
|
||||
|
||||
# make less more friendly for non-text input files, see lesspipe(1)
|
||||
[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
|
||||
|
||||
# colored GCC warnings and errors
|
||||
export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
|
10
install
10
install
|
@ -1,14 +1,16 @@
|
|||
#!/bin/bash
|
||||
|
||||
source "script_helpers/all.sh"
|
||||
source "$HOME/.dotfiles/script_helpers/all.sh"
|
||||
|
||||
set -e
|
||||
|
||||
cwd=$PWD
|
||||
platform=`uname`
|
||||
|
||||
echo platform: $platform
|
||||
|
||||
os_is_windows is_windows
|
||||
if [[ $is_windows -eq 0 ]]; then
|
||||
if [[ $is_windows -eq 1 ]]; then
|
||||
error "This is only supported on Linux or MacOS.\n"
|
||||
exit 1
|
||||
fi
|
||||
|
@ -43,6 +45,9 @@ setup_git() {
|
|||
|
||||
setup_zsh() {
|
||||
printf "Setting up zsh...\n"
|
||||
|
||||
sudo apt install zsh
|
||||
|
||||
TEST_CURRENT_SHELL=$(expr "$SHELL" : '.*/\(.*\)')
|
||||
if [ "$TEST_CURRENT_SHELL" != "zsh" ]; then
|
||||
if hash chsh >/dev/null 2>&1; then
|
||||
|
@ -85,7 +90,6 @@ setup_misc() {
|
|||
|
||||
FILES=()
|
||||
FILES+=('curlrc')
|
||||
FILES+=('racketrc')
|
||||
|
||||
for file in "${FILES[@]}"
|
||||
do
|
||||
|
|
|
@ -1,2 +1,4 @@
|
|||
[code]
|
||||
editor = vim
|
||||
[core]
|
||||
autocrlf = true
|
||||
|
|
|
@ -186,8 +186,8 @@ link_file() {
|
|||
! test -d "$source_path" && ! test -e "$source_path" && error "Source path '$source_path' doesn't exist!" && abort
|
||||
|
||||
# Verify that the dest path doesn't already exist.
|
||||
test -d "$dest_path" && error "Dest folder '$dest_path' already exists!" && abort
|
||||
test -e "$dest_path" && error "Dest file '$dest_path' already exists!" && abort
|
||||
test -d "$dest_path" && error "Dest folder '$dest_path' already exists!\n" && return
|
||||
test -e "$dest_path" && error "Dest file '$dest_path' already exists!\n" && return
|
||||
|
||||
if [[ $is_windows -eq 1 ]]; then
|
||||
source_path=$(unix_to_windows_path "$source_path")
|
||||
|
|
3
vimrc
3
vimrc
|
@ -226,7 +226,8 @@ if IsWindows()
|
|||
" Just assume we don't have a zsh shell
|
||||
set shell=bash
|
||||
else
|
||||
set shell=zsh
|
||||
"set shell=zsh
|
||||
set shell=bash
|
||||
endif
|
||||
|
||||
set t_ti= t_te= " Prevent Vim from clobbering the scrollback buffer. See http://www.shallowsky.com/linux/noaltscreen.html
|
||||
|
|
|
@ -95,6 +95,10 @@ processor time and is generally useless.
|
|||
* Setup git completions for bash:
|
||||
* `curl https://raw.githubusercontent.com/git/git/master/contrib/completion/git-completion.bash -o ~/.git-completion.bash`
|
||||
|
||||
### 32-bit dev tools
|
||||
* Load a 32-bit shell
|
||||
* Install toolchain: `pacman -S mingw-w64-i686-toolchain`
|
||||
|
||||
## Setting up dev tools
|
||||
|
||||
* Download the Windows 2003 Resource Kit in order to get tools like `list.exe` (command line hex
|
||||
|
|
4
zshrc
4
zshrc
|
@ -40,9 +40,9 @@ prompt grb
|
|||
# Linux specific config
|
||||
if [[ $platform == 'Linux' ]]; then
|
||||
# Set caps to ctrl
|
||||
setxkbmap -option 'caps:ctrl_modifier'
|
||||
#setxkbmap -option 'caps:ctrl_modifier'
|
||||
# Make caps act as Esc when tapped. Require `xcape` package.
|
||||
xcape -e 'Caps_Lock=Escape'
|
||||
#xcape -e 'Caps_Lock=Escape'
|
||||
fi
|
||||
|
||||
# Autoload things before calling compinit
|
||||
|
|
Loading…
Reference in New Issue
Block a user