Personal shell configuration files and environment settings for macOS/Linux development environments.
This repository contains my personal dotfiles including shell configurations (bash/zsh), terminal multiplexer settings (tmux), and various development environment configurations. The setup is optimized for software development with features like git-aware prompts, modern shell options, and convenient aliases.
- Bash: Enhanced history, safety aliases, git-aware prompt, OS-specific configurations
- Zsh: Modern shell options, auto-completion, directory navigation shortcuts, git integration
- Cross-platform: Works on macOS, Linux, and Cygwin
- Tmux: Custom key bindings, enhanced status bar, optimized for development workflows
- Git completion and branch information in prompts
- Docker shortcuts and utilities
- Node.js (nvm), Ruby (rvm), Rust, Python (virtualenv) support
- Google Cloud SDK integration
- Kubernetes (kubectl) completion
- Git
- GNU Stow
macOS:
brew install stow
Linux (Ubuntu/Debian):
sudo apt-get install stow
Linux (CentOS/RHEL):
sudo yum install stow
- Clone the repository:
git clone https://github.com/yourusername/dotfiles.git ~/dotfiles
cd ~/dotfiles
- Create symlinks using GNU Stow:
make link
- Reload your shell:
# For bash
source ~/.bashrc
# For zsh
source ~/.zshrc
# Create symlinks manually
stow --target=$HOME .
If you have existing dotfiles you want to replace:
make adopt
File | Purpose |
---|---|
.bashrc |
Bash shell configuration, aliases, and functions |
.zshrc |
Zsh shell configuration with modern features |
.zshenv |
Zsh environment variables and PATH settings |
.bash_profile |
Bash login shell configuration |
.tmux.conf |
Tmux terminal multiplexer configuration |
.gitignore |
Files to ignore in this repository |
.profile |
POSIX shell profile |
.stow-global-ignore |
Files for Stow to ignore when symlinking |
- Enhanced history: 50K entries with timestamps and deduplication
- Safety aliases: Interactive prompts for
rm
,cp
,mv
- Git integration: Branch information in prompt
- OS detection: Platform-specific aliases and settings
- Development tools: Integration with Docker, Node.js, Python, etc.
- Modern shell options: Auto-completion, directory navigation, history management
- Git-aware prompt: Shows branch name and status indicators
- Smart aliases: Directory shortcuts, safety features, productivity helpers
- Performance optimized: Fast startup with efficient plugin loading
- Custom prefix:
Ctrl-g
(better for Emacs users) - Intuitive bindings:
|
for horizontal split,-
for vertical split - Enhanced status bar: Shows session, user, and system information
- Mouse support: Enabled for modern terminal interaction
The configurations support loading additional personal files:
Bash:
~/.bash_profile_ps
- PostScript/work-specific settings~/.bash_profile_do
- DigitalOcean-specific settings~/.bash_profile_personal
- Personal settings~/.bash_linux
- Linux-specific settings~/.bash_osx
- macOS-specific settings
Zsh:
You can add custom configurations at the end of .zshrc
or create separate files and source them.
Set environment variables in:
.zshenv
(for zsh).bash_profile
(for bash)
ll
- Long listing with human-readable sizesla
- List all files including hidden..
,...
,....
- Navigate up directoriesdev
- Quick navigate to development directoryc
- Clear terminalweather
- Get weather for NYC
rm='rm -i'
- Interactive removecp='cp -i'
- Interactive copymv='mv -i'
- Interactive move
tmux='tmux -2'
- Force 256 color modeec
- Open file in Emacs clientgbp
- Git branch and push function
Both bash and zsh prompts show git information:
- Current branch name
*
indicates uncommitted changes+
indicates untracked files
If you get conflicts when running make link
:
# Backup existing files and adopt them
make adopt
Ensure proper permissions:
chmod 600 ~/.bashrc ~/.zshrc
Install missing tools as needed:
# macOS
brew install git stow tmux
# Linux
sudo apt-get install git stow tmux
Licensed under the BSD License. See the repository for full license details.
Feel free to fork this repository and adapt it to your needs. Pull requests for improvements are welcome!