forked from tildeverse/tilde.chat
use tildeverse/wiki
This commit is contained in:
parent
5c1dff6521
commit
d15fccb3ab
@ -1,4 +1,4 @@
|
|||||||
# EdeitorConfig to make ben's editor stop defaulting to spaces
|
# EditorConfig to make ben's editor stop defaulting to spaces
|
||||||
|
|
||||||
root = true # yes, this is the root editorconfig for this project
|
root = true # yes, this is the root editorconfig for this project
|
||||||
|
|
||||||
|
@ -1,2 +0,0 @@
|
|||||||
#mysecrets
|
|
||||||
#dontlookhere
|
|
@ -1,6 +1,11 @@
|
|||||||
{
|
{
|
||||||
"require": {
|
"require": {
|
||||||
"michelf/php-markdown": "^1.8",
|
"tildeverse/wiki": "dev-master"
|
||||||
"mnapoli/front-yaml": "^1.6"
|
},
|
||||||
|
"repositories": [
|
||||||
|
{
|
||||||
|
"type": "vcs",
|
||||||
|
"url": "https://tildegit.org/ben/tildewiki"
|
||||||
}
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
113
composer.lock
generated
113
composer.lock
generated
@ -4,23 +4,24 @@
|
|||||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||||
"This file is @generated automatically"
|
"This file is @generated automatically"
|
||||||
],
|
],
|
||||||
"content-hash": "d6a1ecb21bac8642fb0b75ee1e70eced",
|
"content-hash": "3ab3df15c4e40417f427b37691e83088",
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "erusev/parsedown",
|
"name": "erusev/parsedown",
|
||||||
"version": "1.7.0",
|
"version": "1.7.3",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/erusev/parsedown.git",
|
"url": "https://github.com/erusev/parsedown.git",
|
||||||
"reference": "6678d59be48c4be64eaca6ce70bea48a09488cc2"
|
"reference": "6d893938171a817f4e9bc9e86f2da1e370b7bcd7"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/erusev/parsedown/zipball/6678d59be48c4be64eaca6ce70bea48a09488cc2",
|
"url": "https://api.github.com/repos/erusev/parsedown/zipball/6d893938171a817f4e9bc9e86f2da1e370b7bcd7",
|
||||||
"reference": "6678d59be48c4be64eaca6ce70bea48a09488cc2",
|
"reference": "6d893938171a817f4e9bc9e86f2da1e370b7bcd7",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
|
"ext-mbstring": "*",
|
||||||
"php": ">=5.3.0"
|
"php": ">=5.3.0"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
@ -49,53 +50,51 @@
|
|||||||
"markdown",
|
"markdown",
|
||||||
"parser"
|
"parser"
|
||||||
],
|
],
|
||||||
"time": "2018-02-28T11:41:37+00:00"
|
"time": "2019-03-17T18:48:37+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "michelf/php-markdown",
|
"name": "erusev/parsedown-extra",
|
||||||
"version": "1.8.0",
|
"version": "0.7.1",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/michelf/php-markdown.git",
|
"url": "https://github.com/erusev/parsedown-extra.git",
|
||||||
"reference": "01ab082b355bf188d907b9929cd99b2923053495"
|
"reference": "0db5cce7354e4b76f155d092ab5eb3981c21258c"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/michelf/php-markdown/zipball/01ab082b355bf188d907b9929cd99b2923053495",
|
"url": "https://api.github.com/repos/erusev/parsedown-extra/zipball/0db5cce7354e4b76f155d092ab5eb3981c21258c",
|
||||||
"reference": "01ab082b355bf188d907b9929cd99b2923053495",
|
"reference": "0db5cce7354e4b76f155d092ab5eb3981c21258c",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
"php": ">=5.3.0"
|
"erusev/parsedown": "~1.4"
|
||||||
},
|
},
|
||||||
"type": "library",
|
"type": "library",
|
||||||
"autoload": {
|
"autoload": {
|
||||||
"psr-4": {
|
"psr-0": {
|
||||||
"Michelf\\": "Michelf/"
|
"ParsedownExtra": ""
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"notification-url": "https://packagist.org/downloads/",
|
"notification-url": "https://packagist.org/downloads/",
|
||||||
"license": [
|
"license": [
|
||||||
"BSD-3-Clause"
|
"MIT"
|
||||||
],
|
],
|
||||||
"authors": [
|
"authors": [
|
||||||
{
|
{
|
||||||
"name": "Michel Fortin",
|
"name": "Emanuil Rusev",
|
||||||
"email": "michel.fortin@michelf.ca",
|
"email": "hello@erusev.com",
|
||||||
"homepage": "https://michelf.ca/",
|
"homepage": "http://erusev.com"
|
||||||
"role": "Developer"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "John Gruber",
|
|
||||||
"homepage": "https://daringfireball.net/"
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"description": "PHP Markdown",
|
"description": "An extension of Parsedown that adds support for Markdown Extra.",
|
||||||
"homepage": "https://michelf.ca/projects/php-markdown/",
|
"homepage": "https://github.com/erusev/parsedown-extra",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"markdown"
|
"markdown",
|
||||||
|
"markdown extra",
|
||||||
|
"parsedown",
|
||||||
|
"parser"
|
||||||
],
|
],
|
||||||
"time": "2018-01-15T00:49:33+00:00"
|
"time": "2015-11-01T10:19:22+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "mnapoli/front-yaml",
|
"name": "mnapoli/front-yaml",
|
||||||
@ -134,16 +133,16 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "symfony/polyfill-ctype",
|
"name": "symfony/polyfill-ctype",
|
||||||
"version": "v1.9.0",
|
"version": "v1.11.0",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/symfony/polyfill-ctype.git",
|
"url": "https://github.com/symfony/polyfill-ctype.git",
|
||||||
"reference": "e3d826245268269cd66f8326bd8bc066687b4a19"
|
"reference": "82ebae02209c21113908c229e9883c419720738a"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/e3d826245268269cd66f8326bd8bc066687b4a19",
|
"url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/82ebae02209c21113908c229e9883c419720738a",
|
||||||
"reference": "e3d826245268269cd66f8326bd8bc066687b4a19",
|
"reference": "82ebae02209c21113908c229e9883c419720738a",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -155,7 +154,7 @@
|
|||||||
"type": "library",
|
"type": "library",
|
||||||
"extra": {
|
"extra": {
|
||||||
"branch-alias": {
|
"branch-alias": {
|
||||||
"dev-master": "1.9-dev"
|
"dev-master": "1.11-dev"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
@ -188,20 +187,20 @@
|
|||||||
"polyfill",
|
"polyfill",
|
||||||
"portable"
|
"portable"
|
||||||
],
|
],
|
||||||
"time": "2018-08-06T14:22:27+00:00"
|
"time": "2019-02-06T07:57:58+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "symfony/yaml",
|
"name": "symfony/yaml",
|
||||||
"version": "v4.1.4",
|
"version": "v4.3.2",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/symfony/yaml.git",
|
"url": "https://github.com/symfony/yaml.git",
|
||||||
"reference": "b832cc289608b6d305f62149df91529a2ab3c314"
|
"reference": "c60ecf5ba842324433b46f58dc7afc4487dbab99"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/symfony/yaml/zipball/b832cc289608b6d305f62149df91529a2ab3c314",
|
"url": "https://api.github.com/repos/symfony/yaml/zipball/c60ecf5ba842324433b46f58dc7afc4487dbab99",
|
||||||
"reference": "b832cc289608b6d305f62149df91529a2ab3c314",
|
"reference": "c60ecf5ba842324433b46f58dc7afc4487dbab99",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -220,7 +219,7 @@
|
|||||||
"type": "library",
|
"type": "library",
|
||||||
"extra": {
|
"extra": {
|
||||||
"branch-alias": {
|
"branch-alias": {
|
||||||
"dev-master": "4.1-dev"
|
"dev-master": "4.3-dev"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"autoload": {
|
"autoload": {
|
||||||
@ -247,13 +246,45 @@
|
|||||||
],
|
],
|
||||||
"description": "Symfony Yaml Component",
|
"description": "Symfony Yaml Component",
|
||||||
"homepage": "https://symfony.com",
|
"homepage": "https://symfony.com",
|
||||||
"time": "2018-08-18T16:52:46+00:00"
|
"time": "2019-04-06T14:04:46+00:00"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "tildeverse/wiki",
|
||||||
|
"version": "dev-master",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://tildegit.org/ben/tildewiki",
|
||||||
|
"reference": "751eb64c383cb7c6ec643eaf683b88aa1de351ea"
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"erusev/parsedown-extra": "^0.7.1",
|
||||||
|
"mnapoli/front-yaml": "^1.6"
|
||||||
|
},
|
||||||
|
"type": "library",
|
||||||
|
"autoload": {
|
||||||
|
"psr-4": {
|
||||||
|
"Tildeverse\\Wiki\\": "src/"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"license": [
|
||||||
|
"GPLv3"
|
||||||
|
],
|
||||||
|
"authors": [
|
||||||
|
{
|
||||||
|
"name": "Ben Harris",
|
||||||
|
"email": "ben@tilde.team"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "parsedown extensions for tilde wikis",
|
||||||
|
"time": "2019-07-03T05:06:34+00:00"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"packages-dev": [],
|
"packages-dev": [],
|
||||||
"aliases": [],
|
"aliases": [],
|
||||||
"minimum-stability": "stable",
|
"minimum-stability": "stable",
|
||||||
"stability-flags": [],
|
"stability-flags": {
|
||||||
|
"tildeverse/wiki": 20
|
||||||
|
},
|
||||||
"prefer-stable": false,
|
"prefer-stable": false,
|
||||||
"prefer-lowest": false,
|
"prefer-lowest": false,
|
||||||
"platform": [],
|
"platform": [],
|
||||||
|
@ -1,47 +0,0 @@
|
|||||||
<?php
|
|
||||||
$title = 'tilde.chat discord bridge';
|
|
||||||
include __DIR__.'/../header.php';
|
|
||||||
?>
|
|
||||||
|
|
||||||
<h1>tilde.chat discord</h1>
|
|
||||||
|
|
||||||
<pre>
|
|
||||||
khuxkm Today at 1:39 AM
|
|
||||||
|
|
||||||
ATTENTION @everyone:
|
|
||||||
|
|
||||||
Due to recent events in the Discord server, we have decided to lock this Discord and accompanying IRC bridge until
|
|
||||||
further notice. On Monday, the IRC to Discord bridge will be shut down and all channels in this Discord will be set
|
|
||||||
to READ-ONLY. This decision will only be reversed when a full discussion has been held on moderation requirements,
|
|
||||||
rules, and certain members of our moderation team who appear to be missing.
|
|
||||||
|
|
||||||
How this affects you:
|
|
||||||
|
|
||||||
- If you primarily use Discord, you will have to use IRC from now on. tilde.team users can use our TheLounge instance at
|
|
||||||
https://irc.tilde.team/ for a Discord-like experience (or any other client of their choosing), whereas members of
|
|
||||||
other tildes can continue using their tilde's node in the tilde.chat network.
|
|
||||||
|
|
||||||
- If you primarily use IRC, all that changes is that you will not be able to use this Discord.
|
|
||||||
|
|
||||||
The behavior of some users in this Discord has been unacceptable and does not comply with our code of conduct.
|
|
||||||
Upon further review, we have decided that managing this Discord server is a bit more than we can handle without discussing
|
|
||||||
moderation in-depth. As such, ben and I (khuxkm) have decided to make this Discord READ-ONLY until we have come to a more
|
|
||||||
permanent decision (which may be to close this server permanently).
|
|
||||||
|
|
||||||
If you have any thoughts/ideas for the future of the discord bridge, please drop a line to ben or myself on IRC or by email
|
|
||||||
(@tilde.team). We can be found in the #sudoers channel.
|
|
||||||
|
|
||||||
Thanks for being a member of the tildeverse and working with us to figure out a chat solution that works for everyone!
|
|
||||||
</pre>
|
|
||||||
|
|
||||||
<!-- See above, but here are the links if you want 'em anyways:
|
|
||||||
<strong>which tilde are you part of?</strong>
|
|
||||||
<hr>
|
|
||||||
<p>
|
|
||||||
<a href="https://discord.gg/BH4Bs5U" class="btn btn-default">tilde.team</a>
|
|
||||||
<a href="https://discord.gg/GhmGb3x" class="btn btn-default">tilde.town</a>
|
|
||||||
<a href="https://discord.gg/sfhzHBc" class="btn btn-default">yourtilde.com</a>
|
|
||||||
</p>->
|
|
||||||
|
|
||||||
<?php
|
|
||||||
include __DIR__.'/../footer.php';
|
|
16
footer.php
16
footer.php
@ -1,10 +1,10 @@
|
|||||||
<br><br>
|
<br><br>
|
||||||
</div>
|
</div>
|
||||||
<footer class="text-center">
|
<footer class="text-center">
|
||||||
<a href="https://tildegit.org/tildeverse/tilde.chat">site source</a> ~ official ircnet of the <a href="https://tildeverse.org">tildeverse</a>
|
<a href="https://tildegit.org/tildeverse/tilde.chat">site source</a>
|
||||||
</footer>
|
~ official ircnet of the <a href="https://tildeverse.org">tildeverse</a>
|
||||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
|
</footer>
|
||||||
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.4/js/bootstrap.min.js"></script>
|
<script src="/js/jquery.min.js"></script>
|
||||||
<script src="./jasny-bootstrap.js"></script>
|
<script src="/js/bootstrap.min.js"></script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
1024
jasny-bootstrap.js
1024
jasny-bootstrap.js
File diff suppressed because it is too large
Load Diff
7
js/bootstrap.min.js
vendored
Normal file
7
js/bootstrap.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
4
js/jquery.min.js
vendored
Normal file
4
js/jquery.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
16
navbar.php
16
navbar.php
@ -11,17 +11,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<div id="navbar" class="navbar-collapse collapse">
|
<div id="navbar" class="navbar-collapse collapse">
|
||||||
<ul class="nav navbar-nav navbar-right">
|
<ul class="nav navbar-nav navbar-right">
|
||||||
<li><a href="/">home</a></li>
|
<li><a href="/wiki/"><i class="fa fa-edit"></i> wiki</a></li>
|
||||||
<li><a href="/wiki/">wiki</a></li>
|
<li><a href="https://quotes.tilde.chat/"><i class="fa fa-comment"></i> qdb</a></li>
|
||||||
<li class="dropdown">
|
<li><a href="https://web.tilde.chat/"><i class="fa fa-comments-o"></i> webchat</a></li>
|
||||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">~chat pages <span class="caret"></span></a>
|
<li><a href="/stats/"><i class="fa fa-bar-chart"></i> stats</a></li>
|
||||||
<ul class="dropdown-menu" role="menu">
|
<li><a href="/badges/"><i class="fa fa-shield"></i> badges</a></li>
|
||||||
<li><a href="https://quotes.tilde.chat/"><i class="fa fa-comment"></i> ~chat qdb</a></li>
|
|
||||||
<li><a href="https://web.tilde.chat/"><i class="fa fa-comments-o"></i> ~webchat</a></li>
|
|
||||||
<li><a href="https://tilde.chat/stats/"><i class="fa fa-bar-chart"></i> network stats</a></li>
|
|
||||||
<li><a href="https://tilde.chat/badges/"><i class="fa fa-shield"></i> status badges</a></li>
|
|
||||||
</ul>
|
|
||||||
</li>
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
<?php
|
<?php
|
||||||
require __DIR__.'/../vendor/autoload.php';
|
require __DIR__.'/../vendor/autoload.php';
|
||||||
|
|
||||||
|
use Tildeverse\Wiki\Parser;
|
||||||
|
|
||||||
$additional_head = "
|
$additional_head = "
|
||||||
<style>
|
<style>
|
||||||
:target:before {
|
:target:before {
|
||||||
@ -14,21 +16,7 @@ $additional_head = "
|
|||||||
<meta property='og:site_name' content='tilde.chat wiki'>
|
<meta property='og:site_name' content='tilde.chat wiki'>
|
||||||
";
|
";
|
||||||
|
|
||||||
class MDParser implements Mni\FrontYAML\Markdown\MarkdownParser {
|
$parser = Parser::factory();
|
||||||
public function __construct() {
|
|
||||||
$this->mdparser = new Michelf\MarkdownExtra();
|
|
||||||
$this->mdparser->header_id_func = function ($header) {
|
|
||||||
return preg_replace('/[^a-z0-9]/', '-', strtolower($header));
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
public function parse($markdown) {
|
|
||||||
return $this->mdparser->transform($markdown);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$parser = new Mni\FrontYAML\Parser(null, new MDParser());
|
|
||||||
|
|
||||||
|
|
||||||
if (!isset($_GET["page"]) || !file_exists("pages/{$_GET['page']}.md")) {
|
if (!isset($_GET["page"]) || !file_exists("pages/{$_GET['page']}.md")) {
|
||||||
|
|
||||||
@ -76,7 +64,7 @@ if (!isset($_GET["page"]) || !file_exists("pages/{$_GET['page']}.md")) {
|
|||||||
<a href=".">< ~wiki</a>
|
<a href=".">< ~wiki</a>
|
||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
<?=str_replace("<table", '<table class="table table-striped"', $pg->getContent())?>
|
<?=$pg->getContent()?>
|
||||||
<hr>
|
<hr>
|
||||||
<a href="https://tildegit.org/tildeverse/tilde.chat/src/branch/master/wiki/pages/<?=$_GET["page"]?>.md">
|
<a href="https://tildegit.org/tildeverse/tilde.chat/src/branch/master/wiki/pages/<?=$_GET["page"]?>.md">
|
||||||
<i class="fa fa-edit"></i> source
|
<i class="fa fa-edit"></i> source
|
||||||
|
Loading…
Reference in New Issue
Block a user