Skip to content

Commit

Permalink
Add mac specific tasks to homemaker.
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom Manville committed Jan 12, 2016
1 parent da7bb9b commit 6eaa8ec
Show file tree
Hide file tree
Showing 4 changed files with 90 additions and 3 deletions.
10 changes: 7 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,20 @@ http://linuxg.net/how-to-install-vim-7-4-on-ubuntu-13-10-13-04-12-04-linux-mint-
cd
git clone [email protected]:tdmanv/dotfiles.git
```
### Install dotfiles using homemaker
### Install dotfiles using homemaker
If go is installed
```
GOPATH=$(pwd) go get github.com/FooSoft/homemaker
cd dotfiles
GOPATH=$(pwd)/go go get github.com/FooSoft/homemaker
./go/bin/homemaker --verbose --task=bash --variant=mac config.toml .
```
or
```
cd dotfiles
wget https://foosoft.net/projects/homemaker/dl/homemaker_linux_amd64.tar.gz
tar xvf ./homemaker_linux_amd64.tar.gz
./homemaker_linux_amd64/homemaker
./homemaker_linux_amd64/homemaker --verbose --task=bash --variant=mac config.toml .
```


29 changes: 29 additions & 0 deletions bashrc__mac
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# some more ls aliases
alias ls='ls -G'
alias ll='ls -alF'
alias la='ls -A'
alias l='ls -CF'

# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.

if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi

# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if [ -f /etc/bash_completion ] && ! shopt -oq posix; then
. /etc/bash_completion
fi


# Enables git completion if the file exists.
if [ -f ~/.git-completion.bash ]; then
. ~/.git-completion.bash
fi
PS1='[\[\e[1;34m\]\t\[\e[m\]]\[\e[1;32m\]\u@\h\[\e[m\]:\[\e[1;35m\]\w/\[\e[m\] '
set -o vi
9 changes: 9 additions & 0 deletions config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
[macros.install]
prefix = ["sudo", "apt-get", "install", "-y"]

# Not implemented
[macros.install__mac]
prefix = ["INVALID_COMMAND", "ABORT"]

[macros.clone]
prefix = ["git", "clone"]

Expand Down Expand Up @@ -31,6 +35,8 @@
#
[tasks.bash]
links = [["${HM_DEST}/.bashrc", "bashrc"]]
[tasks.bash__mac]
links = [["${HM_DEST}/.bashrc", "bashrc__mac"]]

[tasks.git]
cmds = [["@install", "git"]]
Expand All @@ -40,6 +46,9 @@
cmds = [["@install", "tmux"]]
links = [["${HM_DEST}/.tmux.conf", "tmux.conf"]]

[tasks.tmux__mac]
links = [["${HM_DEST}/.tmux.conf", "tmux.conf__mac"]]

[tasks.tmux_powerline]
cmds = [
["wget", "https://github.com/Lokaltog/powerline/raw/develop/font/PowerlineSymbols.otf", "https://github.com/Lokaltog/powerline/raw/develop/font/10-powerline-symbols.conf"],
Expand Down
45 changes: 45 additions & 0 deletions tmux.conf__mac
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
LANG="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_CTYPE="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_ALL="en_US.UTF-8"

# enable utf-8 on status bar
set -g status on
set -g status-utf8 on

unbind C-b
set -g prefix C-a

unbind %
bind | split-window -h
bind - split-window -v

set-window-option -g mode-keys vi

bind C-h select-pane -L
bind C-j select-pane -D
bind C-k select-pane -U
bind C-l select-pane -R

#set -g default-terminal "xterm"
#sudo pip install git+git://github.com/Lokaltog/powerline
source /usr/local/lib/python2.7/dist-packages/powerline/bindings/tmux/powerline.conf
#source ~/.local/lib/python2.7/site-packages/powerline/bindings/tmux/powerline.conf

set-option -g default-terminal "screen-256color"

# Set window notifications
setw -g monitor-activity on
set -g visual-activity on

set -g history-limit 50000

# Copy tmux buffer to system clipboard
#bind y run-shell "tmux show-buffer | xclip -sel clip -i" \; display-message "Copied tmux buffer to system clipboard"
bind y run-shell "tmux show-buffer | pbcopy" \; display-message "Copied tmux buffer to system clipboard"


0 comments on commit 6eaa8ec

Please sign in to comment.