diff --git a/README.md b/README.md index 1893761b3..23500e01a 100644 --- a/README.md +++ b/README.md @@ -215,6 +215,23 @@ Then perform the release: ./mvnw release:perform -Prelease ``` +Go to https://repository.apache.org/ and close the staging repository. + +A URL will be generated for the repository, like: https://repository.apache.org/content/repositories/orgapachecamel-xxxx. The URL needs to be communicated during the voting process. + +Now run: + +``` +cd release-utils/scripts/ +./upload-sources.sh $CAMEL_KAMELET_VERSION $CAMEL_KAMELET_VERSION +``` + +You'll be requested to insert the password to unlock the secret key to sign the artifacts and after uploading to nexus dev repository. + +You could verify the result at the following URL: + +https://dist.apache.org/repos/dist/dev/camel/camel-kamelets/<$CAMEL_KAMELET_VERSION> + Restore Kamelets: ``` @@ -228,3 +245,5 @@ git commit -am "Restore Kamelets for development" git push upstream main ``` + +Send an email to dev mailing list to start the vote. diff --git a/release-utils/scripts/sign.sh b/release-utils/scripts/sign.sh new file mode 100755 index 000000000..cdd8b47b7 --- /dev/null +++ b/release-utils/scripts/sign.sh @@ -0,0 +1,35 @@ +#!/bin/sh + +# 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. + +# This is a utility script to sign and sha512 all files in the given directory. + +if [ "$#" -ne 1 ]; then + echo "usage: $0 dir" + exit 1 +fi + +dir=$1 + +pushd . && cd $dir + +for f in $(ls | grep -e ".*tar.gz$"); +do + sha512sum -b $f > $f.sha512 + gpg --output $f.asc --armor --detach-sig $f +done + +popd diff --git a/release-utils/scripts/upload-source.sh b/release-utils/scripts/upload-source.sh new file mode 100755 index 000000000..4ab9cf9c3 --- /dev/null +++ b/release-utils/scripts/upload-source.sh @@ -0,0 +1,36 @@ +#!/bin/bash + +# 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. + +set -e + +if [ "$#" -lt 2 ]; then + echo "usage: $0 upload-sources release-version destination-version" + exit 1 +fi + +location=$(dirname $0) +version=$1 + +mkdir $1/ +cd $1/ + +wget https://github.com/apache/camel-kamelets/archive/refs/tags/v$1.tar.gz -O camel-kamelets-sources-$1.tar.gz +cd ../ +./sign.sh $1/ +svn import $1/ https://dist.apache.org/repos/dist/dev/camel/camel-kamelets/$2/ -m "Import camel-kamelets release" + +rm -rf $1/