lynx/lynx-2.8.9-redhat.patch
caomeng5@huawei.com dcac4b1a0e init
2019-12-17 14:44:32 +08:00

635 lines
23 KiB
Diff

<!DOCTYPE html>
<html lang='en'>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<title>Tree - rpms/lynx - src.fedoraproject.org</title>
<link rel="shortcut icon" type="image/vnd.microsoft.icon"
href="/theme/static/favicon.ico?version=5.8.1"/>
<link href="/theme/static/fedora-bootstrap-1.3.0/fedora-bootstrap.min.css?version=5.8.1"
type="text/css" rel="stylesheet" />
<link href="/theme/static/fonts/fonts.css?version=5.8.1"
rel="stylesheet" type="text/css" />
<link href="/theme/static/fonts/hack_fonts/css/hack-extended.min.css?version=5.8.1"
type="text/css" rel="stylesheet" />
<link href="/theme/static/theme.css?version=5.8.1"
type="text/css" rel="stylesheet" />
<link type="text/css" rel="stylesheet" nonce="xHR90ZOqroWkioF40AQPZFHOM" href="/static/vendor/font-awesome/font-awesome.css?version=5.8.1"/>
<link type="text/css" rel="stylesheet" nonce="xHR90ZOqroWkioF40AQPZFHOM" href="/static/pagure.css?version=5.8.1"/>
<link nonce="xHR90ZOqroWkioF40AQPZFHOM" rel="stylesheet" href="/static/vendor/highlight.js/styles/github.css?version=5.8.1"/>
<link nonce="xHR90ZOqroWkioF40AQPZFHOM" rel="stylesheet" href="/static/vendor/highlightjs-line-numbers/highlightjs-line-numbers.min.css?version=5.8.1"/>
<style nonce="xHR90ZOqroWkioF40AQPZFHOM">
.hljs {
background: #fff;
}
</style>
</head>
<body id="home">
<!-- start masthead -->
<nav class="navbar navbar-light masthead p-0 navbar-expand">
<div class="container">
<a href="/" class="navbar-brand">
<img height=40px src="/theme/static/pagure-logo.png?version=5.8.1"
alt="pagure Logo" id="pagureLogo"/>
</a>
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="btn btn-primary" href="/login/?next=https://src.fedoraproject.org/rpms/lynx/blob/f29/f/lynx-2.8.9-redhat.patch">Log In</a>
</li>
</ul>
</div>
</nav>
<!-- close masthead-->
<div class="bodycontent">
<div class="bg-light border border-bottom pt-3">
<div class="container">
<div class="row mb-3">
<div class="col-6">
<div class="row">
<div class="col-auto pr-0">
<h3>
<i class="fa fa-archive text-muted"></i></h3>
</div>
<div class="col-auto pl-2">
<h3 class="mb-0">
<a href="/projects/rpms/%2A">rpms</a>&nbsp;/&nbsp;<a href="/rpms/lynx"><strong>lynx</strong></a>
</h3>
</div>
</div>
</div>
<div class="col-6 text-right">
<div class="btn-group">
<div class="btn-group">
<a href="#"
class="btn btn-sm dropdown-toggle btn-outline-primary"
data-toggle="dropdown" id="watch-button">
<i class="fa fa-clone fa-fw"></i>
<span>Clone</span>
</a>
<div class="dropdown-menu dropdown-menu-right">
<div class="m-3" id="source-dropdown" class="pointer">
<div>
<h5><strong>Source Code</strong></h5>
<div class="form-group">
<div class="input-group input-group-sm">
<div class="input-group-prepend"><span class="input-group-text">GIT</span></div>
<input class="form-control bg-white select-on-focus" type="text" value="https://src.fedoraproject.org/rpms/lynx.git" readonly>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<ul class="nav nav-tabs nav-small border-bottom-0">
<li class="nav-item mr-2 text-dark">
<a class="nav-link active" href="/rpms/lynx">
<i class="fa fa-code fa-fw text-muted"></i>
<span class="d-none d-md-inline">Source</span>
</a>
</li>
<li class="nav-item mr-2 text-dark">
<a class="nav-link" href="https://bugzilla.redhat.com/buglist.cgi?bug_status=NEW&bug_status=ASSIGNED&classification=Fedora&product=Fedora&component=lynx">
<i class="fa fa-fw text-muted fa-exclamation-circle"></i>
<span class="d-none d-md-inline">Issues&nbsp;</span>
<span class="fa fa-external-link"></span>
</a>
</li>
<li class="nav-item mr-2 text-dark">
<a class="nav-link" href="/rpms/lynx/pull-requests">
<i class="fa fa-fw text-muted fa-arrow-circle-down"></i>
<span class="d-none d-md-inline">Pull Requests&nbsp;</span>
<span class="badge badge-secondary py-0 d-none d-md-inline">
0
</span>
</a>
</li>
<li class="nav-item mr-2 text-dark">
<a class="nav-link" href="/rpms/lynx/stats">
<i class="fa fa-line-chart fa-fw text-muted"></i>
<span class="d-none d-md-inline">Stats</span>
</a>
</li>
</ul>
</div>
</div>
<div class="container pt-5 repo-body-container">
<div class="row">
<div class="col-2">
<nav class="nav nav-tabs nav-sidetabs flex-column">
<a class=
"nav-link nowrap
"
href="/rpms/lynx">
<i class="fa fa-home text-muted fa-fw"></i>&nbsp;<span class="d-none d-md-inline">Overview</span>
</a>
<a class=
"nav-link nowrap
active"
href="/rpms/lynx/tree/f29">
<i class="fa fa-file-code-o text-muted fa-fw"></i>&nbsp;Files
</a>
<a class=
"nav-link nowrap
"
href="/rpms/lynx/commits/f29">
<i class="fa fa-list-alt text-muted fa-fw" data-glyph="spreadsheet"></i>&nbsp;Commits
</a>
<a class=
"nav-link nowrap
"
href="/rpms/lynx/branches?branchname=f29">
<i class="fa fa-random text-muted fa-fw"></i>&nbsp;Branches
</a>
<a class=
"nav-link nowrap
"
href="/rpms/lynx/forks">
<i class="fa fa-code-fork text-muted fa-fw"></i>&nbsp;Forks
</a>
<a class=
"nav-link nowrap
"
href="/rpms/lynx/releases">
<i class="fa fa-tags text-muted fa-fw"></i>&nbsp;Releases
</a>
<div class="col-xs-2 line-height-1"></div>
<p>Monitoring status:</p>
<div class="btn-group">
<button title="Monitoring status" class="btn btn-sm btn-outline-primary disabled"
id="monitoring-button">
<i id="monitoring-icon" class="fa fa-fw fa-eye"></i>
<span id="monitoring-label" class="fa fa-circle-o-notch fa-spin fa-1x fa-fw"></span>
</button>
</div>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM">
window.addEventListener('load', function() {
set_up_monitoring = function(status){
var _label = "Disabled"
if (status === "monitoring") {
_label = "Monitoring";
$("#monitoring-icon").attr("class", "fa fa-fw fa-eye")
} else if (status === "monitoring-with-scratch") {
_label = "Scratch builds"
$("#monitoring-icon").attr("class", "fa fa-fw fa-eye")
} else {
$("#monitoring-icon").attr("class", "fa fa-fw fa-eye-slash")
}
$("#monitoring-label").text(_label);
$("#monitoring-label").removeClass("fa fa-circle-o-notch fa-spin fa-1x fa-fw");
}
$.ajax({
url: "/_dg/anitya/rpms/lynx",
type: 'GET',
dataType: 'json',
success: function(res) {
console.log(res);
set_up_monitoring(res.monitoring)
}
});
});
</script>
</nav> </div>
<div class="col-10">
<div class="row mb-1">
<div class="col-sm-6">
<h3>
Files
</h3>
</div>
<div class="col-sm-6">
<div class="float-right">
<div class="btn-group">
<a href="#" class="btn btn-outline-light border-secondary text-dark btn-sm dropdown-toggle"
data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
<span class="fa fa-random fa-fw"></span> Branch: <span class="font-weight-bold">f29</span>
</a>
<div class="dropdown-menu dropdown-menu-right">
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f10">
<span class="fa fa-random fa-fw"></span> <span class="">f10</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f11">
<span class="fa fa-random fa-fw"></span> <span class="">f11</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f12">
<span class="fa fa-random fa-fw"></span> <span class="">f12</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f13">
<span class="fa fa-random fa-fw"></span> <span class="">f13</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f14">
<span class="fa fa-random fa-fw"></span> <span class="">f14</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f15">
<span class="fa fa-random fa-fw"></span> <span class="">f15</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f16">
<span class="fa fa-random fa-fw"></span> <span class="">f16</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f17">
<span class="fa fa-random fa-fw"></span> <span class="">f17</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f18">
<span class="fa fa-random fa-fw"></span> <span class="">f18</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f19">
<span class="fa fa-random fa-fw"></span> <span class="">f19</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f20">
<span class="fa fa-random fa-fw"></span> <span class="">f20</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f21">
<span class="fa fa-random fa-fw"></span> <span class="">f21</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f22">
<span class="fa fa-random fa-fw"></span> <span class="">f22</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f23">
<span class="fa fa-random fa-fw"></span> <span class="">f23</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f24">
<span class="fa fa-random fa-fw"></span> <span class="">f24</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f25">
<span class="fa fa-random fa-fw"></span> <span class="">f25</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f26">
<span class="fa fa-random fa-fw"></span> <span class="">f26</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f27">
<span class="fa fa-random fa-fw"></span> <span class="">f27</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f28">
<span class="fa fa-random fa-fw"></span> <span class="">f28</span>
</a>
<a class="dropdown-item pl-1 active" href="/rpms/lynx/tree/f29">
<span class="fa fa-random fa-fw"></span> <span class="font-weight-bold">f29</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f30">
<span class="fa fa-random fa-fw"></span> <span class="">f30</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f31">
<span class="fa fa-random fa-fw"></span> <span class="">f31</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f7">
<span class="fa fa-random fa-fw"></span> <span class="">f7</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f8">
<span class="fa fa-random fa-fw"></span> <span class="">f8</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/f9">
<span class="fa fa-random fa-fw"></span> <span class="">f9</span>
</a>
<a class="dropdown-item pl-1 " href="/rpms/lynx/tree/master">
<span class="fa fa-random fa-fw"></span> <span class="">master</span>
</a>
</div>
</div>
</div>
</div>
</div>
<div class="card mb-3">
<div class="card-header">
<ol class="breadcrumb p-0 bg-transparent mb-0">
<li class="breadcrumb-item">
<a href="/rpms/lynx/tree/f29">
<span class="fa fa-random">
</span>&nbsp; f29
</a>
</li>
<li class="active breadcrumb-item">
<span class="fa fa-file" data-glyph="">
</span>&nbsp; lynx-2.8.9-redhat.patch
</li>
</ol>
</div>
<div class="card-body p-0">
<div class="bg-light border text-right pr-2">
<form class="btn btn-sm" method="POST" name="fork_project"
action="/fork_edit/rpms/lynx/edit/f29/f/lynx-2.8.9-redhat.patch">
<button class="btn btn-sm btn-secondary fork_project_btn">
Fork and Edit
</button>
</form>
<a class="btn btn-secondary btn-sm" href="/rpms/lynx/blob/f29/f/lynx-2.8.9-redhat.patch" title="View as blob">Blob</a>
<a class="btn btn-secondary btn-sm" href="/rpms/lynx/blame/lynx-2.8.9-redhat.patch?identifier=f29" title="View git blame">Blame</a>
<a class="btn btn-secondary btn-sm" href="/rpms/lynx/raw/f29/f/lynx-2.8.9-redhat.patch" title="View as raw">Raw</a>
</div>
<pre class="syntaxhighlightblock"><code class="lang-diff">From bccfb8ac43da56cb1f53c4b421e09dcac1fd1af0 Mon Sep 17 00:00:00 2001
From: Kamil Dudka &lt;kdudka@redhat.com&gt;
Date: Wed, 13 Feb 2013 15:17:08 +0100
Subject: [PATCH] lynx-2.8.6-redhat.patch rebased for 2.8.9
---
lynx.cfg | 18 ++++++++++++------
userdefs.h | 18 +++++++++---------
2 files changed, 21 insertions(+), 15 deletions(-)
diff --git a/lynx.cfg b/lynx.cfg
index f01782f..ccc0846 100644
--- a/lynx.cfg
+++ b/lynx.cfg
@@ -1,7 +1,9 @@
# $LynxId: lynx.cfg,v 1.302 2018/07/08 15:22:44 tom Exp $
# lynx.cfg file.
-# The default placement for this file is /usr/local/lib/lynx.cfg (Unix)
-# or Lynx_Dir:lynx.cfg (VMS)
+# The default placement for this file is /etc/lynx.cfg
+#
+# Please don&#39;t edit this file directly (it is updated with every Red Hat
+# Linux update, overwriting your changes). Instead, edit /etc/lynx-site.cfg.
#
# $Format: &#34;#PRCS LYNX_VERSION \&#34;$ProjectVersion$\&#34;&#34;$
#PRCS LYNX_VERSION &#34;2.8.9rel.1&#34;
@@ -108,7 +110,7 @@
#
# Normally we expect you will connect to a remote site, e.g., the Lynx starting
# site:
-STARTFILE:https://lynx.invisible-island.net/
+STARTFILE:https://start.fedoraproject.org/
#
# As an alternative, you may want to use a local URL. A good choice for this is
# the user&#39;s home directory:
@@ -142,7 +144,7 @@ HELPFILE:https://lynx.invisible-island.net/lynx_help/lynx_help_main.html
# An index to your CWIS can be placed here or a document containing
# pointers to lots of interesting places on the web.
#
-DEFAULT_INDEX_FILE:http://scout.wisc.edu/
+DEFAULT_INDEX_FILE:http://www.google.com/
.h1 Interaction
@@ -454,7 +456,7 @@ DEFAULT_INDEX_FILE:http://scout.wisc.edu/
# Find RFC 1345 at
.url http://tools.ietf.org/html/rfc1345
#
-#CHARACTER_SET:iso-8859-1
+CHARACTER_SET:utf-8
.h2 LOCALE_CHARSET
# LOCALE_CHARSET overrides CHARACTER_SET if true, using the current locale to
@@ -467,7 +469,7 @@ DEFAULT_INDEX_FILE:http://scout.wisc.edu/
# values and their relationship to the locale value is not. GNU libiconv
# happens to give useful values, but other implementations are not guaranteed
# to do this.
-#LOCALE_CHARSET:FALSE
+LOCALE_CHARSET:TRUE
.h2 HTML5_CHARSETS
# HTML5_CHARSETS is an alternative to ASSUME_CHARSET and ASSUME_LOCAL_CHARSET.
@@ -1847,6 +1849,9 @@ DEFAULT_INDEX_FILE:http://scout.wisc.edu/
.ex
#DOWNLOADER:Save OS/390 binary file: iconv -f IBM-1047 -t ISO8859-1 %s &gt;%s:FALSE
+# Added by Red Hat:
+DOWNLOADER:View with less:less %s:TRUE
+
.h1 Interaction
.h2 NO_DOT_FILES
@@ -3451,6 +3456,7 @@ COLOR:6:brightred:black
#ENABLE_LYNXRC:VI_KEYS:ON
#ENABLE_LYNXRC:VISITED_LINKS:ON
.fi
+INCLUDE:/etc/lynx-site.cfg
.h1 External Programs
# Any of the compiled-in pathnames of external programs can be overridden
diff --git a/userdefs.h b/userdefs.h
index 40a954b..4afe835 100644
--- a/userdefs.h
+++ b/userdefs.h
@@ -105,7 +105,7 @@
* mailcap files (see the examples in the samples directory).
*/
#ifndef LYNX_CFG_FILE
-#define LYNX_CFG_FILE &#34;Lynx_Dir:lynx.cfg&#34;
+#define LYNX_CFG_FILE &#34;/etc/lynx.cfg&#34;
#endif /* LYNX_CFG_FILE */
#ifndef LYNX_CFG_PATH
@@ -119,8 +119,8 @@
* Mappings in these global and personal files override any SUFFIX
* definitions in lynx.cfg and built-in defaults from src/HTInit.c.
*/
-#define GLOBAL_EXTENSION_MAP &#34;Lynx_Dir:mime.types&#34;
-#define PERSONAL_EXTENSION_MAP &#34;mime.types&#34;
+#define GLOBAL_EXTENSION_MAP &#34;/etc/mime.types&#34;
+#define PERSONAL_EXTENSION_MAP &#34;.mime.types&#34;
/**************************
* The MAILCAP file allows you to map file MIME types to
@@ -129,7 +129,7 @@
* Mappings in these global and personal files override any VIEWER
* definitions in lynx.cfg and built-in defaults from src/HTInit.c.
*/
-#define GLOBAL_MAILCAP &#34;Lynx_Dir:mailcap&#34;
+#define GLOBAL_MAILCAP &#34;/etc/mailcap&#34;
#define PERSONAL_MAILCAP &#34;.mailcap&#34;
/**************************
@@ -300,8 +300,8 @@
#define LYNX_CFG_PATH &#34;.&#34;
#define LYNX_CFG_FILE &#34;./lynx.cfg&#34;
#else
-#define LYNX_CFG_PATH &#34;/usr/local/lib&#34;
-#define LYNX_CFG_FILE &#34;/usr/local/lib/lynx.cfg&#34;
+#define LYNX_CFG_PATH &#34;/etc&#34;
+#define LYNX_CFG_FILE &#34;/etc/lynx.cfg&#34;
#endif /* DOSPATH */
#endif /* LYNX_CFG_FILE */
#endif /* HAVE_CONFIG_H */
@@ -345,7 +345,7 @@
* use any default viewers for image types. Note that open is used as
* the default for NeXT, instead of the XLOADIMAGE_COMMAND definition.
*/
-#define XLOADIMAGE_COMMAND &#34;xli %s &amp;&#34;
+#define XLOADIMAGE_COMMAND &#34;display %s &amp;&#34;
/**************************
* For UNIX systems, SYSTEM_MAIL and SYSTEM_MAIL_FLAGS are set by the
@@ -366,7 +366,7 @@
* the &#34;TMPDIR&#34; (unix), or &#34;TEMP&#34; or &#34;TMP&#34; (Windows,DOS,OS/2)
* variable.
*/
-#define TEMP_SPACE &#34;/tmp/&#34;
+#define TEMP_SPACE &#34;~&#34;
/********************************
* Comment this line out to disable code that implements command logging
@@ -1175,7 +1175,7 @@
* OSU server distribution.
*/
#ifndef HAVE_CONFIG_H
-/* #define LYNXCGI_LINKS */
+#define LYNXCGI_LINKS
#endif
/*********************************
--
2.9.4
</code></pre>
</div>
</div> <!-- end .card-->
</div>
</div>
</div>
</div>
<div class="footer pt-4 text-white">
<div class="container">
<div class="d-flex align-items-center">
<div>
<div>Powered by <a href="https://pagure.io/pagure" class="notblue">Pagure</a> 5.8.1</div>
<div>
<a href="https://docs.pagure.org/pagure/usage/index.html" class="notblue">Documentation</a> &bull;
<a href="https://pagure.io/pagure/new_issue" class="notblue">File an Issue</a> &bull;
<a href="/about">About this Instance</a> &bull;
<a href="/ssh_info" class="notblue">SSH Hostkey/Fingerprint</a>
</div>
</div>
<div class="ml-auto text-right">
<div>&copy; 2014-2019 Red Hat, Inc. and others.</div>
</div>
</div>
</div>
</div>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM" src="/static/vendor/jquery/jquery.min.js?version=5.8.1"></script>
<script src="/static/vendor/bootstrap/bootstrap.bundle.min.js?version=5.8.1"></script>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM">
$('[data-toggle="tooltip"]').tooltip({placement : 'bottom'});
$(".cancel_btn").click(function() {
history.back();
});
</script>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM" src="/static/vendor/lazyload/lazyload.min.js?version=5.8.1"></script>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM">
window.addEventListener("load", function(event) {
lazyload();
});
</script>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM">
$("#giturl-toggle").on('click', function(event){
event.stopPropagation();
$("#giturl-more").toggle();
$("#giturl-toggle").hide();
})
$(".fork_project_btn").click(function() {
$('#fork_project').submit();
});
$(".select-on-focus").on("focus", function() {
$(this).select();
});
</script>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM" src="/static/vendor/highlight.js/highlight.pack.js?version=5.8.1"></script>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM" src="/static/vendor/highlightjs-line-numbers/highlightjs-line-numbers.min.js?version=5.8.1"></script>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM" src="/static/vendor/highlight.js/spec.js?version=5.8.1"></script>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM">
$(document).ready(function() {
$('.fork_project_btn').click($("[name=fork_project]").submit);
$('pre.syntaxhighlightblock code').each(function(i, block) {
hljs.highlightBlock(block);
hljs.lineNumbersBlock(block);
});
var cls = "highlighted-line";
var lines = location.hash.substr(2).split('-').map(function (x) { return parseInt(x, 10) });
if (! isNaN(lines[0]))
{
for (var i = lines[lines.length - 1]; i >= lines[0]; i--) {
$('#_' + i).parent().parent().addClass(cls);
}
setTimeout(function(){
$("#_" + lines[0]).get(0).scrollIntoView({behavior: "instant", block: "start", inline: "nearest"});
}, 50);
}
});
</script>
<script type="text/javascript" nonce="xHR90ZOqroWkioF40AQPZFHOM">
function updateHighlight() {
var cls = "highlighted-line";
$('.' + cls).removeClass(cls)
if (location.hash !== '') {
var lines = location.hash.substr(2).split('-').map(function (x) { return parseInt(x, 10) });
for (var i = lines[lines.length - 1]; i >= lines[0]; i--) {
$('[data-line-number=' + i + ']').closest('tr').addClass(cls);
}
return lines;
}
return [];
}
$(window).on('hashchange', updateHighlight);
var selected = [];
$("[data-line-number]").click(function (ev) {
var line = $(this).attr('data-line-number');
if (ev.shiftKey) {
selected = selected.slice(-1).concat(line);
} else {
selected = [line];
}
var hash = '_' + selected[0];
if (selected.length === 2) {
hash = '_' + Math.min(selected[0], selected[1]) + '-' + Math.max(selected[0], selected[1]);
}
window.location.hash = hash;
return false;
});
</script>
</body>
</html>