Skip to content

Commit

Permalink
Add rat files back in
Browse files Browse the repository at this point in the history
  • Loading branch information
alamb committed May 15, 2021
1 parent 6a5c91c commit f52763d
Show file tree
Hide file tree
Showing 2 changed files with 150 additions and 0 deletions.
107 changes: 107 additions & 0 deletions dev/release/rat_exclude_files.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
*.npmrc
*.gitignore
.gitmodules
*_generated.h
*_generated.js
*_generated.ts
*.csv
*.json
*.snap
.github/ISSUE_TEMPLATE/*.md
.github/pull_request_template.md
ci/etc/rprofile
ci/etc/*.patch
ci/vcpkg/*.patch
CHANGELOG.md
dev/requirements*.txt
dev/archery/MANIFEST.in
dev/archery/requirements*.txt
dev/archery/archery/tests/fixtures/*
dev/archery/archery/crossbow/tests/fixtures/*
dev/release/rat_exclude_files.txt
dev/tasks/homebrew-formulae/apache-arrow.rb
dev/tasks/linux-packages/apache-arrow-apt-source/debian/apache-arrow-apt-source.install
dev/tasks/linux-packages/apache-arrow-apt-source/debian/compat
dev/tasks/linux-packages/apache-arrow-apt-source/debian/control
dev/tasks/linux-packages/apache-arrow-apt-source/debian/rules
dev/tasks/linux-packages/apache-arrow-apt-source/debian/source/format
dev/tasks/linux-packages/apache-arrow/debian/compat
dev/tasks/linux-packages/apache-arrow/debian/control.in
dev/tasks/linux-packages/apache-arrow/debian/gir1.2-arrow-1.0.install
dev/tasks/linux-packages/apache-arrow/debian/gir1.2-arrow-cuda-1.0.install
dev/tasks/linux-packages/apache-arrow/debian/gir1.2-arrow-dataset-1.0.install
dev/tasks/linux-packages/apache-arrow/debian/gir1.2-gandiva-1.0.install
dev/tasks/linux-packages/apache-arrow/debian/gir1.2-parquet-1.0.install
dev/tasks/linux-packages/apache-arrow/debian/gir1.2-plasma-1.0.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-glib-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-glib-doc.doc-base
dev/tasks/linux-packages/apache-arrow/debian/libarrow-glib-doc.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-glib-doc.links
dev/tasks/linux-packages/apache-arrow/debian/libarrow-glib400.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-cuda-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-cuda-glib-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-cuda-glib400.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-cuda400.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-dataset-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-dataset-glib-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-dataset-glib-doc.doc-base
dev/tasks/linux-packages/apache-arrow/debian/libarrow-dataset-glib-doc.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-dataset-glib-doc.links
dev/tasks/linux-packages/apache-arrow/debian/libarrow-dataset-glib400.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-dataset400.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-flight-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-flight400.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-python-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-python-flight-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-python-flight400.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow-python400.install
dev/tasks/linux-packages/apache-arrow/debian/libarrow400.install
dev/tasks/linux-packages/apache-arrow/debian/libgandiva-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libgandiva-glib-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libgandiva-glib-doc.doc-base
dev/tasks/linux-packages/apache-arrow/debian/libgandiva-glib-doc.install
dev/tasks/linux-packages/apache-arrow/debian/libgandiva-glib-doc.links
dev/tasks/linux-packages/apache-arrow/debian/libgandiva-glib400.install
dev/tasks/linux-packages/apache-arrow/debian/libgandiva400.install
dev/tasks/linux-packages/apache-arrow/debian/libparquet-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libparquet-glib-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libparquet-glib-doc.doc-base
dev/tasks/linux-packages/apache-arrow/debian/libparquet-glib-doc.install
dev/tasks/linux-packages/apache-arrow/debian/libparquet-glib-doc.links
dev/tasks/linux-packages/apache-arrow/debian/libparquet-glib400.install
dev/tasks/linux-packages/apache-arrow/debian/libparquet400.install
dev/tasks/linux-packages/apache-arrow/debian/libplasma-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libplasma-glib-dev.install
dev/tasks/linux-packages/apache-arrow/debian/libplasma-glib-doc.doc-base
dev/tasks/linux-packages/apache-arrow/debian/libplasma-glib-doc.install
dev/tasks/linux-packages/apache-arrow/debian/libplasma-glib-doc.links
dev/tasks/linux-packages/apache-arrow/debian/libplasma-glib400.install
dev/tasks/linux-packages/apache-arrow/debian/libplasma400.install
dev/tasks/linux-packages/apache-arrow/debian/patches/series
dev/tasks/linux-packages/apache-arrow/debian/plasma-store-server.install
dev/tasks/linux-packages/apache-arrow/debian/rules
dev/tasks/linux-packages/apache-arrow/debian/source/format
dev/tasks/linux-packages/apache-arrow/debian/watch
dev/tasks/requirements*.txt
dev/tasks/conda-recipes/*
pax_global_header
MANIFEST.in
__init__.pxd
__init__.py
requirements.txt
*.html
*.sgml
*.css
*.png
*.ico
*.svg
*.devhelp2
*.scss
.gitattributes
arrow/test/data/*.csv
rust-toolchain
arrow-flight/src/arrow.flight.protocol.rs
ballista/rust/benchmarks/tpch/queries/q*.sql
ballista/rust/scheduler/testdata/*
ballista/ui/scheduler/yarn.lock
43 changes: 43 additions & 0 deletions dev/release/run-rat.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
#!/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.
#

RAT_VERSION=0.13

# download apache rat
if [ ! -f apache-rat-${RAT_VERSION}.jar ]; then
curl -s https://repo1.maven.org/maven2/org/apache/rat/apache-rat/${RAT_VERSION}/apache-rat-${RAT_VERSION}.jar > apache-rat-${RAT_VERSION}.jar
fi

RAT="java -jar apache-rat-${RAT_VERSION}.jar -x "

RELEASE_DIR=$(cd "$(dirname "$BASH_SOURCE")"; pwd)

# generate the rat report
$RAT $1 > rat.txt
python $RELEASE_DIR/check-rat-report.py $RELEASE_DIR/rat_exclude_files.txt rat.txt > filtered_rat.txt
cat filtered_rat.txt
UNAPPROVED=`cat filtered_rat.txt | grep "NOT APPROVED" | wc -l`

if [ "0" -eq "${UNAPPROVED}" ]; then
echo "No unapproved licenses"
else
echo "${UNAPPROVED} unapproved licences. Check rat report: rat.txt"
exit 1
fi

0 comments on commit f52763d

Please sign in to comment.