Skip to content

OpenPj is publishing release artifacts #2

OpenPj is publishing release artifacts

OpenPj is publishing release artifacts #2

#
# 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: Publish Release Artifacts
run-name: ${{ github.actor }} is publishing release artifacts
on:
workflow_dispatch:
inputs:
release:
type: choice
description: Select the ManifoldCF release
options:
- release-2.26 #Java 11
- release-2.25
- release-2.24
- release-2.23
- release-2.22
- release-2.21
- release-2.20
- release-2.19
- release-2.18
- release-2.17
- release-2.16
- release-2.15
- release-2.14
- release-2.13
- release-2.12
- release-2.11
- release-2.10
- release-2.9
- release-2.8
- release-2.7 #Java 1.8
- release-2.6
- release-2.5
- release-2.4
- release-2.3
- release-2.2
- release-2.1
- release-2.0 #Java 1.7
- release-1.9
- release-1.8
- release-1.2 #Java 1.6
- release-1.1
- release-1.0 #Java 1.5
jobs:
deployReleaseMavenArtifacts:
if: github.repository == 'apache/manifoldcf'
name: "Deploy Apache ManifoldCF release artifacts"
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/[email protected]
with:
ref: ${{ github.event.inputs.release }}
- name: Set up Java
uses: actions/[email protected]
with:
java-version: '11'
distribution: 'temurin'
architecture: x64
cache: maven
server-id: apache.releases.https
server-username: NEXUS_USER
server-password: NEXUS_PW
- name: Ant Build
env:
RELEASE: ${{ inputs.release }}
run: |
if [[ $RELEASE == 'release-2.26' ]]; then
sed -i -e 's/<?xml version=\"1\.0\" encoding=\"UTF-8\"?>/ /g' connectors/csv/pom.xml
sed -i -e 's/https\:\/\/maven.nuxeo.org\/nexus\/content\/repositories\/public-releases/https\:\/\/packages.nuxeo.com\/repository\/maven-public-archives/g' build.xml
sed -i -e 's/https\:\/\/maven.nuxeo.org\/nexus\/content\/repositories\/public-releases\//https\:\/\/packages.nuxeo.com\/repository\/maven-public-archives/g' connectors/nuxeo/pom.xml
sed -i -e 's/<\/dependencies>/<dependency><groupId>org.apache.hadoop<\/groupId><artifactId>hadoop-annotations<\/artifactId><version>\${hadoop.version}<\/version><exclusions><exclusion><groupId>jdk.tools<\/groupId><artifactId>jdk.tools<\/artifactId><\/exclusion><\/exclusions><\/dependency><\/dependencies>/g' connectors/hdfs/pom.xml
fi
ant make-core-deps make-deps image
- name: Maven Build
run: mvn clean install -B -DskipTests -DskipITs
- name: Deploy
env:
NEXUS_USER: ${{ secrets.NEXUS_USER }}
NEXUS_PW: ${{ secrets.NEXUS_PW }}
run: mvn deploy -B -e -DskipTests -DskipITs