<commit_before>---
- file:
    path: "/var/lib/jenkins/.ssh/{{ item }}"
    state: absent
  with_items:
    - id_rsa
    - id_rsa.pub

- shell: sudo -u jenkins ssh-keygen -t rsa -N "" -f /var/lib/jenkins/.ssh/id_rsa

- shell: cat /var/lib/jenkins/.ssh/id_rsa.pub
  register: jenkins_public_key

- set_fact: jenkins_public_key="{{ jenkins_public_key.stdout }}"

- shell: |
    curl --user "admin:{{ jenkins_admin_password | default('<PASSWORD>') }}" \
      --data-urlencode 'script= \
    jlc = JenkinsLocationConfiguration.get();
    jlc.setUrl("{{ jenkins_url }}");
    jlc.save();
    ' http://localhost:8080/scriptText

- shell: |
    curl --user "admin:{{ jenkins_admin_password | default('<PASSWORD>') }}" \
      --data-urlencode 'script= \
    import hudson.markup.RawHtmlMarkupFormatter
    Jenkins.instance.setMarkupFormatter(new RawHtmlMarkupFormatter(false))
    Jenkins.instance.save()
    ' http://localhost:8080/scriptText

- shell: |
    curl --user "admin:{{ jenkins_admin_password | default('<PASSWORD>') }}" \
      --data-urlencode 'script= \
    import hudson.util.Secret;
    import com.cloudbees.plugins.credentials.*;
    import com.cloudbees.plugins.credentials.domains.Domain;
    import org.jenkinsci.plugins.plaincredentials.impl.StringCredentialsImpl;
    import net.sf.json.*;
    import org.kohsuke.stapler.*;

    def descriptor = jenkins.model.Jenkins.getInstance().getDescriptorByType(org.jenkinsci.plugins.ghprb.GhprbTrigger.DescriptorImpl.class);
    stapler = Stapler.getCurrentRequest();
    jsonObject = new JSONObject();
    jsonObject.put("serverAPIUrl", "https://api.github.com");
    jsonObject.put("username", "");
    jsonObject.put("password", "");
    jsonObject.put("accessToken", "accessToken");
    jsonObject.put("adminlist", "");
    jsonObject.put("allowMembersOfWhitelistedOrgsAsAdmin", "false");
    jsonObject.put("publishedURL", "");
    jsonObject.put("requestForTestingPhrase", "test this");
    jsonObject.put("whitelistPhrase", "");
    jsonObject.put("okToTestPhrase", "ok to test");
    jsonObject.put("retestPhrase", "retest this please");
    jsonObject.put("skipBuildPhrase", "[skip ci]");
    jsonObject.put("cron", "*/1 * * * *");
    jsonObject.put("useComments", "false");
    jsonObject.put("logExcerptLines", "0");
    jsonObject.put("unstableAs", "");
    jsonObject.put("testMode", "true");
    jsonObject.put("autoCloseFailedPullRequests", "false");
    jsonObject.put("msgSuccess", "Success");
    jsonObject.put("msgFailure", "Failure");
    jsonObject.put("blackListCommitAuthor", "");<commit_msg>ci: do not comment on new pull requests<commit_after>---
- file:
    path: "/var/lib/jenkins/.ssh/{{ item }}"
    state: absent
  with_items:
    - id_rsa
    - id_rsa.pub

- shell: sudo -u jenkins ssh-keygen -t rsa -N "" -f /var/lib/jenkins/.ssh/id_rsa

- shell: cat /var/lib/jenkins/.ssh/id_rsa.pub
  register: jenkins_public_key

- set_fact: jenkins_public_key="{{ jenkins_public_key.stdout }}"

- shell: |
    curl --user "admin:{{ jenkins_admin_password | default('<PASSWORD>') }}" \
      --data-urlencode 'script= \
    jlc = JenkinsLocationConfiguration.get();
    jlc.setUrl("{{ jenkins_url }}");
    jlc.save();
    ' http://localhost:8080/scriptText

- shell: |
    curl --user "admin:{{ jenkins_admin_password | default('admin') }}" \
      --data-urlencode 'script= \
    import hudson.markup.RawHtmlMarkupFormatter
    Jenkins.instance.setMarkupFormatter(new RawHtmlMarkupFormatter(false))
    Jenkins.instance.save()
    ' http://localhost:8080/scriptText

- shell: |
    curl --user "admin:{{ jenkins_admin_password | default('admin') }}" \
      --data-urlencode 'script= \
    import hudson.util.Secret;
    import com.cloudbees.plugins.credentials.*;
    import com.cloudbees.plugins.credentials.domains.Domain;
    import org.jenkinsci.plugins.plaincredentials.impl.StringCredentialsImpl;
    import net.sf.json.*;
    import org.kohsuke.stapler.*;

    def descriptor = jenkins.model.Jenkins.getInstance().getDescriptorByType(org.jenkinsci.plugins.ghprb.GhprbTrigger.DescriptorImpl.class);
    stapler = Stapler.getCurrentRequest();
    jsonObject = new JSONObject();
    jsonObject.put("serverAPIUrl", "https://api.github.com");
    jsonObject.put("username", "");
    jsonObject.put("password", "");
    jsonObject.put("accessToken", "accessToken");
    jsonObject.put("adminlist", "");
    jsonObject.put("allowMembersOfWhitelistedOrgsAsAdmin", "false");
    jsonObject.put("publishedURL", "");
    jsonObject.put("whitelistPhrase", "");
    jsonObject.put("okToTestPhrase", "ok to test");
    jsonObject.put("retestPhrase", "retest this please");
    jsonObject.put("skipBuildPhrase", "[skip ci]");
    jsonObject.put("cron", "*/1 * * * *");
    jsonObject.put("useComments", "false");
    jsonObject.put("logExcerptLines", "0");
    jsonObject.put("unstableAs", "");
    jsonObject.put("testMode", "true");
    jsonObject.put("autoCloseFailedPullRequests", "false");
    jsonObject.put("msgSuccess", "Success");
    jsonObject.put("msgFailure", "Failure");
    jsonObject.put("blackListCommitAuthor", "");
{'fraction_non_alphanumeric': 0.1699960830395613, 'fraction_numerical': 0.0039169604386995694, 'mean_word_length': 3.99706457925636, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, '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': '132545', 'n_tokens_mistral': 1727, 'n_tokens_neox': 1685, 'n_words': 254}