summaryrefslogtreecommitdiffstats
path: root/src/pacman/add.c
diff options
context:
space:
mode:
authorDan McGee <dan@archlinux.org>2007-04-25 08:27:16 +0200
committerDan McGee <dan@archlinux.org>2007-04-25 17:07:48 +0200
commit34aefc62e45cf221eccf65dd2bcf42ecd51630f3 (patch)
tree11fe5a8621e7243e228150bef55322d842e120d6 /src/pacman/add.c
parent5e1419c0b5cf717e57959bc27eeab1cfa4bea5dc (diff)
downloadpacman-34aefc62e45cf221eccf65dd2bcf42ecd51630f3.tar.gz
pacman-34aefc62e45cf221eccf65dd2bcf42ecd51630f3.tar.xz
Remove single-function upgrade.c
Move pacman_upgrade into add.c, at least for now. It really doesn't need its own file. For the long term, we may want to move this whole file back to upgrade.c if we deprecate the add operation. Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'src/pacman/add.c')
-rw-r--r--src/pacman/add.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/pacman/add.c b/src/pacman/add.c
index 632366c6..86091bdc 100644
--- a/src/pacman/add.c
+++ b/src/pacman/add.c
@@ -1,7 +1,7 @@
/*
* add.c
*
- * Copyright (c) 2002-2006 by Judd Vinet <jvinet@zeroflux.org>
+ * Copyright (c) 2002-2007 by Judd Vinet <jvinet@zeroflux.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -39,6 +39,14 @@
extern config_t *config;
+int pacman_upgrade(alpm_list_t *targets)
+{
+ /* this is basically just a remove-then-add process. pacman_add() will */
+ /* handle it */
+ config->upgrade = 1;
+ return(pacman_add(targets));
+}
+
int pacman_add(alpm_list_t *targets)
{
alpm_list_t *i = targets, *data = NULL;