---
- name: Pacman cache | Remove old cron script 1
  cron:
    state: absent
    name: "Clean pacman cache"
    special_time: weekly
    job: "paccache -rv"
    user: root
    cron_file: paccache

- name: Pacman cache | Remove old cron script 2
  cron:
    state: absent
    name: "Clean pacman cache"
    special_time: weekly
    job: "paccache -rvuk0"
    user: root
    cron_file: paccache_uninstalled

# Removed, does nothing
- name: Ensure the pacman database is optimized monthly
  cron:
    state: absent
    name: "Optimize pacman database"
    special_time: monthly
    job: "pacman-optimize"
    user: root
    cron_file: pacman-optimize

- name: Remove old cronjob
  cron:
    state: absent
    cron_file: pacman-mirrors-rank
    job: /usr/local/sbin/pacman-sort-mirrors.sh
    user: root
    special_time: daily
    name: pacman-mirrors-rank

- name: Remove old cronjob script
  file:
    path: /usr/local/sbin/pacman-sort-mirrors.sh
    state: absent

Remove old scripts moved to own task file
Remove old scripts moved to own task file
