---
- name: deploiement kontrast et color contrast analyser sur windows et linux
  hosts: all  
 # become: true  # lance apt en root
  tasks:
    #------------------------------------------------------------
    # TÂCHES POUR LINUX
    # -----------------------------------------------------------
    
    - name: Installer Kontrast sur Linux
      become: true
      apt:
        name: kontrast
        state: present
        update_cache: yes
      when: ansible_distribution == 'Ubuntu'
    
    #------------------------------------------------------------
    # TÂCHES POUR WINDOWS
    # -----------------------------------------------------------
    
    - name: Installer Colour Contrast Analyzer sur Windows via Chocolatey
      win_chocolatey:
        name: colour-contrast-analyser
        state: present
      when: ansible_os_family == 'Windows'
