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
--[=[ | |
example: | |
#define mv{#} tonumber(%1)>0 and(">"):rep(%1)or("<"):rep(-(%1)) | |
#define add{#} "mv{%1}[-mv{-(%1)}+mv{%1}]mv{-(%1)}" | |
,>,>,<<add{2}add{1}. | |
preprocession: | |
,>,>,<<mv{2}[-mv{-2}+mv{2}]mv{-2}mv{1}[-mv{-1}+mv{1}]mv{-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
var code="\n\ | |
var btn=document.createElement('a')\n\ | |
document.getElementById('brush-2').parentNode.appendChild(btn)\n\ | |
btn.href='#'\n\ | |
btn.id='brush-flood'\n\ | |
btn.className='brushPicker'\n\ | |
btn.innerHTML=\"fill\"\n\ | |
btn.onclick=function(){drawApp.setSize('flood')}\n\ | |
var md=drawApp.onCanvasMouseDown()\n\ | |
// hey, that was clever, but unfortunately not enough\n\ |
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
return { | |
[0x000000]={0,0,0,0,0}, | |
[0xF97CBB]={4,0,2,0,3}, | |
[0xC3C3C3]={5,0,5,0,5}, | |
[0xEA4EFF]={9,0,1,2,9}, | |
[0xBBD0D0]={8,1,6,3,7}, | |
[0x7171FF]={2,0,2,0,6}, | |
[0x38C6FF]={2,0,4,3,9}, | |
[0xFF008A]={6,0,0,0,2}, | |
[0xC7FF7C]={6,2,6,3,2}, |
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
module Patterns | |
( | |
captures, match, residue, | |
maybeCaptures, maybeMatch, gsub, | |
capture, captureMap, captureGuard, captureEq, lookAhead, lookAheadNot, | |
attach, orElse, tryOne, greedySome, lazySome, greedyMany, lazyMany, | |
times, | |
always, never, end, anything, value, notValue, range, anyOf, noneOf, lambda, | |
list, balanced, | |
numeric, hexadecimal, lowercase, uppercase, alpha, alphanumeric, ascii, |
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
#include <stdlib.h> | |
#include <unistd.h> | |
#include <string.h> | |
#include <stdio.h> | |
#include <stdint.h> | |
#include <stddef.h> | |
#include <signal.h> | |
#include <limits.h> | |
#include <errno.h> | |
#include <pthread.h> |
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
// extern void md5(char *digest, const char *data, size_t length) | |
.global md5 | |
.type md5 @function | |
md5: | |
pushq %rbx | |
pushq %r12 | |
pushq %r13 | |
pushq %r14 | |
pushq %r15 | |
push %rbp |
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
# extern void block_round_8(const unsigned int (*data)[8]); | |
# __m256i A register("ymm0"); | |
# __m256i B register("ymm1"); | |
# __m256i C register("ymm2"); | |
# __m256i D register("ymm3"); | |
.global block_round_8 | |
.type block_round_8 @function | |
block_round_8: | |
pushq %rbp | |
movq %rsp, %rbp |
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
#!/bin/bash | |
# Ever wanted to spawn a process in X from a VT? | |
# This little tool spawns a shell whose environment is copied from a specified PID. | |
# Example: ./copyenv.sh $(pidof mate-session) | |
# That will launch a shell with $DISPLAY, $XAUTORITY, and others set to appropriate values and thus you'll be able to spawn your process | |
xargs -0 -a <(cat "/proc/$1/environ";echo -n $SHELL;echo -ne "\0-i") env |
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
use strict; | |
use Coro; | |
use Xchat; | |
Xchat::register("op helper", "0.0"); | |
{ | |
package Promise; |
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
if [ $EUID != 0 ]; then | |
su -c $0 | |
exit | |
fi | |
for i in /tmp/.X11-unix/X*; do | |
ln -f $i $(sed 's:^/::' <<< "$i") | |
done | |
xauth extract - $DISPLAY | xauth -f root/.Xauthority merge - | |
export XAUTHORITY=/root/.Xauthority |
OlderNewer