Skip to content

Commit 73d3c46

Browse files
committed
Fix bug in URL parsing - ignored '-'
1 parent 2db8776 commit 73d3c46

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

contentscript.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
// make root URL, i.e. up to & including CMSSW_X_Y_Z_AAA, or tag hash
55
// note, be careful as can have URLs in diff formats:
66
// github.com/cms-sw/cmssw/blob/CMSSW_7_2_X/DataFormats/JetReco/interface/GenJetCollection.h
7-
// with CMSSW_1_2_3, CMSSW_1_2_X, CMSSW_1_2_3_SHLC_fixTk, etc,
7+
// with CMSSW_1_2_3, CMSSW_1_2_X, CMSSW_1_2_3_SHLC_fixTk, l1t-devel-CMSSW_7_3_0_pre2, etc
88
// or
99
// github.com/cms-sw/cmssw/blob/975...a78/DataFormats/JetReco/interface/GenJetCollection.h
1010
var url = document.URL;
11-
var cmssw_pattern = /.*\/cmssw\/blob\/[_a-zA-Z0-9\.]*?\//;
11+
var cmssw_pattern = /.*\/cmssw\/blob\/[_a-zA-Z0-9\.\-]*?\//;
1212
var rootURL = "";
1313
cmssw = cmssw_pattern.exec(url)[0];
1414
rootURL = url.substr(0, url.search(cmssw_pattern)+cmssw.length);

manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "Github linkify for CMSSW",
33
"description": "Turns #include statments in C++ files, and import X/from X import Y/process.load(XXX.YYY.ZZZ_cff) in python config files, into links when browing CMSSW on Github.",
4-
"version": "0.2.6",
4+
"version": "0.2.7",
55
"content_scripts": [
66
{
77
"matches": [

0 commit comments

Comments
 (0)