[Galago-commits] r2596 - in trunk/galago-daemon: . tools
galago-commits at freedesktop.org
galago-commits at freedesktop.org
Mon Mar 13 23:11:56 PST 2006
Author: chipx86
Date: 2006-03-13 23:11:49 -0800 (Mon, 13 Mar 2006)
New Revision: 2596
Removed:
trunk/galago-daemon/tools/list-accounts.c
trunk/galago-daemon/tools/list-my-accounts.c
trunk/galago-daemon/tools/list-people.c
trunk/galago-daemon/tools/list-services.c
Modified:
trunk/galago-daemon/ChangeLog
trunk/galago-daemon/tools/Makefile.am
Log:
Move a bunch of stuff from tools/ to libgalago/tests/.
Modified: trunk/galago-daemon/ChangeLog
===================================================================
--- trunk/galago-daemon/ChangeLog 2006-03-14 06:40:49 UTC (rev 2595)
+++ trunk/galago-daemon/ChangeLog 2006-03-14 07:11:49 UTC (rev 2596)
@@ -1,3 +1,12 @@
+Mon Mar 13 23:11:32 PST 2006 Christian Hammond <chipx86 at chipx86.com>
+
+ D tools/list-accounts.c:
+ D tools/list-my-accounts.c:
+ D tools/list-people.c:
+ D tools/list-services.c:
+ * tools/Makefile.am:
+ - Move a bunch of stuff from tools/ to libgalago/tests/.
+
Mon Feb 13 00:21:19 PST 2006 Christian Hammond <chipx86 at chipx86.com>
D debian:
Modified: trunk/galago-daemon/tools/Makefile.am
===================================================================
--- trunk/galago-daemon/tools/Makefile.am 2006-03-14 06:40:49 UTC (rev 2595)
+++ trunk/galago-daemon/tools/Makefile.am 2006-03-14 07:11:49 UTC (rev 2596)
@@ -1,22 +1,6 @@
noinst_PROGRAMS = \
- list-accounts \
- list-my-accounts \
- list-people \
- list-services \
shutdown-daemon
-list_accounts_SOURCES = list-accounts.c
-list_accounts_LDADD = $(PACKAGE_LIBS)
-
-list_my_accounts_SOURCES = list-my-accounts.c
-list_my_accounts_LDADD = $(PACKAGE_LIBS)
-
-list_people_SOURCES = list-people.c
-list_people_LDADD = $(PACKAGE_LIBS)
-
-list_services_SOURCES = list-services.c
-list_services_LDADD = $(PACKAGE_LIBS)
-
shutdown_daemon_SOURCES = shutdown-daemon.c
shutdown_daemon_LDADD = $(PACKAGE_LIBS)
Deleted: trunk/galago-daemon/tools/list-accounts.c
===================================================================
--- trunk/galago-daemon/tools/list-accounts.c 2006-03-14 06:40:49 UTC (rev 2595)
+++ trunk/galago-daemon/tools/list-accounts.c 2006-03-14 07:11:49 UTC (rev 2596)
@@ -1,88 +0,0 @@
-/**
- * @file list-accounts.c Displays a list of accounts.
- *
- * @Copyright (C) 2004-2005 Christian Hammond
- *
- * 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 the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public
- * License along with this program; if not, write to the Free
- * Software Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- */
-#include <libgalago/galago.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-static void
-display_service(GalagoService *service)
-{
- GList *l;
-
- printf("%s (%s):\n",
- galago_service_get_name(service),
- galago_service_get_id(service));
-
- for (l = galago_service_get_accounts(service, TRUE);
- l != NULL;
- l = l->next)
- {
- GalagoAccount *account = (GalagoAccount *)l->data;
- GalagoPerson *person = galago_account_get_person(account);
-
- printf("\t%s%s\n", galago_account_get_username(account),
- (galago_person_is_me(person) ? " (me)" : ""));
- }
-
- printf("\n");
-}
-
-int
-main(int argc, char **argv)
-{
- char *service_id = NULL;
-
- if (!galago_init("list-accounts-test", FALSE) ||
- !galago_is_connected())
- {
- fprintf(stderr, "Unable to connect to the Galago service.\n");
- exit(1);
- }
-
- if (argc > 1)
- service_id = argv[1];
-
- if (service_id == NULL)
- {
- GList *l;
-
- for (l = galago_get_services(GALAGO_REMOTE, TRUE);
- l != NULL;
- l = l->next)
- {
- display_service((GalagoService *)l->data);
- }
- }
- else
- {
- GalagoService *service;
-
- service = galago_get_service(service_id, GALAGO_REMOTE, TRUE);
-
- if (service == NULL)
- printf("%s is not a known service\n", service_id);
- else
- display_service(service);
- }
-
- return 0;
-}
Deleted: trunk/galago-daemon/tools/list-my-accounts.c
===================================================================
--- trunk/galago-daemon/tools/list-my-accounts.c 2006-03-14 06:40:49 UTC (rev 2595)
+++ trunk/galago-daemon/tools/list-my-accounts.c 2006-03-14 07:11:49 UTC (rev 2596)
@@ -1,52 +0,0 @@
-/**
- * @file list-my-accounts.c Displays a list of all accounts
- * from the "Me" user.
- *
- * @Copyright (C) 2004-2005 Christian Hammond
- *
- * 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 the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public
- * License along with this program; if not, write to the Free
- * Software Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- */
-#include <libgalago/galago.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-int
-main(int argc, char **argv)
-{
- GList *l;
- GalagoPerson *me;
-
- if (!galago_init("list-accounts-test", FALSE) ||
- !galago_is_connected())
- {
- fprintf(stderr, "Unable to connect to the Galago service.\n");
- exit(1);
- }
-
- me = galago_get_me(GALAGO_REMOTE, TRUE);
-
- for (l = galago_person_get_accounts(me, TRUE); l != NULL; l = l->next)
- {
- GalagoAccount *account = (GalagoAccount *)l->data;
-
- printf("%s (%s)\n",
- galago_account_get_username(account),
- galago_service_get_name(galago_account_get_service(account)));
- }
-
- return 0;
-}
Deleted: trunk/galago-daemon/tools/list-people.c
===================================================================
--- trunk/galago-daemon/tools/list-people.c 2006-03-14 06:40:49 UTC (rev 2595)
+++ trunk/galago-daemon/tools/list-people.c 2006-03-14 07:11:49 UTC (rev 2596)
@@ -1,101 +0,0 @@
-/**
- * @file list-people.c Displays a list of all people.
- *
- * @Copyright (C) 2004-2005 Christian Hammond
- *
- * 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 the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public
- * License along with this program; if not, write to the Free
- * Software Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- */
-#include <libgalago/galago.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-static void
-display_person(GalagoPerson *person)
-{
- GList *l;
- const char *display_name, *uid, *me_text = "";
- const char *displayed_uid;
-
- uid = galago_person_get_id(person);
- display_name = galago_person_get_display_name(person);
-
- if (galago_person_is_me(person))
- me_text = " (me) ";
-
- if (uid == NULL)
- displayed_uid = "no uid";
- else
- displayed_uid = uid;
-
- if (display_name == NULL)
- printf("%s<%s>:\n", me_text, displayed_uid);
- else
- printf("%s %s<%s>\n", display_name, me_text, displayed_uid);
-
- for (l = galago_person_get_accounts(person, TRUE); l != NULL; l = l->next)
- {
- GalagoAccount *account = (GalagoAccount *)l->data;
- GalagoService *service = galago_account_get_service(account);
-
- printf("\t%s (%s)\n",
- galago_account_get_username(account),
- galago_service_get_name(service));
- }
-
- printf("\n");
-}
-
-int
-main(int argc, char **argv)
-{
- char *person_uid = NULL;
-
- if (!galago_init("list-people-test", FALSE) ||
- !galago_is_connected())
- {
- fprintf(stderr, "Unable to connect to the Galago service.\n");
- exit(1);
- }
-
- if (argc > 1)
- person_uid = argv[1];
-
- if (person_uid == NULL)
- {
- GList *l;
-
- for (l = galago_get_people(GALAGO_REMOTE, TRUE);
- l != NULL;
- l = l->next)
- {
- display_person((GalagoPerson *)l->data);
- }
- }
- else
- {
- GalagoPerson *person;
-
- person = galago_get_person(person_uid, GALAGO_REMOTE, TRUE);
-
- if (person == NULL)
- printf("%s is not a known person UID\n", person_uid);
- else
- display_person(person);
- }
-
- return 0;
-}
Deleted: trunk/galago-daemon/tools/list-services.c
===================================================================
--- trunk/galago-daemon/tools/list-services.c 2006-03-14 06:40:49 UTC (rev 2595)
+++ trunk/galago-daemon/tools/list-services.c 2006-03-14 07:11:49 UTC (rev 2596)
@@ -1,50 +0,0 @@
-/**
- * @file list-services.c Displays a list of services.
- *
- * @Copyright (C) 2004-2005 Christian Hammond
- *
- * 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 the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public
- * License along with this program; if not, write to the Free
- * Software Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- */
-#include <libgalago/galago.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-
-int
-main(int argc, char **argv)
-{
- GList *l;
-
- if (!galago_init("list-services-test", FALSE) ||
- !galago_is_connected())
- {
- fprintf(stderr, "Unable to connect to the Galago service.\n");
- exit(1);
- }
-
- for (l = galago_get_services(GALAGO_REMOTE, TRUE);
- l != NULL;
- l = l->next)
- {
- GalagoService *service = (GalagoService *)l->data;
-
- printf("%-10s - %s\n",
- galago_service_get_id(service),
- galago_service_get_name(service));
- }
-
- return 0;
-}
More information about the galago-commits
mailing list