Skip to content

Instantly share code, notes, and snippets.

View hugovk's full-sized avatar

Hugo van Kemenade hugovk

View GitHub Profile
@hugovk
hugovk / README.md
Last active August 29, 2015 14:21
Cutthroat verb-nouns

Cutthroat verb-nouns

David-Antoine Williams writes:

What is the difference between a catch-all and a catch-phrase? Both are compounds formed as Verb+Noun, but in catch-all, the noun is the direct object of the verb, whereas in catch-phrase it is the subject. That is, a catch-all is something that catches all things, whereas a catch-phrase is not something that catches phrases – it is a phrase that catches something. Get it?

Recently there has been some discussion of catch-all type compounds, which Brianne Hughes has named “cutthroat compounds,” after one of the more suggestive of these. Apparently they’re rare, because they violate a general tendency for compounds in English to put the ‘head’ (e.g. phrase) on the right (‘right-headedness’). Compare F. ouvre-bouteille to E. bottle-opener (not open-bo

@hugovk
hugovk / minitest.py
Last active August 29, 2015 14:22
Attempt to download another user's Wordnik list
#!/usr/bin/env python
# encoding: utf-8
from wordnik import swagger, AccountApi, WordListApi
WORDNIK_USERNAME = TODO
WORDNIK_PASSWORD = TODO
WORDNIK_API_KEY = TODO
permalink = "gapeseeds-and-muckworms---compound-derogatives"
@hugovk
hugovk / Vagrantfile
Created June 1, 2015 07:39
A Drupal Vagrantfile
# -*- mode: ruby -*-
# vi: set ft=ruby :
hostname = 'myvagrant'
domain = 'example.com'
ip = '192.168.54.5'
#forwarded_port = 8080
cpus = 2
ram = 2048
@hugovk
hugovk / HOLD-DOOR-1801.jpg
Last active August 29, 2015 14:22
Cutthroats: A supplement to Johnson's English dictionary (1801)
HOLD-DOOR-1801.jpg
@hugovk
hugovk / todayschallenge.py
Created September 3, 2015 05:40
Convert the letters of your full name into numbers, add them together, & determine the prime factorization of the sum
#!/usr/bin/env python
# encoding: utf-8
"""
Today's challenge:
Convert the letters of your full name into numbers, add them together,
& determine the prime factorization of the sum
https://twitter.com/todayschallenge/status/638713672278351875
https://twitter.com/todayschallenge/status/639075809060356096
"""
@hugovk
hugovk / schbot_trends.txt
Last active November 30, 2015 18:16
UK and US Twitter trends from 26 Jan - 30 Nov 2015, one logged per hour (except the first few include World, France and Sweden WOEIDs) by https://twitter.com/botschmot
@hugovk
hugovk / tweetables.py
Created December 17, 2015 08:28
Split a text into sentences shorter than 140 characters.
#!/usr/bin/env python
# encoding: utf-8
"""
Split a text into sentences shorter than 140 characters.
You'll need to first install TextBlob by running:
pip install -U textblob
Then stick your text into the text bit below and run this script:
python tweetables.py
@hugovk
hugovk / pilgrims-progress-capped-hyphenated-edited.txt
Last active February 25, 2016 09:10
The Pilgrim's Cutthroats: potential cutthroat compounds found in the complete works of John Bunyan, including The Pilgrim's Progress
The Pilgrim's Cutthroats: potential cutthroat compounds found in the complete works of John Bunyan, including The Pilgrim's Progress
Source: https://www.gutenberg.org/ebooks/6049
Clip-promise, "a notorious villain"
Mr. Dam-man, commissioner, trier, high Calvinist, immoral in conduct
Mr. Forget-good, "He could remember nothing but mischief, and to do it with delight."
Mr. Fri-babe, "free-babe"?, commissioner, trier, high Calvinist, immoral in conduct
Lord Hate-good, a judge
Mr. Hate-light, a juror
@hugovk
hugovk / twitter_archiver.py
Created May 11, 2016 07:06 — forked from jehiah/twitter_archiver.py
python script to archive your tweets
#!/usr/bin/env python
"""
twitter_archiver.py written by Jehiah Czebotar 2010 <jehiah@gmail.com> http://jehiah.cz/
this uses the great 'python twitter tools' library by Mike Verdone
http://mike.verdone.ca/twitter/
usage:
$ pip install twitter
@hugovk
hugovk / StartPoll.py
Created June 9, 2016 06:48
Twitterの投票機能 投票を発行(対策された?, あとで修正します)
def StartPoll():
from requests_oauthlib import OAuth1Session
#端末向けの公式アプリ系のCK/CSじゃないとダメ(デフォルトでTwitter for iPhone)
CK = 'IQKbtAYlXLripLGPWd0HUA'
CS = 'GgDYlkSvaPxGxC4X8liwpUoqKwwr3lCADbz8A7ADU'
AT = ''
AS = ''
auth = OAuth1Session(CK, CS, AT, AS)