diff --git a/.circleci/config.yml b/.circleci/config.yml index 08e6f93..5b871ca 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -8,5 +8,5 @@ jobs: steps: - checkout - run: gem install puppet-lint - - run: puppet-lint modules/ --fail-on-warnings - - run: puppet-lint manifests/ --fail-on-warnings + - run: puppet-lint modules/ -c .puppet-lint.rc + - run: puppet-lint manifests/ -c .puppet-lint.rc diff --git a/.puppet-lint.rc b/.puppet-lint.rc new file mode 100644 index 0000000..1de88dc --- /dev/null +++ b/.puppet-lint.rc @@ -0,0 +1,4 @@ +--fail-on-warnings +--no-arrow-alignment-check +--no-documentation-check +--no-variables_not_enclosed-check diff --git a/modules/common/manifests/init.pp b/modules/common/manifests/init.pp index 8a9f37f..b4c608b 100644 --- a/modules/common/manifests/init.pp +++ b/modules/common/manifests/init.pp @@ -1,16 +1,15 @@ class common { - user { "make me": - name => "jake", + user { 'make me': + name => 'jake', allowdupe => false, - auth_membership => "inclusive", - comment => "Jake Howard", - home => "/home/jake", - uid => "1000", - } -> - - file { "create home": - path => "/home/jake", + auth_membership => 'inclusive', + comment => 'Jake Howard', + home => '/home/jake', + uid => '1000', + } + -> file { 'create home': ensure => directory, - owner => "jake" + path => '/home/jake', + owner => 'jake' } } diff --git a/modules/config/manifests/fonts.pp b/modules/config/manifests/fonts.pp index ec711fb..614cde4 100644 --- a/modules/config/manifests/fonts.pp +++ b/modules/config/manifests/fonts.pp @@ -1,21 +1,21 @@ class config::fonts { $fonts = [ - "11-lcdfilter-default.conf", - "10-sub-pixel-rgb.conf", - "30-infinality-aliases.conf" + '11-lcdfilter-default.conf', + '10-sub-pixel-rgb.conf', + '30-infinality-aliases.conf' ]; $fonts.each |String $font| { file { "font config $font": - path => "/etc/fonts/conf.d/$font", ensure => link, - mode => "0644", + path => "/etc/fonts/conf.d/$font", + mode => '0644', source => "/etc/fonts/conf.avail/$font" } } exec { 'update font cache': - command => "gdk-pixbuf-query-loaders --update-cache" + command => 'gdk-pixbuf-query-loaders --update-cache' } } diff --git a/modules/config/manifests/git.pp b/modules/config/manifests/git.pp index 913a03e..b53e244 100644 --- a/modules/config/manifests/git.pp +++ b/modules/config/manifests/git.pp @@ -1,13 +1,13 @@ class config::git { file { '/home/jake/.gitignore_global': ensure => file, - mode => "0644", + mode => '0644', source => 'puppet:///modules/config/gitignore_global' } - git::config { "global ignore" : + git::config { 'global ignore' : key => 'core.excludesfile', value => '/home/jake/.gitignore_global', - user => "jake" + user => 'jake' } } diff --git a/modules/config/manifests/init.pp b/modules/config/manifests/init.pp index cc7b345..15e7d50 100644 --- a/modules/config/manifests/init.pp +++ b/modules/config/manifests/init.pp @@ -5,19 +5,19 @@ class config { file { '/etc/libinput-gestures.conf': ensure => file, - mode => "0644", + mode => '0644', source => 'puppet:///modules/config/libinput-gestures.conf' } file { '/home/jake/.config/terminator/config': ensure => file, - mode => "0644", + mode => '0644', source => 'puppet:///modules/config/terminator.conf' } file { '/home/jake/.config/uniemoji/custom.json': ensure => file, - mode => "0644", + mode => '0644', source => 'puppet:///modules/config/uniemoji.json' } } diff --git a/modules/config/manifests/vim.pp b/modules/config/manifests/vim.pp index 74763f0..2d36f2d 100644 --- a/modules/config/manifests/vim.pp +++ b/modules/config/manifests/vim.pp @@ -1,22 +1,22 @@ class config::vim { file { '/home/jake/.vimrc': ensure => file, - mode => "0644", - owner => "jake", - group => "users", + mode => '0644', + owner => 'jake', + group => 'users', source => 'puppet:///modules/config/vimrc' - } -> + } - vcsrepo { '/home/jake/.vim_runtime': + -> vcsrepo { '/home/jake/.vim_runtime': ensure => latest, provider => git, user => 'jake', - source => "https://github.com/amix/vimrc.git", - } -> + source => 'https://github.com/amix/vimrc.git', + } - exec { 'install vim plugins': - command => "vim +PluginInstall +qall", - user => "jake", - environment => "HOME=/home/jake" + -> exec { 'install vim plugins': + command => 'vim +PluginInstall +qall', + user => 'jake', + environment => 'HOME=/home/jake' } } diff --git a/modules/gnome/manifests/init.pp b/modules/gnome/manifests/init.pp index a589453..c7f0fc6 100644 --- a/modules/gnome/manifests/init.pp +++ b/modules/gnome/manifests/init.pp @@ -2,19 +2,19 @@ class gnome { file { '/home/jake/Templates': ensure => directory, source => 'puppet:///modules/gnome/Templates', - owner => "jake", - group => "users", - mode => "0755", + owner => 'jake', + group => 'users', + mode => '0755', recurse => remote } exec { 'show battery percentage': - user => "jake", + user => 'jake', command => 'gsettings set org.gnome.desktop.interface show-battery-percentage true' } exec { 'Remove volume change sound': - user => "jake", + user => 'jake', command => 'gsettings set org.gnome.desktop.sound event-sounds false' } } diff --git a/modules/i3/manifests/autostart.pp b/modules/i3/manifests/autostart.pp index ed78a6d..455e505 100644 --- a/modules/i3/manifests/autostart.pp +++ b/modules/i3/manifests/autostart.pp @@ -1,23 +1,23 @@ class i3::autostart { $programs = [ - "gnome-keyring-pkcs11", - "gnome-keyring-secrets", - "gnome-keyring-ssh", - "mousewheelzoom", - "pulseaudio", - "org.gnome.SettingsDaemon.XSettings", - "org.gnome.SettingsDaemon.XRANDR", - "org.gnome.SettingsDaemon.DiskUtilityNotify", - "org.gnome.SettingsDaemon.Keyboard", - "gsettings-data-convert" + 'gnome-keyring-pkcs11', + 'gnome-keyring-secrets', + 'gnome-keyring-ssh', + 'mousewheelzoom', + 'pulseaudio', + 'org.gnome.SettingsDaemon.XSettings', + 'org.gnome.SettingsDaemon.XRANDR', + 'org.gnome.SettingsDaemon.DiskUtilityNotify', + 'org.gnome.SettingsDaemon.Keyboard', + 'gsettings-data-convert' ]; $programs.each |String $program| { file { "autostart $program": - path => "/home/jake/.config/autostart/$program.desktop", ensure => link, - mode => "0744", - owner => "jake", + path => "/home/jake/.config/autostart/$program.desktop", + mode => '0744', + owner => 'jake', source => "/etc/xdg/autostart/$program.desktop" } } diff --git a/modules/i3/manifests/init.pp b/modules/i3/manifests/init.pp index fefbfeb..25c7c89 100644 --- a/modules/i3/manifests/init.pp +++ b/modules/i3/manifests/init.pp @@ -1,30 +1,30 @@ class i3 { include 'i3::autostart' - file { "i3 config": - path => '/home/jake/.config/i3/config', + file { 'i3 config': ensure => file, - mode => "0644", - owner => "jake", - group => "users", + path => '/home/jake/.config/i3/config', + mode => '0644', + owner => 'jake', + group => 'users', source => 'puppet:///modules/i3/i3.conf' } - file { "i3status-rust config": - path => '/home/jake/.config/i3/status.toml', + file { 'i3status-rust config': ensure => file, - mode => "0644", - owner => "jake", - group => "users", + path => '/home/jake/.config/i3/status.toml', + mode => '0644', + owner => 'jake', + group => 'users', source => 'puppet:///modules/i3/i3status-rust.toml' } - file { "i3status config": - path => '/home/jake/.config/i3status/config', + file { 'i3status config': ensure => file, - mode => "0644", - owner => "jake", - group => "users", + path => '/home/jake/.config/i3status/config', + mode => '0644', + owner => 'jake', + group => 'users', source => 'puppet:///modules/i3/i3status.conf' } } diff --git a/modules/shell/manifests/init.pp b/modules/shell/manifests/init.pp index 6982b68..8b009d3 100644 --- a/modules/shell/manifests/init.pp +++ b/modules/shell/manifests/init.pp @@ -1,19 +1,19 @@ class shell { - $zshrc = "/home/jake/.zshrc" + $zshrc = '/home/jake/.zshrc' $files = [ - "puppet:///modules/shell/.zshrc", - "puppet:///modules/shell/base.sh", - "puppet:///modules/shell/applications.sh", - "puppet:///modules/shell/catfish.sh", - "puppet:///modules/shell/javascript.sh" + 'puppet:///modules/shell/.zshrc', + 'puppet:///modules/shell/base.sh', + 'puppet:///modules/shell/applications.sh', + 'puppet:///modules/shell/catfish.sh', + 'puppet:///modules/shell/javascript.sh' ]; - concat {"zshrc": + concat {'zshrc': path => $zshrc, - owner => "jake", - group => "users", - mode => "0644", + owner => 'jake', + group => 'users', + mode => '0644', ensure_newline => true } @@ -25,19 +25,19 @@ class shell { } file {'nvm': - path => "/home/jake/.nvm/nvm.sh", - owner => "jake", - group => "users", - mode => "0755", - source => "/usr/share/nvm/init-nvm.sh" + path => '/home/jake/.nvm/nvm.sh', + owner => 'jake', + group => 'users', + mode => '0755', + source => '/usr/share/nvm/init-nvm.sh' } file { '/home/jake/.bin': ensure => directory, source => 'puppet:///modules/shell/bin', - owner => "jake", - group => "users", - mode => "0755", + owner => 'jake', + group => 'users', + mode => '0755', recurse => remote } } diff --git a/modules/yaourt/manifests/files.pp b/modules/yaourt/manifests/files.pp index 97700d6..33e4da0 100644 --- a/modules/yaourt/manifests/files.pp +++ b/modules/yaourt/manifests/files.pp @@ -6,9 +6,9 @@ class yaourt::files () { file { '/home/jake/.yaourtrc': ensure => file, - mode => "0644", - owner => "jake", - group => "users", + mode => '0644', + owner => 'jake', + group => 'users', source => 'puppet:///modules/yaourt/.yaourtrc' } } diff --git a/modules/yaourt/manifests/keys.pp b/modules/yaourt/manifests/keys.pp index 583f740..0e335e4 100644 --- a/modules/yaourt/manifests/keys.pp +++ b/modules/yaourt/manifests/keys.pp @@ -1,7 +1,7 @@ class yaourt::keys () { $keys = [ - "8A8F901A", # Sublime Text - "D1483FA6C3C07136" # Tor Browser + '8A8F901A', # Sublime Text + 'D1483FA6C3C07136' # Tor Browser ] $keys.each |$key| {