diff options
author | Bert <ber.t@gmx.com> | 2011-09-03 15:58:58 +0200 |
---|---|---|
committer | Bert <ber.t@gmx.com> | 2011-09-03 15:58:58 +0200 |
commit | 9fa0bbca17f6346f10cffb618d2905dd3711c291 (patch) | |
tree | ab8958971a5b0b121b0ae3449b05d3d2de898a39 /config.h | |
parent | de6b58a3156e64963f5bf48fa446bfbf3bb9da3f (diff) |
Simplified it_shell_cmd() using SXIV_IMG env-variable
Diffstat (limited to 'config.h')
-rw-r--r-- | config.h | 14 |
1 files changed, 9 insertions, 5 deletions
@@ -110,11 +110,15 @@ static const keymap_t keys[] = { /* open current image with given program: */ { True, XK_g, it_open_with, (arg_t) "gimp" }, - /* run shell command line on current file ('#' is replaced by file path: */ - { True, XK_less, it_shell_cmd, (arg_t) "mogrify -rotate -90 #" }, - { True, XK_greater, it_shell_cmd, (arg_t) "mogrify -rotate +90 #" }, - { True, XK_comma, it_shell_cmd, (arg_t) "jpegtran -rotate 270 -copy all -outfile # #" }, - { True, XK_period, it_shell_cmd, (arg_t) "jpegtran -rotate 90 -copy all -outfile # #" }, + /* run shell command line on current file ("$SXIV_IMG"): */ + { True, XK_less, it_shell_cmd, (arg_t) \ + "mogrify -rotate -90 \"$SXIV_IMG\"" }, + { True, XK_greater, it_shell_cmd, (arg_t) \ + "mogrify -rotate +90 \"$SXIV_IMG\"" }, + { True, XK_comma, it_shell_cmd, (arg_t) \ + "jpegtran -rotate 270 -copy all -outfile \"$SXIV_IMG\" \"$SXIV_IMG\"" }, + { True, XK_period, it_shell_cmd, (arg_t) \ + "jpegtran -rotate 90 -copy all -outfile \"$SXIV_IMG\" \"$SXIV_IMG\"" }, }; /* mouse button mappings for image mode: */ |