summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2011-01-15 11:50:47 +0100
committerDaniel Friesel <derf@finalrewind.org>2011-01-15 11:50:47 +0100
commit5cc2c324e269756464275741c35033d972cc645a (patch)
tree786f05bcde9cb8b25ff6620ae83ebb6937932609
parent788fa40bbf04868c3836c9b086c9979649e2c516 (diff)
BC for ~/.fehrc
-rw-r--r--src/options.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/options.c b/src/options.c
index f0e09b5..b4c18ea 100644
--- a/src/options.c
+++ b/src/options.c
@@ -148,6 +148,7 @@ static void feh_load_options_for_theme(char *theme)
FILE *fp = NULL;
char *home = getenv("HOME");
char *rcpath = NULL;
+ char *oldrcpath = NULL;
char *confbase = getenv("XDG_CONFIG_HOME");
char s[1024], s1[1024], s2[1024];
int cont = 0;
@@ -156,6 +157,8 @@ static void feh_load_options_for_theme(char *theme)
if (!home)
eprintf("You have no HOME, cannot read themes");
+ oldrcpath = estrjoin("/", home, ".fehrc", NULL);
+
if (confbase)
rcpath = estrjoin("/", confbase, "feh/themes", NULL);
else
@@ -165,6 +168,12 @@ static void feh_load_options_for_theme(char *theme)
free(rcpath);
+ if (!fp && ((fp = fopen(oldrcpath, "r")) != NULL))
+ weprintf("the config is now read from .config/feh/themes, "
+ "please update your path!");
+
+ free(oldrcpath);
+
if (!fp && ((fp = fopen("/etc/feh/themes", "r")) == NULL))
return;