This role is being deprecated in favor of ansible-collection-slickshell.
Collection on Galaxy: drew1kun.slickshell
Cross-platform ansible role for installing and configuring zsh with oh-my-zsh
There is a choice between powerlevel10k and powerlevel9k Default oh-my-zsh theme is powerlevel10k
If only p10k
is set to yes
, then p9k
will not be installed and configured.
It is not recommended to set p9k
only to yes
, because it's slow).
If both p9k
and p10k
are set to yes
, then p10k
will be used but the p9k
style will be sourced.
If installed both, but want to turn p9k
off, then comment the following line in ~/.zshrc:
source ${HOME}/.zsh/omz_powerlevel9k.cfg
In combination with ansible-macterm role getting the following results(assuming you are using p9k or p10k+p9k combo):
NOTE: Role requires Fact Gathering by ansible!
One of the following OS (or deriviatives):
- Debian | Ubuntu
- MacOS (with Homebrew)
For MacOS: if Homebrew is not installed on the managed host, install the following role via galaxy:
ansible-galaxy install geerlingguy.homebrew
And include it in the playbook:
roles:
- geerlingguy.homebrew
OS-Agnostic:
Variable | Description | Default |
---|---|---|
ohmyzsh_install_dir |
Directory oh-my-zsh to be installed in | /usr/local/share/ohmyzsh |
ohmyzsh_custom_aliases |
File containing custom shell config | $HOME/.zsh/aliases.local |
ohmyzsh_powerlevel10k |
Whether to install powerlevel10k theme or not | yes |
ohmyzsh_powerlevel9k |
Whether to install powerlevel9k theme or not | yes |
ohmyzsh_powerlevel9k_cfg |
Path to powerlevel9k config file | ${HOME}/.zsh/omz_powerlevel9k.cfg |
ohmyzsh_users[] |
List of users to install zsh/oh-my-zsh for | see defaults/main.yml |
ohmyzsh_default_theme |
Default theme to be configured for users which do not have theme specified | robbyrussell |
ohmyzsh_default_plugins[] |
The list of plugins for oh-my-zhs to be installed | see defaults/main.yml |
ohmyzsh_custom_plugins[] |
The list of custom plugins for oh-my-zhs to be installed | see defaults/main.yml |
OS-Specific:
Variable | Description | Default |
---|---|---|
ohmyzsh_root_dir |
Root directory |
|
ohmyzsh_home_dir |
User's home directory |
|
ohmyzsh_zprofile_dir |
Zsh profile directory |
|
None
- hosts: dev_clients_macos
gather_facts: yes
roles:
- geerlingguy.homebrew
- drew1kun.ohmyzsh
Andrew Shagayev | e-mail