NAME
newver - Scan upstream for new software versions
SYNOPSIS
newver [options] file [program] ...
DESCRIPTION
newver is a program that scans for new software versions from upstream web pages and reports any new versions that were found. It similar to the Debian packaging tool uscan(1), but does not handle fetching new upstream sources and isn't associated with specific packaging schemes (like debs in the case of uscan(1)).
newver takes the name of scan file to read from as argument. Additional arguments are interpretted as the names of specific programs to scan updates for in the scan file. If no specific programs are given, then each program in the scan file is scanned.
Scan File
newver reads configuration from a scan file, which is an INI file that contains the list of programs to scan for new versions for.
newver INI files consist of program sections marked with the name of the program enclosed in square brackets. Each section contains a list of key-value pair lines, with the key and value be separated by an equals sign. Leading and trailing whitespace is trimmed from the key and value string.
Lines starting with a hash (#) are treated as comments and ignored. Blank lines are also ignored.
The following are valid configuration fields for program sections in a scan file:
- [program]
-
Each individual program in a scan file is marked by the name of the program encloesd in square brackets, like section headings in a traditional INI file.
- Version = version
-
String of the program's current version number. When scanning for new software versions, newver will look for versions that are considered to be greater than this version.
Either this field or
VersionScanare required. - VersionScan = file -- match
-
Scan for the program's current version number in
filematching the regexmatch.matchmust contain@VERSION@, which will capture the version number. newver will look for the first match and use that as the captured version.Either this field or
Versionare required. - Page = url
-
URL to scan for new upstream releases from.
This field is required.
- Match = match
-
Regex to use that matches upstream software releases.
matchmust contain@VERSION@, which will be used to capture the new version number.matchwill be matched against each page'shrefattribute under an<aelement.gtThis field is required.
- ReturnURL = url
-
URL to report for updated versions, instead of the default behavior of reporting the newest matched URL. Occurances of
@VERSION@in url will be replaced by the new version string.
OPTIONS
- j|--json
-
Report output as JSON. The outputted JSON structure will look something like this:
{ "perl" : { "current" : "5.016", "program" : "perl", "url" : "https://github.com/Perl/perl5/archive/refs/tags/v5.43.6.tar.gz", "version" : "5.43.6" } } - -s|--serial
-
Execute scans serially instead of in parallel.
- -V|--verbose
-
Enable verbose output. newver will print verbose messages to standard error.
- -h|--help
-
Print help message and exit.
- -v|--version
-
Print version and exit.
EXAMPLES
Example Scan File
# Example scan file
# Lines starting with '#' are read as comments and ignored
[noss]
Version = 2.00
# Look for <a> hrefs that match the following
Page = https://www.cpan.org/authors/id/S/SA/SAMYOUNG/
Match = WWW-Noss-@VERSION@.tar.gz
[perl]
# Look for current version in Makefile.PL matching the regex
VersionScan = Makefile.PL -- MIN_PERL_VERSION => '@VERSION@'
Page = https://github.com/repology/libversion/tags
Match = @VERSION@.tar.gz
[libversion]
Version = 3.0.3
Page = https://github.com/repology/libversion/tags
Match = @VERSION@.tar.gz
AUTHOR
Written by Samuel Young
This project's source can be found on its Codeberg page. Comments and pull requests are welcome.
COPYRIGHT
Copyright (C) 2025 Samuel Young.
This program is free software; you can redistribute it and/or modify it under the terms of the Artistic License 2.0.