patch-config.def.h - pkgsrc-localpatches - leot's pkgsrc LOCALPATCHES
 (HTM) hg clone https://bitbucket.org/iamleot/pkgsrc-localpatches
 (DIR) Log
 (DIR) Files
 (DIR) Refs
       ---
       patch-config.def.h
       ---
            1 $NetBSD$
            2 
            3 Add support for UserAgent and UserScript.
            4 
            5 --- config.def.h.orig
            6 +++ config.def.h
            7 @@ -3,6 +3,7 @@ static int surfuseragent    = 1;  /* Append Surf version to default WebKit user
            8  static char *fulluseragent  = ""; /* Or override the whole user agent string */
            9  static char *scriptfile     = "~/.surf/script.js";
           10  static char *styledir       = "~/.surf/styles/";
           11 +static char *scriptdir      = "~/.surf/script/";
           12  static char *certdir        = "~/.surf/certificates/";
           13  static char *cachedir       = "~/.surf/cache/";
           14  static char *cookiefile     = "~/.surf/cookies.txt";
           15 @@ -46,6 +47,8 @@ static Parameter defconfig[ParameterLast] = {
           16         [SpellLanguages]      =       { { .v = ((char *[]){ "en_US", NULL }) }, },
           17         [StrictTLS]           =       { { .i = 1 },     },
           18         [Style]               =       { { .i = 1 },     },
           19 +       [UserAgent]           =       { { .v = "" },    },
           20 +       [UserScript]          =       { { .i = 1 },     },
           21         [WebGL]               =       { { .i = 0 },     },
           22         [ZoomLevel]           =       { { .f = 1.0 },   },
           23  };
           24 @@ -112,6 +115,12 @@ static SiteSpecific styles[] = {
           25         { ".*",                 "default.css" },
           26  };
           27  
           28 +/* scripts */
           29 +static SiteSpecific scripts[] = {
           30 +       /* regexp               file in $scriptdir */
           31 +       { ".*",                 "default.js" },
           32 +};
           33 +
           34  /* certificates */
           35  /*
           36   * Provide custom certificate for urls