forked from conda-forge/conda-forge.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
/
feedstock_outputs.html.tmpl
217 lines (190 loc) · 9.07 KB
/
feedstock_outputs.html.tmpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="">
<meta name="author" content="">
<link rel="shortcut icon" href="img/favicon.ico">
<title>conda-forge feedstocks | community driven packaging for conda</title>
<!-- Bootstrap Core CSS -->
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css" rel="stylesheet">
<!-- Custom CSS -->
<link href="https://conda-forge.org/css/octicons.3.4.1/octicons.css" rel="stylesheet">
<link href="https://conda-forge.org/css/theme.css" rel="stylesheet">
<!-- Custom Fonts -->
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css" rel="stylesheet" type="text/css">
<link href="http://fonts.googleapis.com/css?family=Montserrat:400,700" rel="stylesheet" type="text/css">
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
<script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
<![endif]-->
</head>
<body id="page-top" data-spy="scroll" data-target=".navbar-fixed-top">
<!-- Navigation -->
<nav class="navbar navbar-custom navbar-fixed-top" role="navigation">
<div class="container semi-black-alpha" role="navigation">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-main-collapse">
<i class="fa fa-bars"></i>
</button>
<a class="navbar-brand page-scroll" href="https://conda-forge.org/#page-top">
<i><img src="https://conda-forge.org/img/anvil_white.png" alt="An anvil" style="height: 1em;"></i> <span class="light">conda-forge</span>
</a>
</div>
<div class="collapse navbar-collapse navbar-main-collapse">
<ul class="nav navbar-nav">
<li>
<a class="page-scroll" href="https://conda-forge.org/#about">About</a>
</li>
<li>
<a href="https://conda-forge.org/docs">Docs</a>
</li>
<li>
<a href="https://conda-forge.org/blog">Blog</a>
</li>
<li>
<a class="page-scroll" href="https://conda-forge.org/#contribute">Contribute</a>
</li>
<li class="active">
<a href="https://conda-forge.org/feedstock-outputs">Packages</a>
</li>
<li>
<a href="https://conda-forge.org/docs/user/announcements.html#announcements">News</a>
</li>
<li>
<a href="https://conda-forge.org/status">Status</a>
</li>
<li>
<a href="https://conda-forge.org/docs/orga/getting-in-touch.html">Contact</a>
</li>
<li>
<a href="https://numfocus.salsalabs.org/donate-to-conda-forge/index.html">Donate!</a>
</li>
</ul>
<ul class="nav navbar-nav navbar-right">
<li>
<a href="https://github.com/conda-forge">
<i class="fa fa-github"></i>
</a>
</li>
</ul>
</div>
<!-- /.navbar-collapse -->
</div>
<!-- /.container -->
</nav>
<!-- About Section -->
<section id="feedstocks" class="container content-section">
<div class="row">
<div class="col-lg-8 col-lg-offset-2">
<h2 class="text-center">packages on conda-forge</h2>
</div>
</div>
<div class="row">
<div class="form-group col-lg-8 col-lg-offset-2 col btn-group" role='group'>
<input class='form-control' placeholder='Filter items'
style='display:none' id='searchfield' type='text'>
</div>
</div>
<div class="row">
<div class="col-lg-8 col-lg-offset-2">
<ul class="list-group">
{% for name, data in packages.items() %}
<li class="list-group-item">
<a href="https://anaconda.org/conda-forge/{{ name }}">
{{ name }}:
</a>
{% for fs in data['feedstocks'] %}
<a href="https://github.com/conda-forge/{{ fs }}-feedstock">
{{ fs }}-feedstock
</a>
{% endfor %}
</li>
{% endfor %}
</ul>
</div>
</div>
</section>
<!-- Footer -->
<footer>
<div class="container text-center">
<p>
<a href="https://conda-forge.org">Home</a> |
<a href="https://conda-forge.org/index.html#about">About</a> |
<!-- <a href="https://conda-forge.org/index.html#contribute">Contribute</a> |
<a href="https://conda-forge.org/feedstocks">Feedstocks</a> | -->
<a href="https://github.com/conda-forge">conda-forge on GitHub</a>
</p>
<br/>
<p class="small">
<a rel="license" href="http://creativecommons.org/licenses/by/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by/4.0/88x31.png" /></a><br /><a href="https://conda-forge.org">conda-forge.org</a> is licensed under a <br /> <a href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>.
</p>
</div>
</footer>
<!-- jQuery -->
<script src="https://code.jquery.com/jquery-1.11.3.min.js"></script>
<!-- Bootstrap Core JavaScript -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
<!-- Custom Theme JavaScript -->
<script src="https://conda-forge.org/js/theme.js"></script>
<script>
// Returns a function, that, as long as it continues to be invoked, will not
// be triggered. The function will be called after it stops being called for
// N milliseconds. If `immediate` is passed, trigger the function on the
// leading edge, instead of the trailing.
// see: https://github.com/jashkenas/underscore/blob/master/underscore.js
function debounce(func, wait, immediate) {
var timeout;
return function() {
var context = this, args = arguments;
var later = function() {
timeout = null;
if (!immediate) func.apply(context, args);
};
var callNow = immediate && !timeout;
clearTimeout(timeout);
timeout = setTimeout(later, wait);
if (callNow) func.apply(context, args);
};
};
var listGroup = $('.list-group');
var listGroupItems = $('.list-group-item');
var listGroupText = new Array(listGroupItems.length);
var listGroupHTML = new Array(listGroupItems.length);
var links = new Array(listGroupItems.length);
// collect each element of class list-group-item's innerText
// along with their href on initial page load
for(var i = 0; i < listGroupItems.length; i++) {
listGroupText[i] = listGroupItems[i].innerText;
listGroupHTML[i] = listGroupItems[i].innerHTML;
links[i] = listGroupItems[i].firstElementChild.href;
}
$('#searchfield').show().on('change keyup keypress paste', debounce(function() {
var searchterm = $('#searchfield').val().toLowerCase();
var terms = searchterm.split(' ');
var output = '';
var currentItem = '';
var matches = [];
for(var i = 0; i < listGroupItems.length; i++) {
currentItem = listGroupText[i];
// compare each searched term to the current feedstock item,
// return 0 if term is not in item else return 1
matches = terms.map(function(term) {
return currentItem.indexOf(term) == -1 ? 0 : 1;
})
// sum up the matches and check that it's equal to the number of search terms entered
// if equal, add to output html
if(matches.reduce(function(a,b) { return a + b; }, 0) == terms.length) {
// output += '<li class="list-group-item"><a href="' + links[i] + '">' + listGroupText[i] + '</a></li>';
output += '<li class="list-group-item">' + listGroupHTML[i] + '</li>';
}
}
listGroup.html(output);
}, 100));
</script>
</body>
</html>