Skip to content

Set up dotfiles repository with GNU Stow structure and installation script - #1

Merged
zoro11031 merged 3 commits into
mainfrom
copilot/add-dotfiles-repo
Oct 23, 2025
Merged

Set up dotfiles repository with GNU Stow structure and installation script#1
zoro11031 merged 3 commits into
mainfrom
copilot/add-dotfiles-repo

Conversation

Copilot AI commented Oct 23, 2025

Copy link
Copy Markdown
Contributor

This PR sets up a complete dotfiles repository that can be synced via git across multiple machines using GNU Stow for symlink management.

Overview

The repository now contains organized configuration files (dotfiles) for common development tools, structured in a way that makes it easy to install, manage, and synchronize settings across different machines.

What's Included

Configuration Packages

Each directory represents a "package" that can be independently installed using GNU Stow:

  • bash/ - Bash shell configuration with colorized prompts, history settings, common aliases (ll, la, grep), and bash completion support
  • git/ - Git configuration with useful aliases (st, co, br, ci, lg, unstage), color output, and sensible defaults
  • vim/ - Vim text editor setup with syntax highlighting, line numbers, smart indentation, and search settings
  • zsh/ - Zsh shell configuration with history management, completion system, and colorized prompts
  • tmux/ - Tmux terminal multiplexer with custom prefix (Ctrl-a), mouse support, and intuitive pane splitting

Installation Script

The install.sh script provides an easy way to manage dotfiles:

  • Automatically checks for GNU Stow availability
  • Supports installing all packages or specific ones: ./install.sh bash git
  • Uninstall packages: ./install.sh --uninstall bash
  • Reinstall packages: ./install.sh --reinstall
  • Colored output with success/error indicators

Documentation

The README.md includes:

  • Prerequisites and GNU Stow installation instructions for Ubuntu/Debian, macOS, and Arch Linux
  • Repository structure explanation
  • Installation and usage examples
  • Syncing workflow for multiple machines
  • Troubleshooting guide for common issues like file conflicts

Repository Management

  • .gitignore - Excludes OS files, backups, secrets, and temporary files
  • .stow-local-ignore - Controls which files stow ignores when creating symlinks (excludes README, LICENSE, install.sh, etc.)
  • .gitkeep files - Preserves empty configuration directories in git

Usage Example

# Clone the repository
git clone https://github.com/zoro11031/dotfiles.git ~/dotfiles
cd ~/dotfiles

# Install all dotfiles
./install.sh

# Or install specific packages
./install.sh bash git vim

# Sync changes across machines
git pull && ./install.sh --reinstall

Customization

Each configuration supports local customizations that won't be tracked in git:

  • Bash: Create ~/.bashrc.local for machine-specific settings
  • Zsh: Create ~/.zshrc.local for machine-specific settings

These local files are automatically sourced if they exist, allowing you to keep machine-specific configurations separate from shared dotfiles.

Benefits

  • Easy synchronization: Commit changes once, pull and reinstall on other machines
  • Modular design: Install only the packages you need
  • Safe installation: GNU Stow creates symlinks, so original files in the repo remain untouched
  • Conflict detection: The installation script warns about existing files before creating symlinks
  • Version control: Track all configuration changes with git history

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • esm.ubuntu.com
    • Triggering command: /usr/lib/apt/methods/https (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Original prompt

Repo for my dotfiles which will be synced via git


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: zoro11031 <57109577+zoro11031@users.noreply.github.com>
@zoro11031
zoro11031 marked this pull request as ready for review October 23, 2025 16:35
@zoro11031

Copy link
Copy Markdown
Owner

@copilot Whoops I think I marked this as ready for review early. Keep working

Co-authored-by: zoro11031 <57109577+zoro11031@users.noreply.github.com>
Copilot AI changed the title [WIP] Add dotfiles repository for git synchronization Set up dotfiles repository with GNU Stow structure and installation script Oct 23, 2025
Copilot AI requested a review from zoro11031 October 23, 2025 16:41
@zoro11031
zoro11031 merged commit f1e773a into main Oct 23, 2025
1 of 2 checks passed
@zoro11031
zoro11031 deleted the copilot/add-dotfiles-repo branch October 24, 2025 17:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants