Radish alpha
H
rad:z3QDZAW2FAfuLvihrhiyDC9fAD8G9
HardenedBSD Package Manager
Radicle
Git
Use .txz for digests file as well.
Vsevolod Stakhov committed 13 years ago
commit 8072a3cb6fbce0bce267f3febcb15cca28f472e3
parent bb6a616
3 files changed +8 -3
modified libpkg/pkg_repo.c
@@ -930,7 +930,8 @@ read_pkg_file(void *data)

		if (strcmp(fts_name, "repo.txz") == 0 ||
			strcmp(fts_name, "packagesite.txz") == 0 ||
-
			strcmp(fts_name, "filesite.txz") == 0)
+
			strcmp(fts_name, "filesite.txz") == 0 ||
+
			strcmp(fts_name, "digests.txz") == 0)
			continue;

		pkg_path = fts_path;
@@ -1015,6 +1016,10 @@ pkg_finish_repo(char *path, pem_password_cb *password_cb, char *rsa_key_path)
	snprintf(repo_archive, sizeof(repo_archive), "%s/filesite", path);
	pack_db("filesite.yaml", repo_archive, repo_path, rsa_key_path, password_cb);

+
	snprintf(repo_path, sizeof(repo_path), "%s/digests", path);
+
	snprintf(repo_archive, sizeof(repo_archive), "%s/digests", path);
+
	pack_db("digests", repo_archive, repo_path, rsa_key_path, password_cb);
+

	return (EPKG_OK);
}

modified pkg/install.c
@@ -47,7 +47,7 @@ void
usage_install(void)
{
	fprintf(stderr,
-
	    "usage: pkg install [-AfgIinqRUxy] [-r reponame] <pkg-name> ...\n\n");
+
	    "usage: pkg install [-AfgIinFqRUxy] [-r reponame] <pkg-name> ...\n\n");
	fprintf(stderr, "For more information see 'pkg help install'.\n");
}

modified pkg/upgrade.c
@@ -39,7 +39,7 @@
void
usage_upgrade(void)
{
-
	fprintf(stderr, "usage: pkg upgrade [-fInqUy] [-r reponame]\n\n");
+
	fprintf(stderr, "usage: pkg upgrade [-fInFqUy] [-r reponame]\n\n");
	fprintf(stderr, "For more information see 'pkg help upgrade'.\n");
}