diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml index 1a95489..fab5174 100644 --- a/.github/FUNDING.yml +++ b/.github/FUNDING.yml @@ -1,5 +1,5 @@ +--- # These are supported funding model platforms github: [do1jlr] liberapay: L3D -custom: https://paypal.me/c3woc diff --git a/.github/workflows/ansible-archlinux-latest.yml b/.github/workflows/ansible-archlinux-latest.yml index 9d651a3..e823f0c 100644 --- a/.github/workflows/ansible-archlinux-latest.yml +++ b/.github/workflows/ansible-archlinux-latest.yml @@ -1,5 +1,7 @@ +--- name: Ansible check archlinux:latest +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with archlinux:latest - uses: roles-ansible/check-ansible-archlinux-latest-action@master - with: - targets: "./" + - name: ansible check with archlinux:latest + uses: roles-ansible/check-ansible-archlinux-latest-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-centos-centos7.yml b/.github/workflows/ansible-centos-centos7.yml index 90bff41..401d2c0 100644 --- a/.github/workflows/ansible-centos-centos7.yml +++ b/.github/workflows/ansible-centos-centos7.yml @@ -1,5 +1,7 @@ +--- name: Ansible check centos:centos7 +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with ubuntu:centos7 - uses: roles-ansible/check-ansible-centos-centos7-action@master - with: - targets: "./" + - name: ansible check with ubuntu:centos7 + uses: roles-ansible/check-ansible-centos-centos7-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-centos-centos8.yml b/.github/workflows/ansible-centos-centos8.yml index 5d7acc9..f20097b 100644 --- a/.github/workflows/ansible-centos-centos8.yml +++ b/.github/workflows/ansible-centos-centos8.yml @@ -1,5 +1,7 @@ +--- name: Ansible check centos:centos8 +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with ubuntu:centos8 - uses: roles-ansible/check-ansible-centos-centos8-action@master - with: - targets: "./" + - name: ansible check with ubuntu:centos8 + uses: roles-ansible/check-ansible-centos-centos8-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-centos-latest.yml b/.github/workflows/ansible-centos-latest.yml index de991de..94eb54b 100644 --- a/.github/workflows/ansible-centos-latest.yml +++ b/.github/workflows/ansible-centos-latest.yml @@ -1,5 +1,7 @@ +--- name: Ansible check centos:latest +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with ubuntu:latest - uses: roles-ansible/check-ansible-centos-latest-action@master - with: - targets: "./" + - name: ansible check with ubuntu:latest + uses: roles-ansible/check-ansible-centos-latest-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-debian-buster.yml b/.github/workflows/ansible-debian-buster.yml index a7650ad..d76b02c 100644 --- a/.github/workflows/ansible-debian-buster.yml +++ b/.github/workflows/ansible-debian-buster.yml @@ -1,5 +1,7 @@ +--- name: Ansible check debian:buster +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with debian:buster - uses: roles-ansible/check-ansible-debian-buster-action@master - with: - targets: "./" + - name: ansible check with debian:buster + uses: roles-ansible/check-ansible-debian-buster-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-debian-latest.yml b/.github/workflows/ansible-debian-latest.yml index d0ad4ca..f7eb5b6 100644 --- a/.github/workflows/ansible-debian-latest.yml +++ b/.github/workflows/ansible-debian-latest.yml @@ -1,5 +1,7 @@ +--- name: Ansible check debian:latest +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with debian:latest - uses: roles-ansible/check-ansible-debian-latest-action@master - with: - targets: "./" + - name: ansible check with debian:latest + uses: roles-ansible/check-ansible-debian-latest-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-debian-sid.yml b/.github/workflows/ansible-debian-sid.yml index 72fe3a8..2e3215a 100644 --- a/.github/workflows/ansible-debian-sid.yml +++ b/.github/workflows/ansible-debian-sid.yml @@ -1,5 +1,7 @@ +--- name: Ansible check debian:sid +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with debian:sid - uses: roles-ansible/check-ansible-debian-sid-action@master - with: - targets: "./" + - name: ansible check with debian:sid + uses: roles-ansible/check-ansible-debian-sid-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-debian-stable.yml b/.github/workflows/ansible-debian-stable.yml index 97076ae..e47f773 100644 --- a/.github/workflows/ansible-debian-stable.yml +++ b/.github/workflows/ansible-debian-stable.yml @@ -1,5 +1,7 @@ +--- name: Ansible check debian:stable +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with debian:stable - uses: roles-ansible/check-ansible-debian-stable-action@master - with: - targets: "./" + - name: ansible check with debian:stable + uses: roles-ansible/check-ansible-debian-stable-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-debian-stretch.yml b/.github/workflows/ansible-debian-stretch.yml index 19ac5fb..c947cae 100644 --- a/.github/workflows/ansible-debian-stretch.yml +++ b/.github/workflows/ansible-debian-stretch.yml @@ -1,5 +1,7 @@ +--- name: Ansible check debian:stretch +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with debian:stretch - uses: roles-ansible/check-ansible-debian-stretch-action@master - with: - targets: "./" + - name: ansible check with debian:stretch + uses: roles-ansible/check-ansible-debian-stretch-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-fedora-31.yml b/.github/workflows/ansible-fedora-31.yml index 6bbe44d..08502fe 100644 --- a/.github/workflows/ansible-fedora-31.yml +++ b/.github/workflows/ansible-fedora-31.yml @@ -1,5 +1,7 @@ +--- name: Ansible check fedora:31 +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with fedora:31 - uses: roles-ansible/check-ansible-fedora-31-action@master - with: - targets: "./" + - name: ansible check with fedora:31 + uses: roles-ansible/check-ansible-fedora-31-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-fedora-32.yml b/.github/workflows/ansible-fedora-32.yml index 70fc147..e362dd4 100644 --- a/.github/workflows/ansible-fedora-32.yml +++ b/.github/workflows/ansible-fedora-32.yml @@ -1,5 +1,7 @@ +--- name: Ansible check fedora:32 +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with fedora:32 - uses: roles-ansible/check-ansible-fedora-32-action@master - with: - targets: "./" + - name: ansible check with fedora:32 + uses: roles-ansible/check-ansible-fedora-32-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-fedora-33.yml b/.github/workflows/ansible-fedora-33.yml index 6032811..70c52ad 100644 --- a/.github/workflows/ansible-fedora-33.yml +++ b/.github/workflows/ansible-fedora-33.yml @@ -1,5 +1,7 @@ +--- name: Ansible check fedora:33 +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with fedora:33 - uses: roles-ansible/check-ansible-fedora-33-action@master - with: - targets: "./" + - name: ansible check with fedora:33 + uses: roles-ansible/check-ansible-fedora-33-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-fedora-latest.yml b/.github/workflows/ansible-fedora-latest.yml index 8b14097..7cfbdf7 100644 --- a/.github/workflows/ansible-fedora-latest.yml +++ b/.github/workflows/ansible-fedora-latest.yml @@ -1,5 +1,7 @@ +--- name: Ansible check fedora:latest +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with fedora:latest - uses: roles-ansible/check-ansible-fedora-latest-action@master - with: - targets: "./" \ No newline at end of file + - name: ansible check with fedora:latest + uses: roles-ansible/check-ansible-fedora-latest-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-linting-check.yml b/.github/workflows/ansible-linting-check.yml index 712c76f..41dcb97 100644 --- a/.github/workflows/ansible-linting-check.yml +++ b/.github/workflows/ansible-linting-check.yml @@ -1,5 +1,7 @@ +--- name: Ansible Lint check +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,13 +10,13 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: Lint Ansible Playbook - uses: ansible/ansible-lint-action@master - with: - targets: "." - # [required] - # Paths to ansible files (i.e., playbooks, tasks, handlers etc..) - args: "" - # [optional] + - name: Lint Ansible Playbook + uses: ansible/ansible-lint-action@master + with: + targets: "." + # [required] + # Paths to ansible files (i.e., playbooks, tasks, handlers etc..) + args: "" + # [optional] diff --git a/.github/workflows/ansible-ubuntu-bionic.yml b/.github/workflows/ansible-ubuntu-bionic.yml index aea24a2..0f9edd8 100644 --- a/.github/workflows/ansible-ubuntu-bionic.yml +++ b/.github/workflows/ansible-ubuntu-bionic.yml @@ -1,5 +1,7 @@ +--- name: Ansible check ubuntu:bionic +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with ubuntu:bionic - uses: roles-ansible/check-ansible-ubuntu-bionic-action@master - with: - targets: "./" + - name: ansible check with ubuntu:bionic + uses: roles-ansible/check-ansible-ubuntu-bionic-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-ubuntu-latest.yml b/.github/workflows/ansible-ubuntu-latest.yml index 2e34685..b9544a5 100644 --- a/.github/workflows/ansible-ubuntu-latest.yml +++ b/.github/workflows/ansible-ubuntu-latest.yml @@ -1,5 +1,7 @@ +--- name: Ansible check ubuntu:latest +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with ubuntu:latest - uses: roles-ansible/check-ansible-ubuntu-latest-action@master - with: - targets: "./" + - name: ansible check with ubuntu:latest + uses: roles-ansible/check-ansible-ubuntu-latest-action@master + with: + targets: "./" diff --git a/.github/workflows/ansible-ubuntu-trusty.yml b/.github/workflows/ansible-ubuntu-trusty.yml index a18c397..6cde8b8 100644 --- a/.github/workflows/ansible-ubuntu-trusty.yml +++ b/.github/workflows/ansible-ubuntu-trusty.yml @@ -1,5 +1,7 @@ +--- name: Ansible check ubuntu:trusty +# yamllint disable-line rule:truthy on: [push, pull_request] jobs: @@ -8,9 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v2 - - name: ansible check with ubuntu:trusty - uses: roles-ansible/check-ansible-ubuntu-trusty-action@master - with: - targets: "./" + - name: ansible check with ubuntu:trusty + uses: roles-ansible/check-ansible-ubuntu-trusty-action@master + with: + targets: "./" diff --git a/.github/workflows/yamllint.yaml b/.github/workflows/yamllint.yaml new file mode 100644 index 0000000..39c49f8 --- /dev/null +++ b/.github/workflows/yamllint.yaml @@ -0,0 +1,22 @@ +--- +name: 'Yamllint GitHub Actions' + +# yamllint disable-line rule:truthy +on: [push, pull_request] + +jobs: + yamllint: + name: 'Yamllint' + runs-on: ubuntu-latest + steps: + - name: 'Checkout' + uses: actions/checkout@master + - name: 'Yamllint' + uses: karancode/yamllint-github-action@master + with: + yamllint_file_or_dir: '.' + yamllint_config_filepath: './.yamllint' + yamllint_strict: false + yamllint_comment: true +# env: +# GITHUB_ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN } diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 55b5d6c..0000000 --- a/.travis.yml +++ /dev/null @@ -1,29 +0,0 @@ ---- -# OS Details -os: linux -language: python -python: '3.8' - -cache: - pip: true - -# Install ansible and ansible-lint -install: - - pip install ansible - - pip install ansible-lint - -# testing galaxy install and ansible lint -# more advanced testing is currently handled with -# github actions. The gh-actions for our test are there: -# https://github.com/roles-ansible and are tagged -# with 'github-actions' --> https://github.com/search?q=topic%3Agithub-actions+org%3Aroles-ansible&type=Repositories -script: -# - ansible-galaxy install do1jlr.dotfiles - - ansible-lint . - - echo -e "\n\n\n\n\nWe use github actions for more detailed tests.\n\n\n\n\n" - -notifications: - webhooks: https://galaxy.ansible.com/api/v1/notifications/ - email: - on_success: never - on_failure: always diff --git a/.yamllint b/.yamllint new file mode 100644 index 0000000..7bb3cd9 --- /dev/null +++ b/.yamllint @@ -0,0 +1,11 @@ +--- +extends: default + +rules: + # 280 chars should be enough, but don't fail if a line is longer + line-length: + max: 280 + level: warning + braces: + level: warning + max-spaces-inside: 1 diff --git a/defaults/main.yml b/defaults/main.yml index 627e4ec..d79fea3 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -12,18 +12,17 @@ dotfiles__modify_bashrc: true # list of aliases used in bashrc dotfiles__aliases: - - { alias: "ls", command: "ls ", color: True } - - { alias: "grep", command: "grep", color: True } - - { alias: "ll", command: "ls -alF", color: False } - - { alias: "la", command: "ls -A", color: False } - - { alias: "l", command: "ls -CF", color: False } - - { alias: "lz", command: "ls -Z", color: False } - - { alias: "EDITOR", command: "/usr/bin/vim", color: False } - - { alias: "VISUAL", command: "/usr/bin/gedit", color: False } - - { alias: "gitsubpull", command: "git submodule foreach '(git checkout \\$(git symbolic-ref --short refs/remotes/origin/HEAD | sed 's@^origin/@@'); git pull)'", color: False } + - { alias: "ls", command: "ls ", color: true } + - { alias: "grep", command: "grep", color: true } + - { alias: "ll", command: "ls -alF", color: false } + - { alias: "la", command: "ls -A", color: false } + - { alias: "l", command: "ls -CF", color: false } + - { alias: "lz", command: "ls -Z", color: false } + - { alias: "EDITOR", command: "/usr/bin/vim", color: false } + - { alias: "VISUAL", command: "/usr/bin/gedit", color: false } + - { alias: "gitsubpull", command: "git submodule foreach '(git checkout \\$(git symbolic-ref --short refs/remotes/origin/HEAD | sed 's@^origin/@@'); git pull)'", color: false } - { alias: "pwgen", command: "/usr/bin/pwgen --num-passwords=3000 --numerals --capitalize --secure --no-vowels --ambiguous --symbols 95 1", color: false } - # enable bash completion dotfiles__bash_completion_enabled: true diff --git a/tasks/bashrc.yml b/tasks/bashrc.yml index 0fe622f..99f2a65 100644 --- a/tasks/bashrc.yml +++ b/tasks/bashrc.yml @@ -1,6 +1,6 @@ --- - name: Create a global bashrc configuration - become: yes + become: true template: src: 'templates/bash.bashrc' dest: '/etc/bash.bashrc' @@ -9,7 +9,7 @@ mode: 'u=rw,g=r,o=r' - name: Copy bashrc configuration to root - become: yes + become: true template: src: 'templates/bashrc' dest: '/root/.bashrc' @@ -19,7 +19,7 @@ when: not dotfiles__allow_own_root_bashrc | bool - name: Copy bashrc configuration to non admin users - become: yes + become: true template: src: 'templates/bashrc' dest: '/home/{{ item }}/.bashrc' diff --git a/tasks/basic-selinux.yml b/tasks/basic-selinux.yml index c5b8219..1e3a6f6 100644 --- a/tasks/basic-selinux.yml +++ b/tasks/basic-selinux.yml @@ -1,9 +1,9 @@ --- - name: install the latest libselinux-python package - become: yes + be:come: true dnf: name: libselinux-python state: present when: - - ansible_distribution == "Fedora" + - ansible_distribution == "Fedora" failed_when: false diff --git a/tasks/main.yml b/tasks/main.yml index 3c5e59c..37af643 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -9,7 +9,7 @@ when: dotfiles__modify_bashrc | bool - name: Copy vimrc configuration to root - become: yes + become: true copy: src: 'templates/vimrc' dest: '/root/.vimrc' @@ -18,7 +18,7 @@ mode: 'u=rw,g=r,o=' - name: Copy vimrc configuration to non admin users - become: yes + become: true copy: src: 'templates/vimrc' dest: '/home/{{ item }}/.vimrc' @@ -36,7 +36,7 @@ file: path: "/home/{{ item }}/.config/ranger" state: directory - recurse: yes + recurse: true owner: "{{ item }}" group: "{{ item }}" mode: '0644' diff --git a/tasks/versioncheck.yml b/tasks/versioncheck.yml index fa361f6..1ca07b5 100644 --- a/tasks/versioncheck.yml +++ b/tasks/versioncheck.yml @@ -13,7 +13,7 @@ src: "/etc/.ansible-version/{{ playbook_version_path }}" register: playbook_version when: submodules_versioncheck|bool - ignore_errors: yes + ignore_errors: true failed_when: false - name: Print remote role version diff --git a/templates/vimrc b/templates/vimrc index 3c745f1..fb0447e 100644 --- a/templates/vimrc +++ b/templates/vimrc @@ -1,8 +1,12 @@ +" gopass secure editor +au BufNewFile,BufRead /dev/shm/gopass.* setlocal noswapfile nobackup noundofile + +" vim layout syntax on " enable syntax highlighting set cursorline " highlight the current line -set fileencoding=utf-8 +set fileencoding=utf-8 set encoding=utf-8 -colorscheme elflord +colorscheme elflord set cursorline " highlight the current line " tabs and indenting diff --git a/vars/main.yml b/vars/main.yml index 49656d6..729da29 100644 --- a/vars/main.yml +++ b/vars/main.yml @@ -1,2 +1,3 @@ -playbook_version_number: 2065 # should be over ninethousand +--- +playbook_version_number: 2066 # should be increased integer playbook_version_path: 'role_dotfiles_chaos-bodensee_github.version'