add apk-manifest(8)

cute-signatures
Drew DeVault 2020-01-07 22:46:32 -05:00 committed by Timo Teräs
parent f3412acb85
commit 7c2c68df69
3 changed files with 36 additions and 1 deletions

View File

@ -14,6 +14,7 @@ docs: $(obj)/apk.8 \
$(obj)/apk-index.8 \
$(obj)/apk-info.8 \
$(obj)/apk-list.8 \
$(obj)/apk-manifest.8 \
$(obj)/apk-policy.8 \
$(obj)/apk-update.8 \
$(obj)/apk-upgrade.8 \

33
doc/apk-manifest.8.scd Normal file
View File

@ -0,0 +1,33 @@
apk-manifest(8)
# NAME
apk manifest - Show checksums of package contents
# SYNOPSIS
*apk manifest* [<_options_>...] _packages_...
# DESCRIPTION
*apk manifest* prints the checksums of files in the listed packages. One file
is printed per line, the checksum first, followed by a space, and then the path
to the file.
The checksum itself is printed in the format _algorithm_:_hash_. Supported
algorithms are:
- *md5*
- *sha1*
*sha1* is used for new packages.
# OPTIONS
*apk manifest* does not support any specific options. See *apk*(8) for global
options.
# AUTHORS
Natanael Copa <ncopa@alpinelinux.org>++
Timo Teräs <_timo.teras@iki.fi_>

View File

@ -5,7 +5,7 @@
* Copyright (C) 2017 William Pitcock <nenolod@dereferenced.org>
* All rights reserved.
*
* This program is free software; you can redistribute it and/or modify it
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 as published
* by the Free Software Foundation. See http://www.gnu.org/ for details.
*/
@ -21,6 +21,7 @@
/* TODO: support package files as well as generating manifest from the installed DB. */
static char *csum_types[APK_CHECKSUM_SHA1 + 1] = {
/* Note: if adding new algorithms, update apk-manifest(8) */
[APK_CHECKSUM_MD5] = "md5",
[APK_CHECKSUM_SHA1] = "sha1",
};