Automated development environment setup for Linux (Debian/Ubuntu) and macOS using Ansible.
Linux (Debian/Ubuntu):
sudo apt update
sudo apt install ansible gitmacOS:
# Install Homebrew if not already installed
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
# Install Ansible
brew install ansible# Clone the repository
git clone https://github.com/marouane-dev75/dev-environment-setup.git
cd dev-environment-setup
# Run the setup (automatically detects your OS)
ansible-playbook site.yml --ask-become-pass- Development Tools: curl, wget, git, vim, htop, ffmpeg, and more
- Terminal: tmux, zsh with oh-my-zsh
- Window Manager: i3 with custom productivity features (Pomodoro timer, GPU monitoring, VPN status)
- GUI Apps: VSCode, Inkscape, GIMP (via snap)
- Package Manager: pnpm for Node.js development
- Fonts: Poppins and Roboto font families
- Package Manager: Homebrew
- Terminal: zsh with oh-my-zsh, tmux, vim
- Window Manager: AeroSpace (tiling window manager)
- GUI Apps: Various productivity and development tools
- Development Tools: Common CLI tools (curl, wget, git, etc.)
ansible-playbook linux/site.yml --ask-become-passansible-playbook macos/site.yml --ask-become-passLinux:
# Install only terminal tools (tmux, zsh)
ansible-playbook linux/site.yml --tags "terminal" --ask-become-pass
# Install only development tools (vim, pnpm)
ansible-playbook linux/site.yml --tags "tools" --ask-become-pass
# Install only window manager (i3)
ansible-playbook linux/site.yml --tags "wm" --ask-become-passmacOS:
# Install only zsh
ansible-playbook macos/site.yml --tags "zsh" --ask-become-pass
# Install only Homebrew
ansible-playbook macos/site.yml --tags "homebrew" --ask-become-passdev-environment-setup/
βββ site.yml # Main playbook (auto-detects OS)
βββ linux/
β βββ site.yml # Linux-specific playbook
β βββ roles/ # Linux roles (i3, snap-apps, etc.)
βββ macos/
βββ site.yml # macOS-specific playbook
βββ roles/ # macOS roles (homebrew, zsh)
- i3 Config: Edit
linux/roles/i3/files/i3/config - i3blocks: Customize
linux/roles/i3/files/i3blocks/config - Vim: Modify
linux/roles/vim/files/vimrc - Tmux: Edit
linux/roles/tmux/files/tmux.conf - Zsh: Update
linux/roles/zsh/files/zshrc
- Zsh: Edit
macos/roles/zsh/files/zshrc
- Permission Denied: Ensure you're running with
--ask-become-pass - i3 Won't Start: Verify X11 is available with
startx i3 - Shell Not Changed: Log out/in or restart terminal after zsh installation
- Homebrew Not Found: Ensure Homebrew is in your PATH. Restart terminal or run:
eval "$(/opt/homebrew/bin/brew shellenv)" # Apple Silicon eval "$(/usr/local/bin/brew shellenv)" # Intel
- Ansible Not Found: Install Ansible via Homebrew:
brew install ansible
common-tools,tools- Core development utilitiessnapd- Snap package manager and appsvim- Vim editortmux,terminal- Terminal multiplexerzsh,terminal- Zsh shelli3,wm- i3 window managerpnpm,nodejs- Node.js package managerfonts,system- Font installation
homebrew,setup- Homebrew package managerzsh,terminal- Zsh shelltmux,terminal- Terminal multiplexervim- Vim editoraerospace- AeroSpace window managergui-apps- GUI applicationscommon-tools,tools- Common development tools
- Common development tools (git, curl, wget, vim, etc.)
- tmux configuration
- pnpm and Node.js setup
- GUI applications via Homebrew Cask (VSCode, etc.)
- Font installation
- Optional window manager (Yabai/Rectangle)
MIT License - Feel free to use and modify as needed.
Contributions are welcome! Please feel free to submit a Pull Request.