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 <stdbool.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
int chday(int day, int month, int year); | |
int chmonth(int month); | |
int chyear(int year); | |
int leapYear(int y); | |
int day_of_year(int d, int m, int y); | |
int chday(int day, int month, int year) { |
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
//ref: http://andrewhfarmer.com/hide-discord-sidebar/ | |
var cmd$ = $; | |
document.addEventListener('keydown', function(event) { | |
if (event.metaKey && event.keyCode === 220) { | |
// Toggle visibility of the channel and guilds columns | |
var channelWrap = cmd$('.flex-vertical.channels-wrap'); | |
var guildsWrap = cmd$('.guilds-wrapper'); | |
var titleWrap = cmd$('.title-wrap'); | |
if (channelWrap.getAttribute('style') === 'display: none') { | |
channelWrap.setAttribute('style', ''); |
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
for l in __import__('fileinput').input():print(*[((c,chr(ord(c)+65248))[ord(c)<127]," ")[c==" "]for c in l[:-1]],sep='') |
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/sh | |
# Requires node.js: sudo pacman -Sy nodejs | |
if [ $# -lt 1 ]; then | |
echo "Usage: $(basename "$0") FILE [FILE...]" >&2 | |
exit 1 | |
fi | |
for f in "$@"; do | |
d=$(node -pe "JSON.parse(process.argv[1]).files[0].url" "$(curl -sS --progress-bar -F "files[]=@$f" http://pomf.se/upload.php)") |