This repository contains a collection of various qa scripts for gentoo ebuild repositories. Results of the these scripts can be seen on https://gentooqa.levelnine.at/
Repostats generates statistics about repos. Following statistics are generated:
EAPI
usage in repo9999
) ebuildsLICENSE
usage among ebuildsvirtual/*
usage among ebuildsEAPI
app-group/*
usage among ebuildsapp-user/*
usage among ebuildsrepochecks
scan ebuilds, categories or a whole repository for various errors and mistakes. Nowadays many checks are already done by the the amazing tool dev-util/pkgcheck
, which is why i've included the checks from pkgcheck
into repochecks
.
Since pkgcheck
already has mostly the same checks as repochecks
, checks which are basically the same are going to be removed in further updates.
Following a list of all the checks done with repochecks
and (if available) the correspondig check in pkgcheck
.
INSTALL
files--disable-dependency-tracking
enabled. Not needed since EAPI4
--disable-silent-rules
enabled. Not needed since EAPI5
--disable-static
enabled. Not needed since EAPI8
epatch
usage in EAPI 6
ebuilds
dohtml
usage in EAPI 6
ebuids
DESCRIPTION
is longer then 80 chars
HOMEPAGE
contains variables
git://
usageinherit
eclasses which are not needed
HOMEPAGE
to a know shutdown serviceHOMEPAGE
among ebuildsapp-arch/unzip
dependency
SRC_URI
is unavailable and are the ebuild has mirror restricted enabledSRC_URI
link still workswhitelist
for false-positivespkg_config
or pkg_postinst
pkgcheck scan --net --keywords=-info -q
on packages
pkgcheck
metadata.xml
) if it uses mixed tabs and whitespaces
metadata.xml
of proxy maintained packages if it includes actually a non gentoo email address (address of proxy maintainer)
metadata.xml
which already exists as a global use flag.metadata.xml
Following Structures can't be found (yet) and will give a false positive:
epatch foo-bar-${MY_VERS}.patch
apache-module
do that. However we exclude most of the beforehand.for i in name1 name2 name3; do
epatch foo-bar-$i.patch
done
files
directory will be ignored (for now)For a detailed explanation of each check please refer to the descriptions in repochecks
This script is used in order to run multiple repositories. It support to run scripts in diff
mode (git diffs) in order to only run on packages which were changes since last run.
This python script doesn't take any arguments and just prints every gentoo project and it members.
Simply prints the inheration tree of a particular eclass.
Removes obsolete entries from whitelist files (for unused patches)
Prints functions which can be used by ebuilds.
Following usage will work for repochecks
and repostats
:
./scriptname.sh full
./scriptname.sh app-admin
./scriptname.sh app-admin/diradm
There are also a few Variables which can be set, but don't have too. Most importantly are:
REPOTREE
: Set's the repository path, default is: /usr/portage
FILERESULTS
: If this is set to true
the script will save it's output in files. Default is false
RESULTSDIR
: This is the directory were the files will be copied if SCRIPT_MODE
is enabled. Default is set to ${HOME}/${scriptname}
Most script also have some debugging possibilities. Following variables can be configured:
DEBUG
: if this is set to true
, debugging is enabledDEBUGLEVEL
: if unset, the default is set to 1
. Changes in Levels:
1
only print basic information, in this case script runs in parallel2
includes important messages, script runs not in parallel anymore3
includes non important messages<=4
includes messages from _funcs.sh
as well.DEBUGFILE
: redirects the debug output into a file.All scripts are free software. You can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.