Radish alpha
H
HardenedBSD Package Manager
Radicle
Git (anonymous pull)
Log in to clone via SSH
Warn user if no repos are enabled.
Vsevolod Stakhov committed 12 years ago
commit 0a108d8e4a5867ae1b95b16a622705fa5c32658d
parent 8cacbb9bc175a30399b50934e16e38f929706f36
1 file changed +5 -1
modified src/update.c
@@ -45,7 +45,7 @@
 */
int
pkgcli_update(bool force) {
-
	int retcode = EPKG_FATAL;
+
	int retcode = EPKG_FATAL, update_count = 0;
	struct pkg_repo *r = NULL;

	/* Only auto update if the user has write access. */
@@ -74,8 +74,12 @@ pkgcli_update(bool force) {
		}
		if (retcode != EPKG_OK)
			break;
+
		update_count ++;
	}

+
	if (!quiet && update_count == 0)
+
		printf("No repositories are enabled\n");
+

	return (retcode);
}