Skip to content

Commit 3df7f16

Browse files
clean directory structure
1 parent fb88d56 commit 3df7f16

30 files changed

+7
-6
lines changed
File renamed without changes.
File renamed without changes.
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{"setup":"this.toRadians = function(degrees){\n return degrees * Math.PI / 180; \n};\nthis.rotation = 0;\nthis.halfWidth = context.canvas.width / 2;\nthis.halfHeight = context.canvas.height / 2;","draw":"context.fillStyle = \"rgb(100,250,250)\";\ncontext.fillRect(0, 0, context.canvas.width, context.canvas.height);\n\ncontext.save();\ncontext.translate(this.halfWidth, this.halfHeight);\ncontext.scale(Math.cos(this.rotation * 0.1 ) * 4, Math.sin(this.rotation * 0.1) * 4 );\ncontext.rotate(this.toRadians(this.rotation));\n\nthis.rotation = (this.rotation + .05 ) % 360;\n//this.rotation += this.rotation * 0.05 *(Math.random()-.75);\n\ncontext.fillStyle = \"rgb(200,0,25)\";\ncontext.fillRect(-25, -25, 50, 50);\n\ncontext.restore();\n "}
1+
{"setup":"this.toRadians = function(degrees){\n return degrees * Math.PI / 180; \n};\nthis.rotation = 0;\nthis.halfWidth = context.canvas.width / 2;\nthis.halfHeight = context.canvas.height / 2;","draw":"context.fillStyle = \"rgb(100,250,250)\";\ncontext.fillRect(0, 0, context.canvas.width, context.canvas.height);\n\ncontext.save();\ncontext.translate(this.halfWidth, this.halfHeight);\ncontext.scale(Math.cos(this.rotation * 0.1 ) * 4, Math.sin(this.rotation * 0.1) * 4 );\ncontext.rotate(this.toRadians(this.rotation));\n\nthis.rotation = (this.rotation + .05 ) % 360;\n//this.rotation += this.rotation * 0.05 *(Math.random()-.75);\n\ncontext.fillStyle = \"rgb(200,0,200)\";\ncontext.fillRect(-25, -25, 50, 50);\n\ncontext.restore();\n "}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

csshelper.js public/csshelper.js

File renamed without changes.

editor.js public/editor.js

File renamed without changes.

evileval.js public/evileval.js

File renamed without changes.

exquis.js public/exquis.js

File renamed without changes.

index.html public/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
.code_valid { border: solid rgb(25, 125, 255); }
3131
.invisible { display: none;}
3232
</style>
33-
<script data-main="/main.js" src="/require.js"></script>
33+
<script data-main="/main.js" src="/lib/require.js"></script>
3434
</head>
3535
<body>
3636
<div id="container">

iter2d.js public/iter2d.js

File renamed without changes.

lib/async.js public/lib/async.js

File renamed without changes.

domReady.js public/lib/domReady.js

File renamed without changes.
File renamed without changes.

require.js public/lib/require.js

File renamed without changes.

main.js public/main.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,4 +20,4 @@ var main = function(net, exquis){
2020
window.load();
2121
};
2222

23-
require(["net", "exquis", "domReady!"], main);
23+
require(["net", "exquis", "lib/domReady!"], main);

net.js public/net.js

File renamed without changes.

ui.js public/ui.js

File renamed without changes.

server.js

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
var sys = require('sys'),
22
http = require('http'),
33
fs = require('fs'),
4-
exquis;
4+
exquis,
5+
rootStaticFiles = './public/';
56

67

78

@@ -79,7 +80,7 @@ var startServer = function (allowTests){
7980
pathname = "/index.html";
8081
}else if(matchingDir){
8182

82-
fs.readdir("./"+ matchingDir[0], function(err, files){
83+
fs.readdir(rootStaticFiles + matchingDir[0], function(err, files){
8384
if(err) {
8485
console.log(err);
8586
response.writeHead(500, "OUPS", {'Content-Type': 'text/html'});
@@ -92,7 +93,7 @@ var startServer = function (allowTests){
9293
});
9394
}
9495

95-
pathname = "." + pathname;
96+
pathname = rootStaticFiles + pathname;
9697

9798
if (request.method === "GET"){
9899
fetchFile(pathname, response);

0 commit comments

Comments
 (0)