Skip to content

Commit

Permalink
remove all old site stuff. we dont run the site from this project any…
Browse files Browse the repository at this point in the history
…more.
  • Loading branch information
sporritt committed May 21, 2018
1 parent a7f6909 commit 3249ccc
Show file tree
Hide file tree
Showing 221 changed files with 535 additions and 54,016 deletions.
184 changes: 7 additions & 177 deletions Gruntfile.js
Expand Up @@ -62,10 +62,6 @@ module.exports = function(grunt) {
grunt.log.write('Build jsPlumb');
});

grunt.registerTask('prepare', function() {
grunt.file.delete("dist");
});


var fileLists = function(suffix) {
suffix = suffix || "";
Expand Down Expand Up @@ -99,49 +95,11 @@ module.exports = function(grunt) {
}
}
},
copy:{
site:{
files:[
{ expand:true, cwd:"css", src:"*.*", dest:"jekyll/css" },
{ expand:true, cwd:"demo/font", src:"*.*", dest:"jekyll/css" },
{ expand:true, cwd:"img", src:"*.*", dest:"jekyll/img" },
{ expand:true, cwd:"demo", src:["**/*.jpg", "**/*.png" ], dest:"dist/demo/"}
]
},
demos:{
files:[
{ expand: true, cwd:"demo", src:"demo-list.js", dest:"jekyll/js"}
]
},
tests:{
files:[
{ expand:true, cwd:"tests", src:[ "*.css", "qunit-*.js", "*.js", "loadtest-template.html" ], dest:"jekyll/tests" }
]
},
js:{
files:[
{ expand:true, cwd:"dist/js", src:"*.js", dest:"jekyll/js" }
]
},
dist:{
files:[
{ expand:true, cwd:"jekyll/_site", src:"**/*.*", dest:"dist" }
]
},
external:{
files:[
{ expand:true, cwd:"external", src:"*.*", dest:"jekyll/external" },
{ expand:true, cwd:"css/external", src:"*.*", dest:"dist/css/external" }
]
}
},
clean:{
options:{
force:true
},
dist:["dist"],
stage:[ "jekyll/doc", "jekyll/apidocs", "jekyll/demo", "jekyll/tests", "jekyll/css", "jekyll/js", "jekyll/img", "jekyll/external" ],
site: [ 'jekyll/_site' ]
dist:["dist"]
},
jshint: {
options: {
Expand Down Expand Up @@ -186,17 +144,6 @@ module.exports = function(grunt) {
tasks: ['build-src']
}
},
jekyll: {
options: {
src:'jekyll'
},
dist:{
options:{
dest:"jekyll/_site",
config:'jekyll/_config.yml'
}
}
},
yuidoc: {
compile: {
name: '<%= pkg.name %>',
Expand All @@ -205,21 +152,9 @@ module.exports = function(grunt) {
url: '<%= pkg.homepage %>',
options: {
paths: 'doc/api/',
themedir: 'jekyll/yuitheme/',
outdir: 'jekyll/apidocs/',
helpers:['jekyll/yuitheme/helpers.js']
}
},
tests:{
name: '<%= pkg.name %> - Test Coverage',
description: '<%= pkg.description %>',
version: '<%= pkg.version %>',
url: '<%= pkg.homepage %>',
options: {
paths: 'tests/',
themedir: 'jekyll/yuitheme/',
outdir: 'jekyll/test-apidocs/',
helpers:['jekyll/yuitheme/helpers.js']
themedir: 'doc/yuitheme/',
outdir: 'dist/apidocs/',
helpers:['doc/yuitheme/helpers.js']
}
}
},
Expand All @@ -236,115 +171,13 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-qunit');
grunt.loadNpmTasks('grunt-contrib-connect');
grunt.loadNpmTasks('grunt-qunit-junit');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-yuidoc');
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-jekyll');
grunt.loadNpmTasks('grunt-exec');


// ------------------------- prepare jekyll site task --------------------------------------------------------

var support = require("./build-support.js");
var demoList = BUILD.demos;

var _createDemos = function() {
for (var i = 0; i < demoList.length; i++) {
var d = demoList[i].id,
js = grunt.file.read("demo/" + d + "/demo.js"),
css = grunt.file.read("demo/" + d + "/demo.css");

grunt.file.mkdir("jekyll/demo/" + d);
//for (var j = 0; j < libraries.length; j++) {
var html = grunt.file.read("demo/" + d + "/dom.html"),
m = html.match(/(<!-- demo.*>.*\n)(.*\n)*(.*\/demo -->)/),
t = demoList[i].name;

grunt.file.write("jekyll/demo/" + d + "/demo.js", js);
grunt.file.write("jekyll/demo/" + d + "/demo.css", css);
var fm = support.createFrontMatter({
layout:"demo",
date:support.timestamp(),
categories:"demo",
title:t,
base:"../..",
demo:d
});
grunt.file.write("jekyll/demo/" + demoList[i].id + "/dom.html", fm + m[0]);
// }
}
};



//
// creates qunit test pages: we only need to create markdown files here; the jekyll layout fills in the rest.
//
var _createTests = function() {
// unit tests


var frontMatter = support.createFrontMatter({
layout:"test",
date:support.timestamp(),
categories:"test",
renderer:"svg",
base:".."
});
grunt.file.write("jekyll/tests/qunit-svg-dom-instance.html", frontMatter);


// load tests
var lt = grunt.file.read("tests/loadtest-template.html");

var frontMatter = support.createFrontMatter({
layout:"loadtest",
date:support.timestamp(),
categories:"test",
base:".."
});
grunt.file.write("jekyll/tests/loadtest-dom.html", frontMatter + lt);

// now create index page
var ip = grunt.file.read("tests/index.html"),
m = ip.match(/(<!-- content.*>.*\n)(.*\n)*(.*\/content -->)/),
fm = support.createFrontMatter({
layout:"default",
date:support.timestamp(),
base:".."
});

grunt.file.write("jekyll/tests/index.html", fm + m[0]);
};

var _prepareSite = function() {
// exclusions from input doc dir
var exclusions = ["node_modules", "ff.htl"],
docOutput = "jekyll/doc";

// 1. create directories for docs.
grunt.file.mkdir(docOutput);

// 2. copy files from markdown directory into 'doc', and then give each one some front matter.
var sources = grunt.file.expand({ cwd:"doc/wiki" }, "*");
for (var i = 0; i < sources.length; i++) {
if (exclusions.indexOf(sources[i]) == -1) {
var layout = sources[i] == "contents.md" ? "plain" : "doc";
support.processMarkdownFile(grunt, "doc/wiki", sources[i], layout, "..", docOutput);
}
}
};

grunt.registerTask('writeIndex', function() {
// write an index file to the root of the dist dir (redirects to main "Vanilla" demo)
grunt.file.write("jekyll/index.html", "<!doctype html><html><head><meta http-equiv='refresh' content='0;url=demo/flowchart/dom.html'/></head></html>");
// and to the demo directory root
grunt.file.write("jekyll/demo/index.html", "<!doctype html><html><head><meta http-equiv='refresh' content='0;url=flowchart/dom.html'/></head></html>");
// write an index file to the root of the docs dir (redirects to 'home')
grunt.file.write("jekyll/doc/index.html", "<!doctype html><html><head><meta http-equiv='refresh' content='0;url=home.html'/></head></html>");
});



Expand All @@ -355,11 +188,9 @@ module.exports = function(grunt) {
grunt.file.write("dist/js/jsplumb.min.js", src.replace("<% pkg.version %>", package.version));
});

grunt.registerTask('createTests', _createTests);
grunt.registerTask('createDemos', _createDemos);
grunt.registerTask('prepare', _prepareSite);
grunt.registerTask("build", [ 'build-src', 'clean:stage', 'prepare', 'copy:site', 'copy:tests', 'copy:js', 'copy:demos', 'copy:external', 'yuidoc', 'createTests', 'createDemos', 'writeIndex', 'jekyll', 'copy:dist', 'clean:stage', 'clean:site', 'exec:npmpack' ]);
grunt.registerTask('build-src', ['clean', 'jshint', 'prepare', 'concat', 'uglify', 'insertVersion' ]);

grunt.registerTask("build", [ 'build-src', 'yuidoc', 'exec:npmpack' ]);
grunt.registerTask('build-src', ['clean', 'jshint', 'concat', 'uglify', 'insertVersion' ]);
grunt.registerTask('default', ['help']);
grunt.registerTask('build-all', ['qunit', 'build']);

Expand Down Expand Up @@ -390,7 +221,6 @@ module.exports = function(grunt) {
_replace("demo", "**/*.html", oldV, newV);
_replace(".", "package.json", oldV, newV);
_replace(".", "README.md", oldV, newV);
_replace("jekyll", "**/*.*", oldV, newV);
}

});
Expand Down
108 changes: 10 additions & 98 deletions dist/apidocs/classes/Anchors.Assign.html
@@ -1,78 +1,16 @@
---
layout: apidoc
title: "Anchors.Assign - jsplumb API documentation"
date: 2014-01-01 00:00:00
yuiGridsUrl: http://yui.yahooapis.com/3.9.1/build/cssgrids/cssgrids-min.css
yuiSeedUrl: http://yui.yahooapis.com/combo?3.9.1/build/yui/yui-min.js
projectAssets: ../assets
base: "../.."
---

