Defined Type: ohmyzsh::theme
- Defined in:
- manifests/theme.pp
Overview
Define: ohmyzsh::theme
This is the ohmyzsh module. It installs oh-my-zsh for a user and changes their shell to zsh. It has been tested under Ubuntu.
This module is called ohmyzsh as Puppet does not support hyphens in module names.
oh-my-zsh is a community-driven framework for managing your zsh configuration.
Parameters
set_sh: (boolean) whether to change the user shell to zsh
Authors
Leon Brocard <acme@astray.com> Zan Loy <zan.loy@gmail.com>
Copyright
Copyright 2014
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'manifests/theme.pp', line 24
define ohmyzsh::theme (
String $theme = 'clean',
) {
include ohmyzsh
if $name == 'root' {
$home = '/root'
$group = fact('os.family') ? {
/(Free|Open)BSD/ => 'wheel',
default => 'root',
}
} else {
$home = "${ohmyzsh::home}/${name}"
$group = $name
}
file_line { "${name}-${theme}-install":
path => "${home}/.zshrc",
line => "ZSH_THEME=\"${theme}\"",
match => '^ZSH_THEME',
require => Ohmyzsh::Install[$name],
}
}
|