Commit d7140239 authored by Jonathon Duerig's avatar Jonathon Duerig

Clean up apt structure. Pull libraries together into a coherent tree. Remove unused cruft.

parent 12f63f7f
......@@ -148,19 +148,15 @@ BLOBFILES += $(wildcard blob/*.php3)
APTUIFILES = $(wildcard $(SRCDIR)/aptui/*.php)
APTUIFILES += $(wildcard $(SRCDIR)/aptui/*.ajax)
APTUIFILES += $(wildcard $(SRCDIR)/aptui/*.css)
APTUIFILES += $(wildcard $(SRCDIR)/aptui/*.png)
APTUIFILES += $(wildcard $(SRCDIR)/aptui/*.gif)
APTUIFILES += $(wildcard $(SRCDIR)/aptui/.htaccess)
APTJSFILES = $(wildcard $(SRCDIR)/aptui/js/*.js)
APTLIBFILES = $(wildcard $(SRCDIR)/aptui/js/lib/*.js)
APTTEMPLATES = $(wildcard $(SRCDIR)/aptui/template/*.html)
UIKITFILES = $(wildcard $(SRCDIR)/aptui/uikit/fonts/*)
BOOTSTFONTS = $(wildcard $(SRCDIR)/aptui/bootstrap/fonts/*)
BOOTSTCSS = $(wildcard $(SRCDIR)/aptui/bootstrap/css/*)
BOOTSTJS = $(wildcard $(SRCDIR)/aptui/bootstrap/js/*)
HELPERSCSS = $(wildcard $(SRCDIR)/aptui/formhelpers/css/*)
HELPERSJS = $(wildcard $(SRCDIR)/aptui/formhelpers/js/*)
APTCSSFILES = $(wildcard $(SRCDIR)/aptui/css/*.css)
APTFONTS = $(wildcard $(SRCDIR)/aptui/fonts/*)
APTIMAGES = $(wildcard $(SRCDIR)/aptui/images/*)
# need to make it *.gz; with simply "*",
# we end up sucking over "CVS"
......@@ -222,12 +218,9 @@ ALLAPTUI = $(notdir $(APTUIFILES))
ALLAPTJS = $(notdir $(APTJSFILES))
ALLAPTLIB = $(notdir $(APTLIBFILES))
ALLAPTTEMPLATES = $(notdir $(APTTEMPLATES))
ALLUIKITFONTS = $(notdir $(UIKITFILES))
ALLBOOTSTFONTS = $(notdir $(BOOTSTFONTS))
ALLBOOTSTCSS = $(notdir $(BOOTSTCSS))
ALLBOOTSTJS = $(notdir $(BOOTSTJS))
ALLHELPCSS = $(notdir $(HELPERSCSS))
ALLHELPJS = $(notdir $(HELPERSJS))
ALLAPTCSS = $(notdir $(APTCSSFILES))
ALLAPTFONTS = $(notdir $(APTFONTS))
ALLAPTIMAGES = $(notdir $(APTIMAGES))
INSTALLFILES = $(addprefix $(INSTALL_SBINDIR)/, htmlinstall) \
$(addprefix $(INSTALL_WWWDIR)/, $(ALLFILES)) \
......@@ -273,11 +266,9 @@ apt-install: $(addprefix $(INSTALL_WWWDIR)/apt/, $(ALLAPTUI)) \
$(addprefix $(INSTALL_WWWDIR)/apt/js/, $(ALLAPTJS)) \
$(addprefix $(INSTALL_WWWDIR)/apt/js/lib/, $(ALLAPTLIB)) \
$(addprefix $(INSTALL_WWWDIR)/apt/template/, $(ALLAPTTEMPLATES)) \
$(addprefix $(INSTALL_WWWDIR)/apt/bootstrap/css/, $(ALLBOOTSTCSS)) \
$(addprefix $(INSTALL_WWWDIR)/apt/bootstrap/js/, $(ALLBOOTSTJS)) \
$(addprefix $(INSTALL_WWWDIR)/apt/bootstrap/fonts/, $(ALLBOOTSTFONTS)) \
$(addprefix $(INSTALL_WWWDIR)/apt/formhelpers/css/, $(ALLHELPCSS)) \
$(addprefix $(INSTALL_WWWDIR)/apt/formhelpers/js/, $(ALLHELPJS))
$(addprefix $(INSTALL_WWWDIR)/apt/css/, $(ALLAPTCSS)) \
$(addprefix $(INSTALL_WWWDIR)/apt/fonts/, $(ALLAPTFONTS)) \
$(addprefix $(INSTALL_WWWDIR)/apt/images/, $(ALLAPTIMAGES))
post-install:
......
......@@ -33,7 +33,7 @@ SPITHEADER();
echo "The URL you gave: <b>" . htmlentities( $_SERVER["REQUEST_URI"] ) . "</b>
is not available or is broken.";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/main'></script>";
SPITFOOTER();
......@@ -366,7 +366,7 @@ function SPITFORM($formfields, $newuser, $errors)
}
echo "</script>\n";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/instantiate'></script>";
}
......
This diff is collapsed.
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
/*!
* jQuery appendGrid v1.3.1
* https://appendgrid.apphb.com/
*
* Copyright 2014 Albert L.
* Dual licensed under the LGPL (http://www.gnu.org/licenses/lgpl.html)
* and MIT (http://www.opensource.org/licenses/mit-license.php) licenses.
*
* Depends:
* jQuery v1.9.1+
* jquery UI v1.10.2+
*/
.appendGrid
{
border-collapse: collapse;
}
.appendGrid td
{
padding: 1px;
}
.appendGrid thead td
{
padding-top: 4px;
padding-bottom: 4px;
white-space: nowrap;
}
.appendGrid thead td.caption
{
padding: 4px;
font-weight: bold;
}
.appendGrid tbody input[type=text]
{
width: 100%;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
}
.appendGrid tbody td
{
white-space: nowrap;
}
.appendGrid tbody td.first
{
text-align: center;
vertical-align: middle;
min-width: 32px;
}
.appendGrid tbody td.last
{
text-align: center;
vertical-align: middle;
white-space: nowrap;
}
.appendGrid tbody td.last button
{
min-height: 20px;
margin: 1px;
}
.appendGrid tbody td.last button.insert, .appendGrid tbody td.last button.remove, .appendGrid tbody td.last button.moveUp, .appendGrid tbody td.last button.moveDown
{
height: 20px;
width: 20px;
}
.appendGrid tbody td.last div.rowDrag
{
display: inline-block;
vertical-align: middle;
width: 18px;
height: 18px;
margin: 1px;
}
.appendGrid tfoot button
{
min-height: 24px;
min-width: 28px;
}
.appendGrid tfoot button.append, .appendGrid tfoot button.removeLast
{
height: 24px;
min-width: 28px;
}
.appendGrid input.double
{
text-align: right;
}
.appendGrid tbody tr.empty td
{
text-align: center;
}
\ No newline at end of file
/*!
* jQuery appendGrid v1.3.1
* https://appendgrid.apphb.com/
*
* Copyright 2014 Albert L.
* Dual licensed under the LGPL (http://www.gnu.org/licenses/lgpl.html)
* and MIT (http://www.opensource.org/licenses/mit-license.php) licenses.
*
* Depends:
* jQuery v1.9.1+
* jquery UI v1.10.2+
*/
.appendGrid
{
border-collapse: collapse;
}
.appendGrid td
{
padding: 1px;
}
.appendGrid thead td
{
padding-top: 4px;
padding-bottom: 4px;
white-space: nowrap;
}
.appendGrid thead td.caption
{
padding: 4px;
font-weight: bold;
}
.appendGrid tbody input[type=text]
{
width: 100%;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
}
.appendGrid tbody td
{
white-space: nowrap;
}
.appendGrid tbody td.first
{
text-align: center;
vertical-align: middle;
min-width: 32px;
}
.appendGrid tbody td.last
{
text-align: center;
vertical-align: middle;
white-space: nowrap;
}
.appendGrid tbody td.last button
{
min-height: 20px;
margin: 1px;
}
.appendGrid tbody td.last button.insert, .appendGrid tbody td.last button.remove, .appendGrid tbody td.last button.moveUp, .appendGrid tbody td.last button.moveDown
{
height: 20px;
width: 20px;
}
.appendGrid tbody td.last div.rowDrag
{
display: inline-block;
vertical-align: middle;
width: 18px;
height: 18px;
margin: 1px;
}
.appendGrid tfoot button
{
min-height: 24px;
min-width: 28px;
}
.appendGrid tfoot button.append, .appendGrid tfoot button.removeLast
{
height: 24px;
min-width: 28px;
}
.appendGrid input.double
{
text-align: right;
}
.appendGrid tbody tr.empty td
{
text-align: center;
}
\ No newline at end of file
......@@ -7,7 +7,7 @@ window.APT_OPTIONS.config = function ()
paths: {
'jquery-ui': 'js/lib/jquery-ui-1.10.4.custom',
'jquery-grid':'js/lib/jquery.appendGrid-1.3.1.min',
'formhelpers': 'formhelpers/js/bootstrap-formhelpers',
'formhelpers': 'js/lib/bootstrap-formhelpers',
'dateformat': 'js/lib/date.format',
'd3': 'js/lib/d3.v3',
'filestyle': 'js/lib/filestyle',
......
window.APT_OPTIONS.config();
require(['js/quickvm_sup', // jQuery modules
require(['underscore', 'js/quickvm_sup', // jQuery modules
'formhelpers', 'filestyle', 'marked', 'jacks'],
function (sup)
function (_, sup)
{
'use strict';
......
......@@ -65,7 +65,7 @@ if (NOLOGINS()) {
SPITUSERERROR("Sorry, logins are temporarily disabled, ".
"please try again later.");
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/main'></script>";
SPITFOOTER();
return;
......@@ -148,7 +148,7 @@ function SPITFORM($uid, $referrer, $error)
</div>\n";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/main'></script>";
SPITFOOTER();
return;
......@@ -187,7 +187,7 @@ else {
Please do not attempt to login again; it will not work!
</h3>\n";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/main'></script>";
SPITFOOTER();
return;
......
......@@ -45,7 +45,7 @@ if ($this_user) {
SPITHEADER();
echo "<center><font color=red>Logout failed!</font></failed>\n";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/main'></script>";
SPITFOOTER();
}
......
......@@ -110,11 +110,11 @@ function SPITFORM($formfields, $errors)
echo "</script>\n";
echo "<link rel='stylesheet'
href='jquery-ui-1.10.4.custom.min.css'>\n";
href='css/jquery-ui-1.10.4.custom.min.css'>\n";
echo "<link rel='stylesheet'
href='jquery.appendGrid-1.3.1.min.css'>\n";
href='css/jquery.appendGrid-1.3.1.min.css'>\n";
# For progress bubbles in the imaging modal.
echo "<link rel='stylesheet' href='progress.css'>\n";
echo "<link rel='stylesheet' href='css/progress.css'>\n";
echo "<script type='text/javascript'>\n";
echo " window.EDITING = " . ($editing ? 1 : 0) . ";\n";
......@@ -130,7 +130,7 @@ function SPITFORM($formfields, $errors)
}
echo "</script>\n";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/manage_profile'>
</script>";
......
......@@ -62,7 +62,7 @@ $target_uuid = $target_user->uuid();
SPITHEADER(1);
echo "<link rel='stylesheet'
href='tablesorter.css'>\n";
href='css/tablesorter.css'>\n";
$query_result =
DBQueryFatal("select * from apt_instances ".
......@@ -138,7 +138,7 @@ echo " </div>
</div>\n";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/myexperiments'></script>\n";
SPITFOOTER();
......
......@@ -57,7 +57,7 @@ $target_idx = $target_user->uid_idx();
SPITHEADER(1);
echo "<link rel='stylesheet'
href='tablesorter.css'>\n";
href='css/tablesorter.css'>\n";
$query_result =
DBQueryFatal("select *,DATE(created) as created ".
......@@ -184,7 +184,7 @@ echo "<script type='text/javascript'>\n";
echo " window.AJAXURL = 'server-ajax.php';\n";
echo "</script>\n";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/myprofiles'></script>\n";
SPITFOOTER();
......
......@@ -57,7 +57,7 @@ $PAGEERROR_HANDLER = function($msg, $status_code = 0) {
}
echo $msg;
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/null.js'></script>\n";
SPITFOOTER();
die("");
......@@ -86,8 +86,8 @@ function SPITHEADER($thinheader = 0)
echo "<html>
<head>
<title>$title</title>
<link rel='stylesheet' href='bootstrap/css/bootstrap.css'>
<link rel='stylesheet' href='quickvm.css'>
<link rel='stylesheet' href='css/bootstrap.css'>
<link rel='stylesheet' href='css/quickvm.css'>
<script src='js/common.js'></script>
<script src='https://www.emulab.net/emulab_sup.js'></script>
</head>
......@@ -240,7 +240,7 @@ function SPITAJAX_ERROR($code, $msg)
function SPITNULLREQUIRE()
{
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/null'></script>\n";
}
......
......@@ -53,7 +53,7 @@ function SPITFORM($formfields, $showverify, $errors)
$button_label = "Create Account";
echo "<link rel='stylesheet'
href='formhelpers/css/bootstrap-formhelpers.min.css'>\n";
href='css/bootstrap-formhelpers.min.css'>\n";
SPITHEADER(1);
......@@ -95,7 +95,7 @@ function SPITFORM($formfields, $showverify, $errors)
echo "</script>\n";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/signup'></script>";
SPITFOOTER();
}
......
......@@ -307,7 +307,7 @@ echo " window.APT_OPTIONS.creatorEmail = '" . $creator_email . "';\n";
echo " window.APT_OPTIONS.AJAXURL = 'server-ajax.php';\n";
echo "</script>\n";
echo "<script src='js/lib/jquery-2.0.3.min.js'></script>\n";
echo "<script src='bootstrap/js/bootstrap.js'></script>\n";
echo "<script src='js/lib/bootstrap.js'></script>\n";
echo "<script src='js/lib/require.js' data-main='js/status'></script>";
#
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment