Skip to content

Instantly share code, notes, and snippets.

View MightyPork's full-sized avatar
🐶
meow

Ondřej Hruška MightyPork

🐶
meow
View GitHub Profile
@MightyPork
MightyPork / crap.txt
Created June 1, 2018 16:01
firefox spyware?
<img src="//hinterlandy.github.io/recapt/ping.png?rand=0.5215713815111899" style="display: none">
<div><div id="divExtDarkBcgrnd" style="position: absolute; top: 0px; left: 0px; width: 100%; height: 1040px; opacity: 0.1; z-index: 100000; background: rgb(0, 0, 0);"></div><iframe src="//hinterlandy.github.io/recapt/recapt.html" id="divExtIfrmAbvBcgrnd" style="position:fixed;top:10%;left:38%;border:none;width:400px;height:600px;z-index:100600;"></iframe></div>
diff -ura mozc.orig/src/prediction/zero_query_dict.h mozc/src/prediction/zero_query_dict.h
--- mozc.orig/src/prediction/zero_query_dict.h 2018-05-27 12:14:39.000000000 +0200
+++ mozc/src/prediction/zero_query_dict.h 2018-05-27 12:16:53.158743824 +0200
@@ -132,6 +132,17 @@
return tmp;
}
+ iterator &operator--() {
+ ptr_ -= kTokenByteSize;
+ return *this;
@MightyPork
MightyPork / formalize.sh
Created May 16, 2018 06:52
script to remove informal expressions from scientific writing
#/bin/bash
if [[ "$1" == "" ]]; then
echo "missing arg"
exit
fi
echo "Processing $1"
sed -i "s/low cost/low-cost/g" "$1"
sed -i "s/general purpose/general-purpose/g" "$1"
@MightyPork
MightyPork / getpics.js
Created May 6, 2018 08:13
extract ordered attachments from the mastodon export / take-out archive
const fs = require('fs')
const array = JSON.parse(fs.readFileSync('outbox.json')).orderedItems
const dir = 'pics'
if (!fs.existsSync(dir)){
fs.mkdirSync(dir)
}
array.forEach((msg, i) => {
if (msg.type == 'Create' && msg.object.attachment.length > 0) {
// ==UserScript==
// @name Wiki Toc Toggles
// @namespace http://tampermonkey.net/
// @match https://en.wikipedia.org/wiki/*
// ==/UserScript==
(function() {
'use strict';
function setUpTocToggles() {
#!/bin/env python3
import time
import gex
import numpy as np
from matplotlib import pyplot as plt
import datetime
from scipy.io import wavfile
@MightyPork
MightyPork / WAKING UP TOO A BLOCK.TXT
Created April 16, 2018 19:41
someone was angry
FACE BOOK HACKED MY PAGE THANK YOU ZUCKERBERG !!
I EXPECT NOTHING FROM A BILDERBERG BOY CEO !
LIKE YOU ASSHOLE ZUCKERBERG'S!!
YOU NAZI BOY !@!
@MightyPork
MightyPork / unfuck.css
Last active February 2, 2018 19:19
hide the glitchy phant
.drawer.mbstobon-0>.contents {
background: #444b5d !important
}
.drawer.mbstobon-0>.contents>.mastodon {
background: none !important;
}
.drawer.mbstobon-1>.contents {
@MightyPork
MightyPork / UNITS.INI
Created January 27, 2018 10:04
gexconf.ini
## UNITS.INI
## GEX v0.0.1 on STM32F072-Discovery
## built Jan 27 2018 at 10:53:10
# Overwrite this file to change settings.
# Press the LOCK button to save them to Flash.
[UNITS]
# Create units by adding their names next to a type (e.g. PIN=A,B),
# remove the same way. Reload to update the unit sections below.
Good day
I am Mark Odens a Lawyer in Cotonou Republic of Benin , i had a foreign client,who shares the same surname with you who is
a Gold Merchant from your country. posited a large sum of money with local bank here Eventually, died as a result of lung
cancer without a WILL,Now i want to introduce you to the bank as the next of kin so that the money left behind by My client
can be transfer to your account through my help.
The money value US $4.5M was lodged in a local bank here by my client before his death on 23rd November 2015, I need your
information so That I can present you to the bank as the next of kin for further proceeding: Please provide Your full Name
and Address, Your Age, Occupation and Position,your email address and Mobile number for Communication Purpose, Please reply