Subversion Repositories DevTools

Rev

Rev 133 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 133 Rev 145
Line 76... Line 76...
76
   // Other general validations
76
   // Other general validations
77
   var cleanStrRE = /^[0-9a-z_\.\(\)\-]+$/i;
77
   var cleanStrRE = /^[0-9a-z_\.\(\)\-]+$/i;
78
   var pkgRE = /^[a-z][a-z0-9_-]*[a-z0-9]$/i;
78
   var pkgRE = /^[a-z][a-z0-9_-]*[a-z0-9]$/i;
79
   var versionRE = /^[0-9a-z_\.\(\)\-]+$/i;
79
   var versionRE = /^[0-9a-z_\.\(\)\-]+$/i;
80
   var versionNumberRE = /^\d+\.\d+\.\d+$/;
80
   var versionNumberRE = /^\d+\.\d+\.\d+$/;
-
 
81
   var re_patch_ver_format = /^\d+\.\d+\.\d+\.p\d+\.[a-zA-Z0-9]+$/;
81
   var urlRE = "^https?://[a-z1-9]";
82
   var urlRE = "^https?://[a-z1-9]";
82
   //character range disallowed
83
   //character range disallowed
83
   var HTMLchr = /[\<\>\'\"]+/i;
84
   var HTMLchr = /[\<\>\'\"]+/i;
84
 
85
 
85
 
86
 
Line 128... Line 129...
128
            if (test.indexOf('isVersionStr')!=-1) {
129
            if (test.indexOf('isVersionStr')!=-1) {
129
               REresults = val.search(versionRE);
130
               REresults = val.search(versionRE);
130
               if (REresults < 0) errors += val += '- '+nm+' uses invalid character. Allowed characters are A-Z a-z 0-9 . - _\n';
131
               if (REresults < 0) errors += val += '- '+nm+' uses invalid character. Allowed characters are A-Z a-z 0-9 . - _\n';
131
            }
132
            }
132
 
133
 
-
 
134
            if (test.indexOf('isPatchVersionStr')!=-1) {
-
 
135
               if ( !re_patch_ver_format.test(val) ) {
-
 
136
                  errors += val += '- '+nm+' is not of form (integer).(integer).(integer).p(integer).(extension)\n';
-
 
137
               }
-
 
138
            }
-
 
139
 
133
            if (test.indexOf('isCCPath')!=-1) {
140
            if (test.indexOf('isCCPath')!=-1) {
134
               var CCPathRE = /^\\|\/[a-z]+[0-9a-z_\.\-\\\/ ]+$/i;
141
               var CCPathRE = /^\\|\/[a-z]+[0-9a-z_\.\-\\\/ ]+$/i;
135
 
142
 
136
               REresults = val.search(CCPathRE);
143
               REresults = val.search(CCPathRE);
137
               if (REresults < 0) errors += val += '- '+nm+' uses invalid character.\nAllowed characters are \\ / A-Z a-z 0-9 . - _ SPACE\nAnd the path must begin with \\ or /';
144
               if (REresults < 0) errors += val += '- '+nm+' uses invalid character.\nAllowed characters are \\ / A-Z a-z 0-9 . - _ SPACE\nAnd the path must begin with \\ or /';