Apache RAT is developed by the Apache Creadur project of the Apache Software Foundation. Join us at https://creadur.apache.org and read more about Apache RAT at https://creadur.apache.org/rat.
Release Audit Tool (RAT) is a tool to improve accuracy and efficiency when checking releases. It is heuristic in nature: making guesses about possible problems. It will produce false positives and cannot find every possible issue with a release. Its reports require interpretation.
RAT was developed in response to a need felt in the Apache Incubator to be able to review releases for the most common faults less labour intensively. It is therefore highly tuned to the Apache style of releases.
A good way to use RAT is to through the source. This allows the code base to be easily patched for example to add new generated file matchers. The main jar is runnable and self-documenting. This jar is available as a standard alone binary.
RAT includes a task library for Ant 1.7. This allows RAT reports to be run against a wide variety of resources. See ant-task-examples.xml. To use the Ant tasks, Apache Ant 1.7 is required. See https://ant.apache.org/.
For Maven builds, the plugin is recommended.
In response to demands from project quality tool developers, RAT is available as a library (rat-lib jar) suitable for inclusion in tools.
Note that binary compatibility is not guaranteed between 0.x releases. The XML output format is not yet in its final form and so library users are recommended to either use the supplied stylesheets or keep in close touch with the code.
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.
If you want to contribute, feel free to branch from master and provide a pull request via GitHub. You should file a contributor license agreement in order to properly handle your input. Apart from that you can file an issue in ASF's Jira: project RAT
RAT is developed using the Maven build tool. The simplest method for building RAT is to clone the repository and execute mvn install
. The ./mvnw
, or ./mvnw.cmd
scripts can be run in place of the mvn
command.
The RAT build generates some source and copies test data, therefore it is necessary to run one of three commands to initially configure the system:
mvn package
../mvnw verify
mvn install
.To build without running the tests add -Dmaven.test.skip=true
to the mvn
or mvnw
command line.
RAT uses the previous release version during the build to verify it complies its own rules.
The “apache-release” profile creates the source release archive as part of the build process and is only relevant during release builds.
The “release-notes” profile generates the RELEASE-NOTES.txt
in the top-level directory from the src/changes/changes.xml
file using the maven-changes-plugin plugin.
Usage: mvn changes:announcement-generate -Prelease-notes [-Dchanges.version=nnn]
Defining changes.version creates the release notice without first removing the SNAPSHOT suffix.
Requires: file src/changes/release-notes.vm
to format the changes.xml.
To import RAT into Eclipse,
creadur-rat
project and execute “Run As -> Maven install”The above steps will generate the necessary source code as well as testing resources.
To import RAT into IntelliJ
The above steps will generate the necessary source code as well as testing resources.