diff --git a/public/client.js b/public/client.js index e4abea3..0fcd087 100644 --- a/public/client.js +++ b/public/client.js @@ -19,6 +19,7 @@ document.addEventListener('click', function (e) { document.querySelector('main').outerHTML = json.html; // and change the file name in the header. document.querySelector('.js-file-name').textContent = json.context.fileName; + document.querySelector('.js-file-name-link').href = 'https://github.com/j-f1/forked-super-tiny-compiler/tree/glitch/' + json.context.fileName; // Finally, update the title bar and address bar, history.pushState(null, json.title, target.href); diff --git a/server.js b/server.js index dc03eeb..8725666 100644 --- a/server.js +++ b/server.js @@ -6,6 +6,9 @@ var path = require('path'); var ejs = require('ejs'); var fs = require('fs'); +process.env.NWO = process.env.NWO || 'thejameskyle/the-super-tiny-compiler'; +process.env.BRANCH = process.env.BRANCH || 'master'; + // First, let's create the server, var app = express(); // add a `req.body` property to requests containing diff --git a/template.html.ejs b/template.html.ejs index b23e5da..212bb05 100644 --- a/template.html.ejs +++ b/template.html.ejs @@ -93,8 +93,10 @@ left: 300px; right: 0; overflow: auto; + } + main.is-code { /* The topbar, the padding, and the last line */ - padding-bottom: calc(100vh - 2em - 1em - 2em); + padding-bottom: calc(100vh - 2em - 1em - 0.7em); } main pre#code { padding-bottom: 0; @@ -289,19 +291,15 @@
- - /Users/thejameskyle/code/the-super-tiny-compiler/<%= fileName %> + + /Users/you/code/the-super-tiny-compiler/<%= fileName %> - + Star this in GitHub - - - Follow me on Twitter - - - + + Remix this in Glitch