Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
e330e0c5
Commit
e330e0c5
authored
Jan 25, 2012
by
Matt Selsky
Committed by
Tiago Mello
Jan 25, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug 617802: Add see also support for Rietveld installations on appspot.com
r=timello, a=LpSolit
parent
15f7b4a8
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
47 additions
and
0 deletions
+47
-0
BugUrl.pm
Bugzilla/BugUrl.pm
+1
-0
Rietveld.pm
Bugzilla/BugUrl/Rietveld.pm
+45
-0
user-error.html.tmpl
template/en/default/global/user-error.html.tmpl
+1
-0
No files found.
Bugzilla/BugUrl.pm
View file @
e330e0c5
...
@@ -57,6 +57,7 @@ use constant SUB_CLASSES => qw(
...
@@ -57,6 +57,7 @@ use constant SUB_CLASSES => qw(
Bugzilla::BugUrl::MantisBT
Bugzilla::BugUrl::MantisBT
Bugzilla::BugUrl::SourceForge
Bugzilla::BugUrl::SourceForge
Bugzilla::BugUrl::ReviewBoard
Bugzilla::BugUrl::ReviewBoard
Bugzilla::BugUrl::Rietveld
)
;
)
;
###############################
###############################
...
...
Bugzilla/BugUrl/Rietveld.pm
0 → 100644
View file @
e330e0c5
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
# This Source Code Form is "Incompatible With Secondary Licenses", as
# defined by the Mozilla Public License, v. 2.0.
package
Bugzilla::BugUrl::
Rietveld
;
use
strict
;
use
base
qw(Bugzilla::BugUrl)
;
###############################
#### Methods ####
###############################
sub
should_handle
{
my
(
$class
,
$uri
)
=
@_
;
return
(
$uri
->
authority
=~
/\.appspot\.com$/i
and
$uri
->
path
=~
m
#^/\d+(?:/|/show)?$#) ? 1 : 0;
}
sub
_check_value
{
my
(
$class
,
$uri
)
=
@_
;
$uri
=
$class
->
SUPER::
_check_value
(
$uri
);
# Rietveld URLs have three forms:
# http(s)://example.appspot.com/1234
# http(s)://example.appspot.com/1234/
# http(s)://example.appspot.com/1234/show
if
(
$uri
->
path
=~
m
#^/(\d+)(?:/|/show)$#) {
# This is the shortest standard URL form for Rietveld issues,
# and so we reduce all URLs to this.
$uri
->
path
(
'/'
.
$1
);
}
# Make sure there are no query parameters.
$uri
->
query
(
undef
);
# And remove any # part if there is one.
$uri
->
fragment
(
undef
);
return
$uri
;
}
1
;
template/en/default/global/user-error.html.tmpl
View file @
e330e0c5
...
@@ -255,6 +255,7 @@
...
@@ -255,6 +255,7 @@
<li>A b[% %]ug in a MantisBT installation.</li>
<li>A b[% %]ug in a MantisBT installation.</li>
<li>A b[% %]ug on sourceforge.net.</li>
<li>A b[% %]ug on sourceforge.net.</li>
<li>A Review Board review request.</li>
<li>A Review Board review request.</li>
<li>An issue in a Rietveld installation.</li>
</ul>
</ul>
[% ELSIF reason == 'id' %]
[% ELSIF reason == 'id' %]
There is no valid [% terms.bug %] id in that URL.
There is no valid [% terms.bug %] id in that URL.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment