Add Windows + Git Bash support via winget manifests, zsh handoff, and standalone bootstrap script#2
Add Windows + Git Bash support via winget manifests, zsh handoff, and standalone bootstrap script#2
Conversation
Co-authored-by: mkhnsn <10660565+mkhnsn@users.noreply.github.com>
Co-authored-by: mkhnsn <10660565+mkhnsn@users.noreply.github.com>
Co-authored-by: mkhnsn <10660565+mkhnsn@users.noreply.github.com>
|
@copilot can we add a windows version of a bootstrap script also? something that can be downloaded standalone, and run as a shell script in normal cmd to get everything set up, including installing git bash, etc. |
Co-authored-by: mkhnsn <10660565+mkhnsn@users.noreply.github.com>
Added Usage: iwr -useb https://raw.githubusercontent.com/mkhnsn/dotfiles/main/install.ps1 | iexThe script will:
After running, open Git Bash from the Start Menu and it will automatically launch zsh with your configuration. Commit: e5b14c5 |
Co-authored-by: mkhnsn <10660565+mkhnsn@users.noreply.github.com>
|
Closing — speculative Copilot-generated Windows support, never verified on a Windows machine and no active need. Can revisit if/when Windows becomes a real target. |
Adds Windows bootstrap support that reuses the existing zsh configuration structure. Git Bash auto-launches zsh on Windows; all existing macOS/Linux behavior is preserved.
Implementation
Package manifests (
manifests/windows/)common.txt/windows-only.txt- winget package IDs (one per line, comments allowed){{ hostname }}.txtWindows package installer (
run_onchange_install-windows.ps1.tmpl)winget install --id <ID> --exact --silentGit Bash zsh setup (
run_onchange_10-setup-gitbash-zsh.sh.tmpl)pacman -S --noconfirm zshZsh auto-launch (
dot_bashrc.tmpl)$ZSH_VERSIONcheckWindows environment (
dot_config/shell/env.windows.zsh)env.zshonly when$OSTYPEmatchesmsys|cygwin|mingwStandalone Windows bootstrap script (
install.ps1)Usage:
Modified files
dot_config/shell/env.zsh- Added 9 lines at top for Windows/MSYS detection:README.md- Added Windows installation instructions and updated repository structure documentation.All other files (
.zshrc, existingrun_onchange_*scripts,aliases.zsh,functions.zsh) are untouched.Flow
Windows (via standalone script): Run
install.ps1→ installs Git for Windows, chezmoi → runschezmoi apply→ winget installs packages → zsh installed in Git Bash → Git Bash auto-launches zshWindows (via chezmoi):
chezmoi apply→ winget installs packages → zsh installed in Git Bash →.bashrcauto-launches zsh →.zshrcloadsenv.zsh→env.zshsourcesenv.windows.zshmacOS/Linux: Windows templates don't render (conditional), OSTYPE check fails, no behavior change
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.