Merge branch 'content-reorganize'

This commit is contained in:
Kristian Polso 2018-05-30 18:52:10 +03:00
commit 682f054c61
70 changed files with 23 additions and 23 deletions

2
.gitignore vendored
View file

@ -13,6 +13,6 @@ yarn-error.log*
*.njsproj
*.sln
.vuepress/dist
content/.vuepress/dist
.env

View file

@ -82,7 +82,7 @@ export default {
</script>
<style lang="scss">
@import "../../node_modules/highlight.js/styles/monokai-sublime";
@import "../../../node_modules/highlight.js/styles/monokai-sublime";
@import "../scss/init/colors";
@import "../scss/init/extends";
@import "../scss/init/mixins";

View file

@ -1,5 +1,6 @@
// .vuepress/config.js
module.exports = {
base: '/',
title: 'LBRY.tech',
head: [
['meta', {name: 'viewport', content: 'initial-scale=1, viewport-fit=cover'}],

View file

Before

Width:  |  Height:  |  Size: 445 KiB

After

Width:  |  Height:  |  Size: 445 KiB

View file

Before

Width:  |  Height:  |  Size: 91 B

After

Width:  |  Height:  |  Size: 91 B

View file

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

View file

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

View file

Before

Width:  |  Height:  |  Size: 562 B

After

Width:  |  Height:  |  Size: 562 B

View file

Before

Width:  |  Height:  |  Size: 288 B

After

Width:  |  Height:  |  Size: 288 B

View file

Before

Width:  |  Height:  |  Size: 1.3 KiB

After

Width:  |  Height:  |  Size: 1.3 KiB

View file

Before

Width:  |  Height:  |  Size: 154 B

After

Width:  |  Height:  |  Size: 154 B

View file

Before

Width:  |  Height:  |  Size: 745 B

After

Width:  |  Height:  |  Size: 745 B

View file

Before

Width:  |  Height:  |  Size: 411 B

After

Width:  |  Height:  |  Size: 411 B

View file

Before

Width:  |  Height:  |  Size: 408 B

After

Width:  |  Height:  |  Size: 408 B

View file

Before

Width:  |  Height:  |  Size: 426 B

After

Width:  |  Height:  |  Size: 426 B

View file

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

View file

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 1.5 KiB

View file

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

View file

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View file

Before

Width:  |  Height:  |  Size: 34 KiB

After

Width:  |  Height:  |  Size: 34 KiB

View file

Before

Width:  |  Height:  |  Size: 414 B

After

Width:  |  Height:  |  Size: 414 B

4
content/index.md Normal file
View file

@ -0,0 +1,4 @@
---
home: true
title: LBRY.tech
---

View file

@ -1,18 +0,0 @@
require('dotenv').config();
var octokit = require('@octokit/rest')();
var redis = require("redis"),
redisClient = redis.createClient(process.env.REDISCLOUD_URL);
octokit.activity.getEventsForOrg({
org: 'lbryio',
per_page: 20,
page: 1
}).then(function({data}) {
console.log(data);
redisClient.set('events', JSON.stringify(data), redis.print);
});

View file

@ -5,8 +5,8 @@
"author": "",
"private": true,
"scripts": {
"dev": "./node_modules/vuepress/bin/vuepress.js dev",
"start": "./node_modules/vuepress/bin/vuepress.js build && node server.js"
"dev": "./node_modules/vuepress/bin/vuepress.js dev content",
"start": "./node_modules/vuepress/bin/vuepress.js build content && node server.js"
},
"engines": {
"node": "10.2.x"

View file

@ -2,6 +2,8 @@
// env variables
require('dotenv').config();
// fs
var fs = require('fs');
// Async
var async = require("async");
// Express etc
@ -22,7 +24,7 @@ redisClient = redis.createClient(process.env.REDISCLOUD_URL);
var logger = require('heroku-logger');
app = express();
app.use(serveStatic(__dirname + "/.vuepress/dist"));
app.use(serveStatic(__dirname + "/content/.vuepress/dist"));
app.use(cors());
@ -89,6 +91,17 @@ app.get('/github-feed', function(req, res) {
});
app.get('/*', function(req, res) {
if(fs.existsSync(__dirname + "/.vuepress/dist" + req.path + ".html")) {
res.redirect(req.path + ".html");
} else {
res.status(404);
res.send('Not found');
}
});
var port = process.env.PORT || 8080;
app.listen(port);