-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathcode.php
More file actions
27 lines (20 loc) · 707 Bytes
/
code.php
File metadata and controls
27 lines (20 loc) · 707 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<?php
require_once('config.php');
include_once 'github_repos.php';
View::$title = 'High Fidelity code';
View::write('page', 'code');
View::addStyle('css/code.css');
View::addScript('js/packery.pkgd.min.js');
View::addScript('js/code.js');
View::addScript('js/json-sans-eval.js');
View::addScript('js/game-of-life-v3.1.1.js');
$gh = new GithubCloud();
$gh->setToken(GITHUB_API_TOKEN);
for ($i = 0; $i < count($github_repos); $i++) {
$repo = $github_repos[$i];
if (isset($repo['show_cloud']) && $repo['show_cloud'] === true) {
$github_repos[$i]['words'] = $gh->getWordsForRepo($repo['github_repo']);
}
}
View::write('github_repos', $github_repos);
View::renderCommonLayout('code');