-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix #8 fix #27 * Add some scripts to release * dev/release/prepare.sh: For a new release. * dev/release/tag.sh: For tagging. * See https://datafusion-contrib.github.io/datafusion-c/main/developer/release.html how to release a new version. * Add support for GitHub Releases * Create a release page automatically when we tag a new version * Add support for publishing .deb/.rpm to https://apache.jfrog.io/artifactory/arrow/ * See also: https://lists.apache.org/thread/f47nmpmmydmr9613jty21sgbv83pr9tq
- Loading branch information
Showing
21 changed files
with
611 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# Copyright 2022 Sutou Kouhei <kou@clear-code.com> | ||
# | ||
# Licensed 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. | ||
|
||
/vendor/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
#!/bin/bash | ||
# | ||
# Copyright 2022 Sutou Kouhei <kou@clear-code.com> | ||
# | ||
# Licensed 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 -eux | ||
|
||
if [ $# -lt 1 ]; then | ||
echo "Usage: $0 version" | ||
echo " e.g.: $0 11.0.0" | ||
exit 1 | ||
fi | ||
|
||
version=$1 | ||
major_version=$(echo ${version} | grep -o -E '^[0-9]+') | ||
|
||
source_dir="$(dirname "$0")/../.." | ||
|
||
git fetch origin --tags | ||
|
||
branch="prepare-${version}" | ||
git branch -D ${branch} || : | ||
git checkout -b ${branch} origin/main | ||
|
||
pushd "${source_dir}" | ||
sed -i'.bak' \ | ||
-e "s/^version = \".*\"/version = \"${version}\"/" \ | ||
Cargo.toml | ||
rm Cargo.toml.bak | ||
git add Cargo.toml | ||
|
||
sed -i'.bak' \ | ||
-e "s/^version = \'.*\'/version = \"${version}\"/" \ | ||
meson.build | ||
rm meson.build.bak | ||
git add meson.build | ||
popd | ||
|
||
pushd "${source_dir}/package/debian/" | ||
sed -i'.bak' -E \ | ||
-e "s/libdatafusion[0-9]+/libdatafusion${major_version}/g" \ | ||
-e "s/libdatafusion-glib[0-9]+/libdatafusion-glib${major_version}/g" \ | ||
-e "s/gir1\.2-datafusion-[0-9]+/gir1.2-datafusion-${major_version}/g" \ | ||
control | ||
rm control.bak | ||
git add control | ||
git mv gir1.2-datafusion-*.install \ | ||
gir1.2-datafusion-${major_version}.0.install | ||
git mv libdatafusion-glib[[:alnum:]]*.install \ | ||
libdatafusion-glib${major_version}.install | ||
git mv libdatafusion[[:alnum:]]*.install \ | ||
libdatafusion${major_version}.install | ||
popd | ||
|
||
pushd "${source_dir}/doc/" | ||
latest_news_md=$(ls source/news/*.md | sort -n -r | head -n1) | ||
sed \ | ||
-e "s/^# .*\$/# ${version} - $(date +%Y-%m-%d)/" \ | ||
${latest_news_md} > source/news/${version}.md | ||
git add source/news/${version}.md | ||
sed -i'.bak' \ | ||
-e "N; /^\.\. toctree::/ a \ \ \ news/${version}" \ | ||
source/news.rst | ||
rm source/news.rst.bak | ||
git add source/news.rst | ||
sed -i'.bak' \ | ||
-e "\,^ 'source' / 'news\.rst', i \ \ 'source' / 'news' / '${version}.md'," \ | ||
meson.build | ||
rm meson.build.bak | ||
git add meson.build | ||
popd | ||
|
||
pushd "${source_dir}/package" | ||
rake version:update | ||
git add . | ||
popd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#!/bin/bash | ||
# | ||
# Copyright 2022 Sutou Kouhei <kou@clear-code.com> | ||
# | ||
# Licensed 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 -eux | ||
|
||
source_dir="$(dirname "$0")/../.." | ||
|
||
version=$(grep "^version" "${source_dir}/Cargo.toml" | \ | ||
head -n1 | \ | ||
grep -o "[0-9.]*") | ||
git tag -a -m "Release ${version}!!!" ${version} | ||
git push origin ${version} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
#!/bin/bash | ||
# | ||
# Copyright 2022 Sutou Kouhei <kou@clear-code.com> | ||
# | ||
# Licensed 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 -eux | ||
|
||
if [ $# -lt 1 ]; then | ||
echo "Usage: $0 rc" | ||
echo " $0 staging-rc" | ||
echo " $0 release" | ||
echo " $0 staging-release" | ||
echo " e.g.: $0 rc # Verify RC packages" | ||
echo " e.g.: $0 staging-rc # Verify RC packages on staging" | ||
echo " e.g.: $0 release # Verify release packages" | ||
echo " e.g.: $0 staging-release # Verify release packages on staging" | ||
exit 1 | ||
fi | ||
|
||
verify_type="$1" | ||
|
||
source_dir="$(dirname "$0")/../.." | ||
|
||
pushd "${source_dir}" | ||
for dir in package/{apt,yum}/*; do | ||
if [ ! -d "${dir}" ]; then | ||
continue | ||
fi | ||
base_name=${dir##*/} | ||
distribution= | ||
code_name= | ||
case ${base_name} in | ||
*-aarch64|*-arm64) | ||
;; | ||
almalinux-*|debian-*|ubuntu-*) | ||
distribution=${base_name%-*} | ||
code_name=${base_name#*-} | ||
;; | ||
esac | ||
if [ "${distribution}" = "" -o "#{code_name}" = "" ]; then | ||
continue | ||
fi | ||
package_type=$(basename "$(dirname "${dir}")") | ||
docker run \ | ||
--rm \ | ||
--volume "$PWD:/host" \ | ||
-it \ | ||
${distribution}:${code_name} \ | ||
/host/package/${package_type}/test.sh \ | ||
"${verify_type}" | ||
done | ||
popd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
.. Copyright 2022 Sutou Kouhei <kou@clear-code.com> | ||
Licensed 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 | ||
Developer | ||
========= | ||
|
||
.. toctree:: | ||
|
||
developer/release |
Oops, something went wrong.