From 9be0c631ddb6c7bc0f51396b8a4fdfcbb57702f0 Mon Sep 17 00:00:00 2001 From: maxonfjvipon Date: Thu, 28 Aug 2025 15:41:42 +0300 Subject: [PATCH] add deep CI --- .github/workflows/deep.yml | 68 ++++++++++++++++++++++++++++++++++++++ build.gradle | 6 ++-- 2 files changed, 71 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/deep.yml diff --git a/.github/workflows/deep.yml b/.github/workflows/deep.yml new file mode 100644 index 0000000000000..424c65916dee2 --- /dev/null +++ b/.github/workflows/deep.yml @@ -0,0 +1,68 @@ +# SPDX-FileCopyrightText: Copyright (c) 2025 Objectionary.com +# SPDX-License-Identifier: MIT +--- +# yamllint disable rule:line-length +name: deep +'on': + push: + branches: + - master + paths-ignore: [ 'README.md' ] +jobs: + start-instance: + runs-on: ubuntu-24.04 + outputs: + label: ${{ steps.start.outputs.label }} + ec2-instance-id: ${{ steps.start.outputs.ec2-instance-id }} + steps: + - uses: aws-actions/configure-aws-credentials@v4 + with: + aws-access-key-id: ${{ secrets.AWS_KEY }} + aws-secret-access-key: ${{ secrets.AWS_SECRET }} + aws-region: ${{ secrets.AWS_REGION }} + - id: start + uses: machulav/ec2-github-runner@v2 + with: + mode: start + aws-resource-tags: '[{"Key":"Name","Value":"hone-deep"}]' + github-token: ${{ secrets.AWS_PAT }} + ec2-image-id: ${{ secrets.AWS_AMI }} + ec2-instance-type: t3.2xlarge + subnet-id: ${{ secrets.AWS_SUBNET }} + security-group-id: ${{ secrets.AWS_SGROUP }} + deep: + runs-on: ubuntu-24.04 + timeout-minutes: 80 + steps: + - uses: actions/checkout@v5 + - uses: actions/setup-java@v5 + with: + distribution: 'zulu' + java-version: 17 + - uses: actions/cache@v4 + with: + path: | + ~/.gradle/caches + ~/.gradle/wrapper + key: ubuntu-jdk-17-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} + restore-keys: | + ubuntu-jdk-17-gradle- + - run: ./gradlew clean test + terminate-instance: + needs: + - start-instance + - deep + runs-on: ubuntu-24.04 + if: ${{ always() }} + steps: + - uses: aws-actions/configure-aws-credentials@v4 + with: + aws-access-key-id: ${{ secrets.AWS_KEY }} + aws-secret-access-key: ${{ secrets.AWS_SECRET }} + aws-region: ${{ secrets.AWS_REGION }} + - uses: machulav/ec2-github-runner@v2 + with: + mode: stop + github-token: ${{ secrets.AWS_PAT }} + label: ${{ needs.start-instance.outputs.label }} + ec2-instance-id: ${{ needs.start-instance.outputs.ec2-instance-id }} diff --git a/build.gradle b/build.gradle index 93ecc6feddf34..ab445f2ff3e4c 100644 --- a/build.gradle +++ b/build.gradle @@ -305,18 +305,18 @@ println("Build properties: ignoreFailures=$userIgnoreFailures, maxParallelForks= subprojects { pluginManager.withPlugin('java') { - def v = '0.13.1' + def v = '0.14.1' def hone = tasks.register('hone', Exec) { group = 'build' description = 'Run hone after Java compile' sourceSets.main.output.classesDirs.files.each { dir -> commandLine 'mvn', - "-Dhone.timeout=60", + "-Dhone.timeout=400", "-Dhone.threads=0", "-Dhone.grep-in=(66-69-6C-74-65-72|6D-61-70)", "-Dhone.target=${project.buildDir}", "-Dhone.classes=${project.buildDir.toPath().relativize(dir.toPath())}", - '-Dhone.rules=streams/*,!streams/101-remove-self-reference-labels', + '-Dhone.rules=streams/*', "org.eolang:hone-maven-plugin:${v}:pull", "org.eolang:hone-maven-plugin:${v}:optimize" }