mirror of
https://github.com/Matir/skel.git
synced 2026-05-25 21:19:09 -07:00
Merge remote-tracking branch 'vdesktop/master'
This commit is contained in:
@@ -8,10 +8,13 @@ alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo
|
||||
alias luksFormat='cryptsetup luksFormat -s 512 -c aes-xts-plain64 -h sha256 -i 15000'
|
||||
|
||||
# Colors
|
||||
if [ `uname` != 'Darwin' ] ; then
|
||||
# Should have a better way to check for GNU versions
|
||||
alias ls='ls --color=auto'
|
||||
alias grep='grep --color=auto'
|
||||
alias egrep='egrep --color=auto'
|
||||
alias fgrep='fgrep --color=auto'
|
||||
fi
|
||||
|
||||
# Easy upgrade
|
||||
alias dist-upgrade="sudo sh -c 'apt-get update && apt-get -y dist-upgrade'"
|
||||
|
||||
@@ -20,9 +20,13 @@ esac
|
||||
autoload -U colors && colors
|
||||
PS1="%{$fg[black]%}[%{$fg[yellow]%}%h%{$fg[black]%}] %{%(!.$fg[red].$fg[green])%}%8>..>%n%>>%{$fg[white]%}@%{$fg[blue]%}%12>..>%m%>>%{$fg[white]%}:%{$fg[green]%}%32<...<%~%<<%{$fg[white]%}%#%{$reset_color%} "
|
||||
|
||||
# LS Colors
|
||||
if [ `uname` != 'Darwin' ] ; then
|
||||
# ls Colors
|
||||
alias ls='ls --color'
|
||||
zstyle ':completion:*:default' list-colors ${(s.:.)LS_COLORS}
|
||||
else
|
||||
alias ls='ls -G'
|
||||
fi
|
||||
|
||||
# Load oh-my-zsh
|
||||
if [ -d $HOME/.oh-my-zsh ] ; then
|
||||
|
||||
11
install.sh
11
install.sh
@@ -3,6 +3,13 @@
|
||||
set -o nounset
|
||||
set -o errexit
|
||||
|
||||
FINDTYPE="-xtype"
|
||||
|
||||
if [ `uname` == 'Darwin' ] ; then
|
||||
# MacOS specifics
|
||||
FINDTYPE="-type"
|
||||
fi
|
||||
|
||||
function prerequisites {
|
||||
if which zsh > /dev/null 2>&1 ; then
|
||||
if [[ $- == *i* ]] ; then
|
||||
@@ -30,7 +37,7 @@ function install_dotfile_dir {
|
||||
-name install.sh -o \
|
||||
-name README.md -o \
|
||||
-name .gitignore \) \
|
||||
-prune -o -xtype f -print | \
|
||||
-prune -o ${FINDTYPE} f -print | \
|
||||
while read dotfile ; do
|
||||
local TARGET="${HOME}/.${dotfile#${SRCDIR}/}"
|
||||
mkdir -p `dirname "${TARGET}"`
|
||||
@@ -42,7 +49,7 @@ function install_basic_dir {
|
||||
local SRCDIR="${1}"
|
||||
local DESTDIR="${2}"
|
||||
local file
|
||||
find "${SRCDIR}" -xtype f -print | \
|
||||
find "${SRCDIR}" ${FINDTYPE} f -print | \
|
||||
while read file ; do
|
||||
local TARGET="${2}/${file#${SRCDIR}/}"
|
||||
mkdir -p `dirname "${TARGET}"`
|
||||
|
||||
Reference in New Issue
Block a user