mbien commented on a change in pull request #3785:
URL: https://github.com/apache/netbeans/pull/3785#discussion_r832409935



##########
File path: .github/workflows/main.yml
##########
@@ -0,0 +1,342 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: NetBeans
+
+on:
+  push:
+  pull_request:
+
+jobs:
+    
+# primary build job, most other jobs use the artifact produced here
+# artifact is only produced once in the matrix
+  base-build:
+    name: Build Clusters on JDK ${{ matrix.java }} 
+    runs-on: ubuntu-latest
+    env:
+      ANT_OPTS: 
-Dmetabuild.jsonurl=https://raw.githubusercontent.com/apache/netbeans-jenkins-lib/master/meta/netbeansrelease.json
+    strategy:
+      matrix:
+        java: [ '11', '17' ]
+      fail-fast: false
+    steps:
+        
+      - name: Set up JDK ${{ matrix.java }} 
+        uses: actions/setup-java@v2
+        with:
+          java-version: ${{ matrix.java }} 
+          distribution: 'zulu'
+
+      - name: Caching dependencies
+        uses: actions/cache@v2
+        with:
+          path: ~/.hgexternalcache
+          key: ${{ runner.os }}-${{ hashFiles('*/external/binaries-list', 
'*/*/external/binaries-list') }}
+          restore-keys: ${{ runner.os }}-
+          
+      - name: Checkout
+        uses: actions/checkout@v2
+
+      - name: Build NetBeans
+        run: ant -Dcluster.config=release build-nozip
+
+      - name: Archive Build
+        if: ${{ matrix.java == '11' }}
+        run: tar -czf /tmp/build.tar.gz --exclude ".git" .
+
+      - name: Upload Build
+        if: ${{ matrix.java == '11' }}
+        uses: actions/upload-artifact@v3
+        with:
+          name: build
+          path: /tmp/build.tar.gz
+          retention-days: 1
+          if-no-files-found: error
+
+
+# secondary jobs
+  linux-commit-validation:
+    needs: base-build
+    name: Commit Validation on Linux/JDK ${{ matrix.java }} 
+    runs-on: ubuntu-latest
+    env:
+      ANT_OPTS: 
-Dmetabuild.jsonurl=https://raw.githubusercontent.com/apache/netbeans-jenkins-lib/master/meta/netbeansrelease.json
+    strategy:
+      matrix:
+        java: [ '11' ]
+    steps:
+
+      - name: Set up JDK ${{ matrix.java }} 
+        uses: actions/setup-java@v2
+        with:
+          java-version: ${{ matrix.java }} 
+          distribution: 'zulu'
+
+      - name: Download Build
+        uses: actions/download-artifact@v3
+        with:
+          name: build
+
+      - name: Extract
+        run: tar -xzf build.tar.gz --exclude nbbuild/build/test
+        
+      - name: Commit Validation tests
+        run: ant -Dcluster.config=release commit-validation
+
+  linux-build-system-test:
+    needs: base-build
+    name: Build-System Test on Linux/JDK ${{ matrix.java }} 
+    runs-on: ubuntu-latest
+    env:
+      ANT_OPTS: 
-Dmetabuild.jsonurl=https://raw.githubusercontent.com/apache/netbeans-jenkins-lib/master/meta/netbeansrelease.json
+    strategy:
+      matrix:
+        java: [ '11' ]
+    steps:
+
+      - name: Set up JDK ${{ matrix.java }} 
+        uses: actions/setup-java@v2
+        with:
+          java-version: ${{ matrix.java }} 
+          distribution: 'zulu'
+
+      - name: Download Build
+        uses: actions/download-artifact@v3
+        with:
+          name: build
+
+      - name: Extract
+        run: tar -xzf build.tar.gz --exclude nbbuild/build/test
+
+      - name: Test Netbeans Build System
+        run: ant -Dcluster.config=release localtest
+
+  linux-javadoc:
+    needs: base-build
+    name: Build NBMs, Source zips and Javadoc on JDK ${{ matrix.java }} 
+    runs-on: ubuntu-latest
+    strategy:
+      matrix:
+        java: [ '11' ]
+    env:
+      ANT_OPTS: 
-Dmetabuild.jsonurl=https://raw.githubusercontent.com/apache/netbeans-jenkins-lib/master/meta/netbeansrelease.json
+    steps:
+
+      - name: Set up JDK ${{ matrix.java }} 
+        uses: actions/setup-java@v2
+        with:
+          java-version: ${{ matrix.java }} 
+          distribution: 'zulu'
+
+      - name: Download Build
+        uses: actions/download-artifact@v3
+        with:
+          name: build
+
+      - name: Extract
+        run: tar -xzf build.tar.gz --exclude nbbuild/build/test
+
+      - name: Get maven coordinates
+        run: ant getallmavencoordinates
+
+      - name: Build nbms
+        run: ant build-nbms
+
+      - name: Build source zips
+        run: ant build-source-zips
+
+      - name: Build javadoc
+        run: ant build-javadoc
+
+  macos:
+    needs: base-build
+    name: Tests on MacOS/JDK ${{ matrix.java }} 
+    runs-on: macos-11
+    env:
+      ANT_OPTS: 
-Dmetabuild.jsonurl=https://raw.githubusercontent.com/apache/netbeans-jenkins-lib/master/meta/netbeansrelease.json
+    strategy:
+      matrix:
+        java: [ '11' ]
+    steps:
+
+      - name: Set up JDK ${{ matrix.java }} 
+        uses: actions/setup-java@v2
+        with:
+          java-version: ${{ matrix.java }} 
+          distribution: 'zulu'
+
+      - uses: actions/cache@v2
+        with:
+          path: ~/Library/Caches/Homebrew
+          key: ${{ runner.os }}-homebrew
+          restore-keys: ${{ runner.os }}-homebrew
+
+      - name: Download Build
+        uses: actions/download-artifact@v3
+        with:
+          name: build
+
+      - name: Extract
+        run: tar -xzf build.tar.gz --exclude nbbuild/build/test
+
+      - run: brew install ant
+
+      - name: Test platform/masterfs.macosx
+        run: ant -f platform/masterfs.macosx test

Review comment:
       @JaroslavTulach but let me ask first: is there a reason you prefer a 
test distribution over the full workspace approach? It is basically like 
testing a fresh clone, just from a snapshot which has been already built.
   
   My main argument for a test-dist is the reduced artifact size (it still 
going to be big!). But I am not sure if that is a problem with 1 day retention 
time. Its likely that we will have to ask someone from apache infra anyway - 
even if we reduce the artifact size by using a test dist build.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to