Browse Source

Add templates for Aruba reporting

master
Susan Potter 10 years ago
parent
commit
8db2f40b45
  1. 14
      templates/files.erb
  2. 79
      templates/index.erb
  3. 88
      templates/main.erb

14
templates/files.erb

@ -0,0 +1,14 @@
<% if children(file).any? %>
<ul>
<% children(file).each do |child|
css_class = File.directory?(child) ? 'folder' : File.extname(child) == '' ? 'file unknown' : 'file ' + File.extname(child)[1..-1]
-%>
<li class="<%= css_class %>"><span class="filename"><%= File.basename(child) -%></span>
<% if File.file?(child) %>
<%= child %>
<% end %>
<% again(erb, _erbout, child) -%>
</li>
<% end -%>
</ul>
<% end -%>

79
templates/index.erb

@ -0,0 +1,79 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title><%= index_title %></title>
<meta name="description" content="">
<meta name="author" content="Susan Potter">
<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<!-- Le styles -->
<link href="//twitter.github.com/bootstrap/assets/css/bootstrap.css" rel="stylesheet">
<link href="//twitter.github.com/bootstrap/assets/css/bootstrap-responsive.css" rel="stylesheet">
<style>
body {
padding-top: 60px; /* 60px to make the container go all the way to the bottom of the topbar */
}
</style>
</head>
<body>
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
<span class="i-bar"></span>
<span class="i-bar"></span>
<span class="i-bar"></span>
</a>
<a class="brand" href="/">Cabal/GHC Buildpack</a>
<div class="nav-collapse">
<ul class="nav">
<li class="active"><a href="#">Home</a></li>
<li><a href="/maven">Maven</a></li>
<li><a href="/gems">RubyGems</a></li>
<li><a href="/vagrant">Vagrant Boxes</a></li>
<li><a href="/continuum">Continuum</a></li>
</ul>
</div><!--/.nav-collapse -->
</div>
</div>
</div>
<div class="container">
<h1><%= index_title %></h1>
<% Aruba::Reporting.reports.keys.sort{|f1, f2| f1.title <=> f2.title}.each do |feature| -%>
<h3><%= feature.title %></h3>
<ul>
<% Aruba::Reporting.reports[feature].each do |scenario, report_path| %>
<li><a href="<%= report_path%>"><%= scenario.title %></a></li>
<% end -%>
</ul>
<% end -%>
</div> <!-- /container -->
<!-- Le javascript
================================================== -->
<!-- Placed at the end of the document so the pages load faster -->
<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/tests/vendor/jquery.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-transition.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-alert.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-modal.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-dropdown.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-scrollspy.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-tab.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-tooltip.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-popover.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-button.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-collapse.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-carousel.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-typeahead.js"></script>
</body>
</html>

88
templates/main.erb

@ -0,0 +1,88 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title><%= index_title %></title>
<meta name="description" content="">
<meta name="author" content="Susan Potter">
<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<!-- Le styles -->
<link href="//twitter.github.com/bootstrap/assets/css/bootstrap.css" rel="stylesheet">
<link href="//twitter.github.com/bootstrap/assets/css/bootstrap-responsive.css" rel="stylesheet">
<style>
body {
padding-top: 60px; /* 60px to make the container go all the way to the bottom of the topbar */
}
</style>
</head>
<body>
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
<span class="i-bar"></span>
<span class="i-bar"></span>
<span class="i-bar"></span>
</a>
<a class="brand" href="/">Cabal/GHC Buildpack</a>
<div class="nav-collapse">
<ul class="nav">
<li class="active"><a href="#">Home</a></li>
<li><a href="/maven">Maven</a></li>
<li><a href="/gems">RubyGems</a></li>
<li><a href="/vagrant">Vagrant Boxes</a></li>
<li><a href="/continuum">Continuum</a></li>
</ul>
</div><!--/.nav-collapse -->
</div>
</div>
</div>
<div class="container">
<h2><%= title %></h2>
<div class="description">
<%= description %>
</div>
<h3>Files</h3>
<div class="filesystem">
<%= files %>
</div>
<h3>Output</h3>
<pre class="console">
<% commands.each do |cmd| -%>
$ <%= cmd %>
<% end -%>
<%= output %>
</pre>
</div> <!-- /container -->
<!-- Le javascript
================================================== -->
<!-- Placed at the end of the document so the pages load faster -->
<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/tests/vendor/jquery.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-transition.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-alert.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-modal.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-dropdown.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-scrollspy.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-tab.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-tooltip.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-popover.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-button.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-collapse.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-carousel.js"></script>
<script src="//twitter.github.com/bootstrap/assets/js/bootstrap-typeahead.js"></script>
</body>
</html>
Loading…
Cancel
Save