<commit_before>---

- name: Provisioning

  hosts: all

  tasks:

    - name: Install aptitude
      apt: name=aptitude state=latest install_recommends=no
      become: True

    - name: Update all packages to the latest version
      apt:
        update_cache: yes
        upgrade: dist
      become: True

    - import_tasks: tasks/install-roles.yml
    - import_tasks: tasks/setup-locale.yml
    - import_tasks: tasks/create-user.yml
    - import_tasks: tasks/setup-git.yml

    - name: Install Google Chrome
      include_role:
        name: fagia.chrome
      when: params.apps.install.chrome

    - name: Install MariaDB
      include_role:
        name: fagia.mariadb
      when: params.apps.install.mariadb

    - name: Install Apache HTTPD
      include_role:
        name: fagia.apache
      when: params.apps.install.apache

    - name: Install PHP
      include_role:
        name: fagia.php
      when: params.apps.install.php

    - name: Install PHP extensions for MariaDB
      apt: name=php-mysql state=latest
      become: True
      when: params.apps.install.mariadb and params.apps.install.php

    - name: Install Apache extensions for PHP
      apt: name=libapache2-mod-php state=latest
      become: True
      when: params.apps.install.apache and params.apps.install.php

    - name: Install Filezilla
      include_role:
        name: fagia.filezilla
      when: params.apps.install.filezilla

    - name: Install SublimeText
      include_role:
        name: fagia.sublimetext
      when: params.apps.install.sublime
    - name: Set fact necessary_menu_items
      set_fact:
        necessary_menu_items: "{{ necessary_menu_items }} + [ 'sublime_text.dockitem' ]"
      when: params.apps.install.sublime

    - name: Install Java
      include_role:
        name: fagia.java
      when: params.apps.install.java

    - name: Install Maven
      include_role:
        name: fagia.maven
      when: params.apps.install.maven

    - name: Install Gradle
      include_role:
        name: fagia.gradle
      when: params.apps.install.gradle

    - name: Install IntelliJ Idea
      include_role:
        name: fagia.intellij
      when: params.apps.install.java and params.apps.install.maven and params.apps.install.intellij_idea

    - name: Install PyCharm
      include_role:
        name: fagia.pycharm
      when: params.apps.install.java and params.apps.install.pycharm

    - name: Finding extra (private) roles
      find:
        paths: roles/private
        file_type: directory
      register: private_roles

    - name: Running extra (private) roles
      include_role:
        name: "{{ item.path }}"
      with_items: "{{ private_roles.files }}"
      when: ( private_roles.files|length > 0 ) and ( ansible_version.full is version_compare('2.4.2.0', '>') )

    - name: Add necessary menu items
      template:
        src: '{{ item }}'
        dest: '{{ plank_dock_configuration_dir }}/{{ item }}'
        force: no
        mode: 0644
      with_items: "{{ necessary_menu_items }}"
      become: True
      become_user: '{{ params.user.username }}'

    - name: Remove unecessary applications
      apt: name={{ item }} state=absent purge=yes
      with_items:
        - pantheon-mail
        - audience<commit_msg>executing private roles as virtual machine default user<commit_after>---

- name: Provisioning

  hosts: all

  tasks:

    - name: Install aptitude
      apt: name=aptitude state=latest install_recommends=no
      become: True

    - name: Update all packages to the latest version
      apt:
        update_cache: yes
        upgrade: dist
      become: True

    - import_tasks: tasks/install-roles.yml
    - import_tasks: tasks/setup-locale.yml
    - import_tasks: tasks/create-user.yml
    - import_tasks: tasks/setup-git.yml

    - name: Install Google Chrome
      include_role:
        name: fagia.chrome
      when: params.apps.install.chrome

    - name: Install MariaDB
      include_role:
        name: fagia.mariadb
      when: params.apps.install.mariadb

    - name: Install Apache HTTPD
      include_role:
        name: fagia.apache
      when: params.apps.install.apache

    - name: Install PHP
      include_role:
        name: fagia.php
      when: params.apps.install.php

    - name: Install PHP extensions for MariaDB
      apt: name=php-mysql state=latest
      become: True
      when: params.apps.install.mariadb and params.apps.install.php

    - name: Install Apache extensions for PHP
      apt: name=libapache2-mod-php state=latest
      become: True
      when: params.apps.install.apache and params.apps.install.php

    - name: Install Filezilla
      include_role:
        name: fagia.filezilla
      when: params.apps.install.filezilla

    - name: Install SublimeText
      include_role:
        name: fagia.sublimetext
      when: params.apps.install.sublime
    - name: Set fact necessary_menu_items
      set_fact:
        necessary_menu_items: "{{ necessary_menu_items }} + [ 'sublime_text.dockitem' ]"
      when: params.apps.install.sublime

    - name: Install Java
      include_role:
        name: fagia.java
      when: params.apps.install.java

    - name: Install Maven
      include_role:
        name: fagia.maven
      when: params.apps.install.maven

    - name: Install Gradle
      include_role:
        name: fagia.gradle
      when: params.apps.install.gradle

    - name: Install IntelliJ Idea
      include_role:
        name: fagia.intellij
      when: params.apps.install.java and params.apps.install.maven and params.apps.install.intellij_idea

    - name: Install PyCharm
      include_role:
        name: fagia.pycharm
      when: params.apps.install.java and params.apps.install.pycharm

    - name: Finding extra (private) roles
      find:
        paths: roles/private
        file_type: directory
      register: private_roles

    - name: Running extra (private) roles
      include_role:
        name: "{{ item.path }}"
      with_items: "{{ private_roles.files }}"
      become: True
      become_user: '{{ params.user.username }}'
      when: ( private_roles.files|length > 0 ) and ( ansible_version.full is version_compare('2.4.2.0', '>') )

    - name: Add necessary menu items
      template:
        src: '{{ item }}'
        dest: '{{ plank_dock_configuration_dir }}/{{ item }}'
        force: no
        mode: 0644
      with_items: "{{ necessary_menu_items }}"
      become: True
      become_user: '{{ params.user.username }}'

    - name: Remove unecessary applications
      apt: name={{ item }} state=absent purge=yes
      with_items:
        - pantheon-mail
        - audience
{'fraction_non_alphanumeric': 0.09375472554060184, 'fraction_numerical': 0.0030243459851807047, 'mean_word_length': 2.2905472636815922, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3176704', 'n_tokens_mistral': 2087, 'n_tokens_neox': 2018, 'n_words': 484}