welcome: please sign in

attachment:highlight_ext_gen.pl of HcoopVolunteerTasks

Attachment 'highlight_ext_gen.pl'

Download

   1 #!/usr/bin/perl
   2 
   3 use strict;
   4 use warnings;
   5 
   6 my @high_in = `highlight --list-scripts=langs`;
   7 my @gitweb_out;
   8 
   9 foreach(@high_in){
  10   my @l = split(/:\s([[:ascii:]]+?)( \( ([\s,[:ascii:]]*) \))*$/, $_);
  11 
  12   #Output in gitweb $ext_highlight format
  13   if($l[1]){
  14     print"(map { \$_ => \'$l[1]\' } qw($l[1]";
  15     if($l[3]) {
  16       print " $l[3]";
  17     }
  18     print")),\n";
  19   }
  20 }

Attached Files

To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.
  • [get | view] (2014-03-12 23:46:09, 1.7 KB) [[attachment:config-v1.1.xml]]
  • [get | view] (2014-04-02 06:56:56, 0.4 KB) [[attachment:highlight_ext_gen.pl]]
 All files | Selected Files: delete move to page copy to page

You are not allowed to attach a file to this page.