Skip to content

Instantly share code, notes, and snippets.

View jnv's full-sized avatar

Jan Vlnas jnv

View GitHub Profile
@jnv
jnv / index.js
Created August 27, 2016 08:27
SMS forwarder for broken Arduino Uno WiFi Ciao library
'use strict'
const http = require('http')
const server = http.createServer().listen(process.env.PORT || 3000)
const url = require('url')
const TWILIO_SID = ''
const TWILIO_TOKEN = ''
const TEL_FROM = ''
const TEL_TO = ''
@jnv
jnv / README.markdown
Last active January 7, 2016 11:07 — forked from karmi/README.markdown
NYT ISIS Attacks Chart
@jnv
jnv / twitterdetox.user.js
Last active January 3, 2016 12:11
Remove stuff from twitter, like following/followers, retweets and likes count. https://greasyfork.org/en/scripts/4054-twitter-detox
// ==UserScript==
// @id twitter.com-0c8ee385-6991-418e-940e-106644506a90@scriptish
// @name Twitter Carefree
// @version 2016.01.03
// @namespace https://jnv.github.io
// @description Remove stuff from Twitter, like following/followers, retweets and likes count.
// @include https://twitter.com/*
// @include https://mobile.twitter.com/*
// @grant GM_addStyle
// @license CC0 1.0; https://creativecommons.org/publicdomain/zero/1.0/
@jnv
jnv / effective_tld_names.dat
Created December 23, 2013 22:01
Public Suffix List minus the private part
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
// ===BEGIN ICANN DOMAINS===
// ac : http://en.wikipedia.org/wiki/.ac
ac
com.ac
edu.ac
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jnv
jnv / 11a-dsl.ipynb
Last active December 29, 2015 23:59
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@jnv
jnv / dh-ngram-cloud.R
Created November 25, 2013 17:02
N-gramy do wordcloudu
# Podle https://gist.github.com/josefslerka/4148592
## Nacteni knihoven
library(textcat)
library(tau)
library(wordcloud)
## Vytvoreni korpusu
# Pro texty ve Windows kodovani pouzijte encoding="cp1250"
mujKorpus <- Corpus(DirSource("klaus", encoding="UTF-8"), readerControl = list(language = "cz"))
@jnv
jnv / rfacebook-wordcloud.R
Last active December 29, 2015 06:09
Načetní postů z facebooku, tokenizace, sestavení korpusu a vytvoření wordcloudu. Pro StuNoMe Digital Humanities
### Rfacebook
# Instalace knihovny - staci spustit jenom jednou
install.packages("Rfacebook")
# Nacteni knihovny
library(Rfacebook)
# Token ziskany z https://developers.facebook.com/tools/explorer
token <- "..."
@jnv
jnv / dropbox-thumbs-names.js
Created October 12, 2013 13:00
Get numerical filenames of pictures in Dropbox gallery (thumbnails view)
var thumbs = document.querySelectorAll("#gallery-view-media a[onclick^=Lightbox]");
var ids = [];
for (var i = 0; i < thumbs.length; ++i)
{
var item = thumbs[i];
var fname = item.href.split('/').pop();
var id = fname.match(/^\d+/)[0];
ids.push(id);
}
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.