This repository contains my personal configuration files (dotfiles) for tools and environments I use daily. These dotfiles are organized for efficient management using GNU Stow.
The repository is organized as follows:
dotfiles/
├── tmux/
│ └── .tmux.conf
├── nvim/
│ └── .config/nvim/init.lua
├── git/
│ └── .gitconfig
├── fish/
│ └── .config/fish/config.fish
tmux/
: Configuration for tmux.nvim/
: Configuration for Neovim.git/
: Global Git configurations.fish/
: Configuration for Fish.
Before using these dotfiles, ensure the following tools are installed:
sudo apt update
sudo apt install build-essential curl file git -y
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
Add PATH of Homebrew to bash shell:
echo 'eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"' >> ~/.bashrc
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
git clone https://github.com/ryanoasis/nerd-fonts.git
cd nerd-fonts
./install.sh Hack
git clone git@github.com:ThongVu1996/dotfiles.git ~/dotfiles
cd ~/dotfiles
brew bundle --file=Brewfile
Note: If you use WSL in Windows, you must install WezTerm in Windows. Do not use WezTerm installed by brew.
brew bundle dump --file=Brewfile
brew bundle dump --force --file=Brewfile
echo /usr/bin/fish | sudo tee -a /etc/shells
chsh -s /usr/bin/fish
fish
Create symlink
ln -s ~/dotfiles/fish/.config/fish/config.fish ~/.config/fish/config.fish
source ~/.config/fish/config.fish
Note: Close and reopen the terminal.
stow tmux
stow nvim
stow wezterm -- Don't need if you use wsl
If you want to remove a configuration, use:
stow -D <folder_name>
Example:
stow -D tmux
Here’s how my terminal looks after applying these configurations:
- Simplified dotfiles management using GNU Stow.
- Easy to customize and extend for other tools.
- Supports configurations for tmux, Neovim, Git, and Zsh.
Set Windows to Use Local Time:
sudo timedatectl set-timezone your_time_zone
Example
sudo timedatectl set-timezone America/New_York
or
sudo timedatectl set-timezone Asia/Ho_Chi_Minh
Restart your computer.
Verify Time in WSL:
date
Install Required Tools:
sudo apt update
sudo apt install sysstat procps
Create Scripts for CPU and RAM Usage:
echo '#!/bin/bash
top -bn1 | grep "Cpu(s)" | sed "s/.*, *\([0-9.]*\)%* id.*/\1/" | awk "{print int(100 - \$1)}"' > ~/.tmux/cpu_usage.sh
chmod +x ~/.tmux/cpu_usage.sh
echo '#!/bin/bash
free | grep Mem | awk "{print int(\$3/\$2 * 100.0)}"' > ~/.tmux/ram_usage.sh
chmod +x ~/.tmux/ram_usage.sh
Update tmux.conf
:
set -g status-right "#(~/.tmux/cpu_usage.sh)% CPU | #(~/.tmux/ram_usage.sh)% RAM | %H:%M"
Reload tmux Configuration:
tmux source-file ~/.tmux.conf
Contributions are welcome! Feel free to fork this repository and submit a pull request with your improvements.
This project is licensed under the MIT License. See the LICENSE file for details.