From c7cf07bd994280fbfb68c9d22bcb74c35c5e50f7 Mon Sep 17 00:00:00 2001 From: Anatolii Kmetiuk Date: Fri, 3 Apr 2020 14:41:10 +0200 Subject: [PATCH] CI Debug --- .github/workflows/ci.yaml | 324 ++------------------------------------ 1 file changed, 10 insertions(+), 314 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 0fca4d567740..36800adaf0db 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -3,146 +3,22 @@ name: Dotty CI on: push: pull_request: - schedule: - - cron: '0 3 * * *' # Every day at 3 AM - -env: - DOTTY_CI_RUN: true jobs: - test: - runs-on: self-hosted - container: akmetiuk/dotty:2020-02-12 - - steps: - - name: Cleanup - run: | - TARGETS="$(pwd) /__w/_temp /github/home" - for folder in $TARGETS; do - echo "Cleaning $folder" - cd $folder - rm -rf ..?* .[!.]* * - done - - - name: Git Checkout - uses: actions/checkout@v2 - - - name: Cache Ivy - uses: actions/cache@v1.1.2 - with: - path: /root/.ivy2/cache - key: ${{ runner.os }}-ivy-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-ivy- - - - name: Cache SBT - uses: actions/cache@v1.1.2 - with: - path: /root/.sbt - key: ${{ runner.os }}-sbt-${{ hashFiles('project/**') }} - restore-keys: ${{ runner.os }}-sbt- - - - name: Cache Coursier and Mill - uses: actions/cache@v1.1.2 - with: - path: /root/.cache - key: ${{ runner.os }}-general-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-general- - - - name: Test - run: | - ./project/scripts/sbt ";compile ;test" - ./project/scripts/cmdTests - - test_bootstrapped: - runs-on: self-hosted - container: akmetiuk/dotty:2020-02-12 - - steps: - - name: Cleanup - run: | - TARGETS="$(pwd) /__w/_temp /github/home" - for folder in $TARGETS; do - echo "Cleaning $folder" - cd $folder - rm -rf ..?* .[!.]* * - done - - - name: Git Checkout - uses: actions/checkout@v2 - - - name: Cache Ivy - uses: actions/cache@v1.1.2 - with: - path: /root/.ivy2/cache - key: ${{ runner.os }}-ivy-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-ivy- - - - name: Cache SBT - uses: actions/cache@v1.1.2 - with: - path: /root/.sbt - key: ${{ runner.os }}-sbt-${{ hashFiles('project/**') }} - restore-keys: ${{ runner.os }}-sbt- - - - name: Cache Coursier and Mill - uses: actions/cache@v1.1.2 - with: - path: /root/.cache - key: ${{ runner.os }}-general-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-general- - - - name: Test - run: | - ./project/scripts/sbt ";dotty-bootstrapped/compile ;dotty-bootstrapped/test;sjsSandbox/run;sjsSandbox/test;sjsJUnitTests/test ;configureIDE" - ./project/scripts/bootstrapCmdTests - - community_build: - runs-on: self-hosted - container: akmetiuk/dotty:2020-02-12 + good: + runs-on: ubuntu-latest steps: - - name: Cleanup - run: | - TARGETS="$(pwd) /__w/_temp /github/home" - for folder in $TARGETS; do - echo "Cleaning $folder" - cd $folder - rm -rf ..?* .[!.]* * - done - - - name: Git Checkout - uses: actions/checkout@v2 - - - name: Cache Ivy - uses: actions/cache@v1.1.2 - with: - path: /root/.ivy2/cache - key: ${{ runner.os }}-ivy-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-ivy- - - - name: Cache SBT - uses: actions/cache@v1.1.2 - with: - path: /root/.sbt - key: ${{ runner.os }}-sbt-${{ hashFiles('project/**') }} - restore-keys: ${{ runner.os }}-sbt- - - - name: Cache Coursier and Mill - uses: actions/cache@v1.1.2 - with: - path: /root/.cache - key: ${{ runner.os }}-general-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-general- - - name: Test run: | - git submodule sync - git submodule update --init --recursive --jobs 7 - ./project/scripts/sbt community-build/test + echo "Hello" + echo "github.event_name = ${{ github.event_name }}" + echo "github.event.ref = ${{ github.event.ref }}" + echo "startsWith(github.event.ref, 'refs/tags/') = ${{ startsWith(github.event.ref, 'refs/tags/') }}" + echo "If-condition = ${{ (github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/')) || github.event_name == 'schedule' }}" - test_sbt: - runs-on: self-hosted - container: akmetiuk/dotty:2020-02-12 + bad: + runs-on: ubuntu-latest if: ( github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/') @@ -150,185 +26,5 @@ jobs: github.event_name == 'schedule' steps: - - name: Cleanup - run: | - TARGETS="$(pwd) /__w/_temp /github/home" - for folder in $TARGETS; do - echo "Cleaning $folder" - cd $folder - rm -rf ..?* .[!.]* * - done - - - name: Git Checkout - uses: actions/checkout@v2 - - - name: Cache Ivy - uses: actions/cache@v1.1.2 - with: - path: /root/.ivy2/cache - key: ${{ runner.os }}-ivy-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-ivy- - - - name: Cache SBT - uses: actions/cache@v1.1.2 - with: - path: /root/.sbt - key: ${{ runner.os }}-sbt-${{ hashFiles('project/**') }} - restore-keys: ${{ runner.os }}-sbt- - - - name: Cache Coursier and Mill - uses: actions/cache@v1.1.2 - with: - path: /root/.cache - key: ${{ runner.os }}-general-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-general- - - name: Test - run: ./project/scripts/sbt sbt-dotty/scripted - - test_java11: - runs-on: self-hosted - container: akmetiuk/dotty:2020-02-12 - if: ( - github.event_name == 'push' && - startsWith(github.event.ref, 'refs/tags/') - ) || - github.event_name == 'schedule' - - steps: - - name: Cleanup - run: | - TARGETS="$(pwd) /__w/_temp /github/home" - for folder in $TARGETS; do - echo "Cleaning $folder" - cd $folder - rm -rf ..?* .[!.]* * - done - - - name: Git Checkout - uses: actions/checkout@v2 - - - name: Cache Ivy - uses: actions/cache@v1.1.2 - with: - path: /root/.ivy2/cache - key: ${{ runner.os }}-ivy-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-ivy- - - - name: Cache SBT - uses: actions/cache@v1.1.2 - with: - path: /root/.sbt - key: ${{ runner.os }}-sbt-${{ hashFiles('project/**') }} - restore-keys: ${{ runner.os }}-sbt- - - - name: Cache Coursier and Mill - uses: actions/cache@v1.1.2 - with: - path: /root/.cache - key: ${{ runner.os }}-general-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-general- - - - name: Test - run: | - export PATH="/usr/lib/jvm/java-11-openjdk-amd64/bin:$PATH" - ./project/scripts/sbt ";compile ;test" - - publish_nightly: - runs-on: self-hosted - container: akmetiuk/dotty:2020-02-12 - needs: [test, test_bootstrapped, community_build, test_sbt, test_java11] - if: github.event_name == 'schedule' - env: - NIGHTLYBUILD: yes - PGP_PW: ${{ secrets.PGP_PW }} # PGP passphrase - PGP_SECRET: ${{ secrets.PGP_SECRET }} # Export your private and public PGP key to an *.asc file, take the file's contents as a string - SONATYPE_PW: ${{ secrets.SONATYPE_PW }} - SONATYPE_USER: ${{ secrets.SONATYPE_USER }} - - steps: - - name: Cleanup - run: | - TARGETS="$(pwd) /__w/_temp /github/home" - for folder in $TARGETS; do - echo "Cleaning $folder" - cd $folder - rm -rf ..?* .[!.]* * - done - - - name: Git Checkout - uses: actions/checkout@v2 - - - name: Cache Ivy - uses: actions/cache@v1.1.2 - with: - path: /root/.ivy2/cache - key: ${{ runner.os }}-ivy-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-ivy- - - - name: Cache SBT - uses: actions/cache@v1.1.2 - with: - path: /root/.sbt - key: ${{ runner.os }}-sbt-${{ hashFiles('project/**') }} - restore-keys: ${{ runner.os }}-sbt- - - - name: Cache Coursier and Mill - uses: actions/cache@v1.1.2 - with: - path: /root/.cache - key: ${{ runner.os }}-general-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-general- - - - name: Publish Nightly - run: | - ./project/scripts/sbtPublish ";project dotty-bootstrapped ;publishSigned ;sonatypeBundleRelease" - - nightly_documentation: - runs-on: self-hosted - container: akmetiuk/dotty:2020-02-12 - needs: [publish_nightly] - if: github.event_name == 'schedule' - env: - NIGHTLYBUILD: yes - BOT_TOKEN: ${{ secrets.BOT_TOKEN }} # If you need to change this: - # Generate one at https://github.com/settings/tokens - # Make sure you have the write permissions to the repo: https://github.com/lampepfl/dotty-website - - steps: - - name: Cleanup - run: | - TARGETS="$(pwd) /__w/_temp /github/home" - for folder in $TARGETS; do - echo "Cleaning $folder" - cd $folder - rm -rf ..?* .[!.]* * - done - - - name: Git Checkout - uses: actions/checkout@v2 - - - name: Cache Ivy - uses: actions/cache@v1.1.2 - with: - path: /root/.ivy2/cache - key: ${{ runner.os }}-ivy-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-ivy- - - - name: Cache SBT - uses: actions/cache@v1.1.2 - with: - path: /root/.sbt - key: ${{ runner.os }}-sbt-${{ hashFiles('project/**') }} - restore-keys: ${{ runner.os }}-sbt- - - - name: Cache Coursier and Mill - uses: actions/cache@v1.1.2 - with: - path: /root/.cache - key: ${{ runner.os }}-general-${{ hashFiles('**/build.sbt') }} - restore-keys: ${{ runner.os }}-general- - - - name: Nightly Documentation - run: | - ./project/scripts/genDocs -doc-snapshot + run: echo "Hello"