<commit_before>
- job-template:
    name: 'periodic-gerrit-plugin-{name}'
    node: '{node}'

    wrappers:
      - timeout:
          timeout: 30
          fail: true
      - timestamps

    builders:
      - revoke-sudo
      - shell: |
          #!/bin/bash -xe
          rm -rf gerrit
          git clone -b {gerrit-branch} {gerrit-project}
          git clone -b {plugin-branch} {plugin-project} gerrit/plugins/{plugin-name}
          cd gerrit/plugins/{plugin-name}
          /usr/local/jenkins/slave_scripts/version-properties.sh
      - inject:
          properties-file: gerrit/plugins/{plugin-name}/version.properties
      - install-buck
      - shell: |
          #!/bin/bash -xe
          export PATH=`pwd`/buck/bin:$PATH
          cd gerrit
          buck clean
          buck build plugins/{plugin-name}:{plugin-name}
          cp ./buck-out/gen/plugins/{plugin-name}/{plugin-name}.jar ./buck-out/gen/plugins/{plugin-name}/{plugin-name}-$PROJECT_VER.jar

    publishers:
      - war:
          site: '{tarball-site}'
          warfile: 'gerrit/buck-out/gen/plugins/{plugin-name}/{plugin-name}-${{PROJECT_VER}}.jar'
          target: 'tarballs/ci/{name}'
      - console-log

- job-group:
    name: gerrit-plugin-jobs
    jobs:
      - 'periodic-gerrit-plugin-{name}'<commit_msg>deploy gerrit plugins into folder with plugin name<commit_after>
- job-template:
    name: 'periodic-gerrit-plugin-{name}'
    node: '{node}'

    wrappers:
      - timeout:
          timeout: 30
          fail: true
      - timestamps

    builders:
      - revoke-sudo
      - shell: |
          #!/bin/bash -xe
          rm -rf gerrit
          git clone -b {gerrit-branch} {gerrit-project}
          git clone -b {plugin-branch} {plugin-project} gerrit/plugins/{plugin-name}
          cd gerrit/plugins/{plugin-name}
          /usr/local/jenkins/slave_scripts/version-properties.sh
      - inject:
          properties-file: gerrit/plugins/{plugin-name}/version.properties
      - install-buck
      - shell: |
          #!/bin/bash -xe
          export PATH=`pwd`/buck/bin:$PATH
          cd gerrit
          buck clean
          buck build plugins/{plugin-name}:{plugin-name}
          cp ./buck-out/gen/plugins/{plugin-name}/{plugin-name}.jar ./buck-out/gen/plugins/{plugin-name}/{plugin-name}-$PROJECT_VER.jar

    publishers:
      - war:
          site: '{tarball-site}'
          warfile: 'gerrit/buck-out/gen/plugins/{plugin-name}/{plugin-name}-${{PROJECT_VER}}.jar'
          target: 'tarballs/ci/gerrit/plugins/{plugin-name}'
      - console-log

- job-group:
    name: gerrit-plugin-jobs
    jobs:
      - 'periodic-gerrit-plugin-{name}'
{'fraction_non_alphanumeric': 0.1440453686200378, 'fraction_numerical': 0.0015122873345935729, 'mean_word_length': 1.9108910891089108, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, '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': '4157616', 'n_tokens_mistral': 893, 'n_tokens_neox': 827, 'n_words': 142}