<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no"/>
<title>Anchors.Assign - jsplumb API documentation</title>



<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css" rel="stylesheet">
<link href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css" rel="stylesheet">
<link href="//fonts.googleapis.com/css?family=Lato:400,700" rel="stylesheet">
<link rel="stylesheet" href="../../css/main.css">
<link rel="stylesheet" href="../../css/jsplumb-doc.css">

<!-- yuidoc -->
<link rel="stylesheet" href="http://yui.yahooapis.com/3.9.1/build/cssgrids/cssgrids-min.css">
<link rel="stylesheet" href="../assets/vendor/prettify/prettify-min.css">

<link rel="stylesheet" href="../../css/external/cssgrids-min.css">
<link rel="stylesheet" href="../../css/external/prettify-min.css">

<link rel="shortcut icon" type="image/png" href="../../img/favicon.png">
<script src="https://yui-s.yahooapis.com/combo?3.9.1/build/yui/yui-min.js"></script>
<style>
#doc {
text-align:left;
margin-top:44px;
}
</style>
</head>
<body class="yui3-skin-sam">

<div class="navbar navbar-top navbar-fixed-top" role="navigation">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>

<a class="navbar-brand" href="/"><img src="../../img/logo-medium-jsplumb.png"></a>
<div class="community"></div>

