This file contains hidden or 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
def insert_comma(mystring, position): | |
mystring[:position] + ',' + mystring[position:] | |
offset = 0 | |
for magic_number in magic_numbers: | |
position = magic_number + offset | |
mystring = insert_comma(mystring, position) | |
offset += 1 |
This file contains hidden or 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
import os, sys, re, subprocess | |
tsfile = 'raws.txt' | |
# create the Timestamps (tsfile) using grep and Sublime Text or whatever you want | |
# it should contain the episode name/video file + the timestamp, for example: | |
# | |
# Seinfeld.S03E15.The.Suicide.720p.HULU.WEBRip.AAC2.0.H.264-NTb.srt-00:14:25,242 --> 00:14:27,775 | |
# Seinfeld.S03E17.The.Boyfriend.720p.HULU.WEBRip.AAC2.0.H.264-NTb.srt-00:12:34,738 --> 00:12:36,639 | |
# S03E18-00:12:34,768 --> 00:12:36,639 | |
# ... |
This file contains hidden or 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
sudo apt-get update | |
sudo apt-get install \ | |
python-dev \ | |
python-pip \ | |
python-virtualenv | |
virtualenv findbots | |
source findbots/bin/activate | |
curl -O http://geolite.maxmind.com/download/geoip/database/GeoLite2-City.mmdb.gz |
This file contains hidden or 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
{ | |
"contributors": null, | |
"text": "ツイッター動画投稿テスト http://t.co/y9hjEfABw1", | |
"geo": null, | |
"retweeted": false, | |
"in_reply_to_screen_name": null, | |
"possibly_sensitive": false, | |
"truncated": false, | |
"lang": "ja", | |
"entities": { |
This file contains hidden or 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
// Inject css rules in Cryptocat conversation for a full width display | |
// Also add a "body click to text focus" action (using jQuery, already embedded in Cryptocat) | |
// Note: Only tested on IE 6 ! (Ok, I'm kidding, only Chrome) | |
// Author : Cyril N. | |
(function (){ | |
var newcss = "#userInput>#userInputText {width : 84%;} body>div#bubble {width : auto; margin : 0 auto; position : absolute; top : 0; bottom : 0; left : 0; right : 0; height : auto; border-radius: 0}"; | |
newcss += "div#conversationWindow .line1, div#conversationWindow .line2, div#conversationWindow .line3, div#conversationWindow .line4 {max-width : 96%;}"; | |
newcss += "div#buddyWrapper {width : 14%;}"; |
This file contains hidden or 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
This is free and unencumbered software released into the public domain. | |
Anyone is free to copy, modify, publish, use, compile, sell, or | |
distribute this software, either in source code form or as a compiled | |
binary, for any purpose, commercial or non-commercial, and by any | |
means. | |
In jurisdictions that recognize copyright laws, the author or authors | |
of this software dedicate any and all copyright interest in the | |
software to the public domain. We make this dedication for the benefit |
This file contains hidden or 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
#!/usr/bin/env python | |
# requires python >= 2.7 | |
# see: https://pypi.python.org/pypi/ordereddict | |
from collections import OrderedDict | |
MAXLRU = 200 | |
class LRU(OrderedDict): | |
def __init__(self, *args, **kwds): |
This file contains hidden or 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
This playbook has been removed as it is now very outdated. |
This file contains hidden or 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
#!/usr/bin/env bash | |
# bash 4.1.5(1) Linux Ubuntu 10.04 Date : 2012-02-17 | |
# | |
# _______________| digy : tame DNS utility dig with reasonable options. | |
# | |
# Usage: digy [address] [rev|name|short|mail|all|long|longa|who] | |
# | |
# Examples: % digy friendfeed.com | |
# 69.63.180.52 | |
# # default second argument is 'short' |
This file contains hidden or 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
--- | |
layout: default | |
--- | |
<div class="blog-index"> | |
{% assign post = site.posts.first %} | |
{% assign content = post.content %} | |
{% include post_detail.html %} | |
</div> |
NewerOlder