pandemonium1986.ohmyzsh
Ansible角色:OhMyZsh
为任何用户安装和配置oh-my-zsh。
要求
此角色是自包含的。如果需要,会为Debian、Ubuntu、OpenSUSE、SLES、CentOS安装zsh和git包。
角色变量
来自defaults/main.yml:
ohmyzsh_users:
- user_name: pandemonium
user_group: pandemonium
user_home: /home/pandemonium/
ohmyzsh_config:
- { regexp: '^ZSH_THEME="robbyrussell"$', line: 'ZSH_THEME="agnoster"' }
- { regexp: '^# ENABLE_CORRECTION="true"$', line: 'ENABLE_CORRECTION="true"' }
- { regexp: '^plugins=\(.*\)', line: "plugins=({{ ohmyzsh_plugins }})" }
ohmyzsh_plugins: >-
ansible
colored-man-pages
composer
debian
docker
docker-compose
extract
git
git-flow
history
kubectl
minikube
ssh-agent
vagrant
zsh-autosuggestions
zsh-syntax-highlighting
来自vars/[distro|familly]-[os_familly]-[os_version].yml(取决于发行版):
_packages:
- git
- sudo
- zsh
依赖
无。
示例剧本
- name: OhMyZsh剧本
hosts: pandama
become: true
become_method: sudo
become_user: root
tasks:
- import_role:
name: pandemonium1986.ohmyzsh
警告:请不要忘记在你的ansible.cfg中将pipeling设置为True,以绕过文件成为非特权用户
许可证
该项目根据MIT许可证授权 - 详细信息见LICENSE文件
作者信息
- Jérémy Baumgarth - 最初工作 - jebovic
- Michael Maffait - 定制 - Pandemonium1986