</div>

<div class="navbar-collapse collapse nav-wrapper">
<ul class="nav navbar-nav">
<li><a href="../../">DEMOS</a></li>
<li><a href="../../doc/home.html">DOCS</a></li>
<li><a href="../../apidocs/index.html">API</a></li>
<li><a href="../../download">DOWNLOAD</a></li>
<li><a href="http://beta.jsplumbtoolkit.com/contact.html">CONTACT</a></li>
<li><a href="https://blog.jsplumbtoolkit.com">BLOG</a></li>

</ul>

<div class="social-nav hidden-xs">
<a href="http://twitter.com/jsplumblib" class="link"><span class="icon-twitter"></span></a>
<a href="http://github.com/sporritt/jsplumb/" class="link"><span class="icon-github"></span></a>
<a href="http://www.linkedin.com/company/jsplumb" class="link"><span class="icon-linkedin"></span></a>

</div>
</div><!--/.nav-collapse -->
</div>
</div>

<div class="container">
<div class="row">
<div id="doc">
<div id="doc">
<div id="bd" class="yui3-g">
<div class="yui3-u-1-4">
<div id="docs-sidebar" class="sidebar apidocs">
Expand Down Expand Up @@ -282,29 +220,3 @@ <h2 class="off-left">Item Index</h2>
</div>
</div>
</div>

</div>
</div>

<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');

ga('create', 'UA-49979015-1', 'auto');
ga('send', 'pageview');

</script>


<script src="../assets/vendor/prettify/prettify-min.js"></script>
<script>prettyPrint();</script>
<script src="../assets/js/yui-prettify.js"></script>
<script src="../assets/../api.js"></script>
<script src="../assets/js/api-filter.js"></script>
<script src="../assets/js/api-list.js"></script>
<script src="../assets/js/api-search.js"></script>
<script src="../assets/js/apidocs.js"></script>
</body>
</html>

0 comments on commit 3249ccc

Please sign in to comment.