Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

"daemon" in the configuration enabled daemon mode by default, -d disa…

…bles

it again.
  • Loading branch information...
commit 4dd0d1c5905e30d0d7bd578727fcdc61ccedfa27 1 parent 6fe54a6
Jonas Kramer authored
View
5 manual/shell-fm.1
@@ -176,6 +176,11 @@ This allows you to color format elements. The
may be the letter of any format flag (without percent). The color is just a
normal shell color code matching "[01];3[0-7]". Whenever the format element is
printed to the console, it will have the given color. Have a look at the
+.TP
+.B daemon = something
+If this is set to something, shell-fm will start in daemon mode by default.
+Starting with -d as command line option will disable daemon mode.
+.TP
.B COLORS
section for a list.
.TP
View
2  scripts/vim/syntax/shell-fm-rc.vim
@@ -18,7 +18,7 @@ syn keyword ShellFMKnownKey contained
\ username password default-radio np-file np-file-format np-cmd
\ pp-cmd bind port extern proxy expiry device title-format minimum
\ delay-change screen-format term-format download gap discovery
- \ preview-format screen-format term-format unix
+ \ preview-format screen-format term-format unix daemon
syn match ShellFMColorKey /\<[atldsSALTR]-color\>/ contained
View
6 source/main.c
@@ -83,6 +83,10 @@ int main(int argc, char ** argv) {
if(haskey(& rc, "discovery"))
enable(DISCOVERY);
+ /* If "daemon" is set in the configuration, enable daemon mode by default. */
+ if(haskey(& rc, "daemon"))
+ background = !0;
+
/* Get proxy environment variable. */
if((proxy = getenv("http_proxy")) != NULL)
set(& rc, "proxy", proxy);
@@ -92,7 +96,7 @@ int main(int argc, char ** argv) {
while(-1 != (option = getopt(argc, argv, ":dbhi:p:D:y:")))
switch(option) {
case 'd': /* Daemonize. */
- background = !0;
+ background = !background;
break;
case 'i': /* IP to bind network interface to. */
Please sign in to comment.
Something went wrong with that request. Please try again.