From 1cfcdac7958878dc7e3823a2185cdfeb648e3818 Mon Sep 17 00:00:00 2001 From: hellekin Date: Fri, 22 Jan 2021 16:12:13 +0100 Subject: WIP: display version --- app/lib/incommon.rb | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/app/lib/incommon.rb b/app/lib/incommon.rb index e03b0e9..78ba894 100644 --- a/app/lib/incommon.rb +++ b/app/lib/incommon.rb @@ -6,12 +6,10 @@ module INCOMMON module_function def repo_url(version) case version - when /^HEAD/ - query="h=#{version}" - when /^incommon-map @(.*)/ - query="h=HEAD&id=#{$1}" - when /^incommon-map (v.*)/ - query="h=#{$1}" + when /^incommon-map (.*)@(.*)/ + query="h=#{$1}&id=#{$2}" + else + query="h=HEAD" end URI.parse("https://code.cepheide.org/incommon-map.git/tree/?#{query}").to_s end -- cgit v1.2.3