chiark / gitweb /
yarrg: with --find-window-only, print ocean and pirate parseably to stdout
authorIan Jackson <ian@liberator.relativity.greenend.org.uk>
Sat, 12 Dec 2009 13:10:43 +0000 (13:10 +0000)
committerIan Jackson <ian@liberator.relativity.greenend.org.uk>
Sat, 12 Dec 2009 13:15:25 +0000 (13:15 +0000)
yarrg/convert.c
yarrg/convert.h

index b7925b8..28729ae 100644 (file)
@@ -374,6 +374,9 @@ int main(int argc, char **argv) {
   default:                                     abort();
   }
 
+  if (o_mode & mf_printoceanpirate)
+    printf("%s %s\n",ocean,pirate);
+
   if (o_mode & mf_screenshot) {
     open_screenshot_file(1);
     if (o_flags & ff_singlepage) take_one_screenshot();
index a9e6a68..8930087 100644 (file)
@@ -136,16 +136,17 @@ enum flags {
 extern enum flags o_flags;
 
 enum mode {
-  mf_findwindow=      00001,
-  mf_screenshot=      00010,
-  mf_readscreenshot=  00020,
-  mf_analyse=         00100,
-  mfm_special=        07000,
+  mf_findwindow=        00001,
+  mf_screenshot=        00010,
+  mf_readscreenshot=    00020,
+  mf_analyse=           00100,
+  mf_printoceanpirate=  00200,
+  mfm_special=          07000,
   
-  mode_findwindow=    00001,
-  mode_screenshot=    00011,
-  mode_analyse=       00120,
-  mode_showcharset=   01000,
+  mode_findwindow=      00201,
+  mode_screenshot=      00011,
+  mode_analyse=         00120,
+  mode_showcharset=     01000,
 
   mode_all=           00111,
 };