This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<PremiereData Version="3"> | |
<Tree ObjectRef="1"/> | |
<Tree ObjectID="1" ClassID="177f2841-dd5b-43bd-9d9a-79e231bd47dd" Version="1"> | |
<RootBin ObjectRef="2"/> | |
<Node Version="1"> | |
</Node> | |
</Tree> | |
<BinTreeItem ObjectID="2" ClassID="5e0f46fa-384f-4c09-bc53-0b8e2b7005b5" Version="4"> | |
<TreeItemBase Version="4"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Bittorrent Tracker | |
[Service] | |
ExecStart=bittorrent-tracker -qsp 6969 | |
Restart=always | |
RestartSec=10 | |
StandardOutput=syslog | |
StandardError=syslog | |
SyslogIdentifier=bittorrent-tracker |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extra-keys = [ \ | |
[ \ | |
{ key: ESC, popup: '&' }, \ | |
{ key: '/', popup: '~' }, \ | |
{ key: '-', popup: '|' }, \ | |
{ key: HOME, popup: '[' }, \ | |
{ key: UP, popup: ':' }, \ | |
{ key: END, popup: ']' }, \ | |
{ key: PGUP, popup: '&' } \ | |
], \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function ytbdl() { | |
until youtube-dl $@; | |
} | |
# usage: | |
# $ ytbdl [...targets] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* the minimal router - mrt.php | @jamesliu96 | GPL */ | |
$path = urldecode(parse_url(preg_replace('/\/+/', '/', $_SERVER['REQUEST_URI']), PHP_URL_PATH)); | |
function route(string $rule, callable $callback) | |
{ | |
global $path; | |
if ($path === $rule) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
define('OTP_LEN', 6); | |
define('OTP_INT', 30); | |
define('OTP_WIN', 4); | |
function hotp(string $key, int $counter, $len = OTP_LEN) | |
{ | |
static $alphabet = [ | |
'A' => 0, 'B' => 1, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isArrowFunction(f) { return typeof f === 'function' && typeof f.prototype === 'undefined' } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
play_youtube() { | |
G=(`youtube-dl -g $1`) | |
echo ${G[1]} | |
echo ${G[2]} | |
ffmpeg -i ${G[1]} -i ${G[2]} -c:v copy -c:a copy -f matroska - | ffplay - | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"image" | |
"image/draw" | |
"image/png" | |
"math/rand" | |
"os" | |
"runtime" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var __s = document.createElement('style'); __s.type = 'text/css'; __s.innerText = `body, #app { | |
background-color: #121212 !important; | |
color: #666666 !important; | |
} | |
.bilibili-player { | |
box-shadow: 0 0 8px #080808 !important; | |
} | |
.nav-mask { | |
background-color: #222222 !important; | |
} |