Mercurial > pidgin
diff src/main.c @ 8596:56360561af5e
[gaim-migrate @ 9347]
" This patch creates a new command line argument ('-c' or
'--config') that allows the location of tha gaim prefs
files to be located somewhere other than in ~/.gaim
The patch also removes the -f argument as it is no
longer relevant since .gaimrc is all but gone.
The one "weirdness" is that for the session managment
support, the --config argument will allways appear to
be specified and will contain either the custom value
(if specified) or the canonical version of ~/.gaim (if
no custom -c is specified). If this should be done
differently, let me know." --Daniel Atallah
committer: Tailor Script <tailor@pidgin.im>
author | Luke Schierer <lschiere@pidgin.im> |
---|---|
date | Tue, 06 Apr 2004 14:29:51 +0000 |
parents | e38c127ec2d4 |
children | cfb11d9a46fd |
line wrap: on
line diff
--- a/src/main.c Tue Apr 06 05:41:12 2004 +0000 +++ b/src/main.c Tue Apr 06 14:29:51 2004 +0000 @@ -87,7 +87,6 @@ int opt_away = 0; int docklet_count = 0; char *opt_away_arg = NULL; -char *opt_rcfile_arg = NULL; int opt_debug = 0; #if HAVE_SIGNAL_H @@ -530,7 +529,7 @@ " account(s) to use, seperated by commas)\n" " -n, --loginwin don't automatically login; show login window\n" " -u, --user=NAME use account NAME\n" - " -f, --file=FILE use FILE as config\n" + " -c, --config=DIR use DIR for config files\n" " -d, --debug print debugging messages to stdout\n" " -v, --version display the current version and exit\n" " -h, --help display this help and exit\n"), VERSION, name); @@ -623,7 +622,7 @@ /*{"login", optional_argument, NULL, 'l'}, */ {"loginwin", no_argument, NULL, 'n'}, {"user", required_argument, NULL, 'u'}, - {"file", required_argument, NULL, 'f'}, + {"config", required_argument, NULL, 'c'}, {"debug", no_argument, NULL, 'd'}, {"version", no_argument, NULL, 'v'}, {"session", required_argument, NULL, 's'}, @@ -758,9 +757,9 @@ opterr = 1; while ((opt = getopt_long(argc, argv, #ifndef _WIN32 - "adhu:f:vns:", + "adhu:c:vns:", #else - "adhu:f:vn", + "adhu:c:vn", #endif long_options, NULL)) != -1) { switch (opt) { @@ -774,8 +773,8 @@ case 'd': /* debug */ opt_debug = 1; break; - case 'f': - opt_rcfile_arg = g_strdup(optarg); + case 'c': /* use specified config dir */ + set_gaim_user_dir(optarg); break; case 's': /* use existing session ID */ opt_session_arg = g_strdup(optarg);