Skip to content

Instantly share code, notes, and snippets.


arief nur andono goldalworming

View GitHub Profile
import speech_recognition
import pyttsx
speech_engine = pyttsx.init('sapi5') # see
speech_engine.setProperty('rate', 150)
def speak(text):
sveetch / casperjs_authenticator.js
Created Jan 19, 2016
CasperJS script to authenticate and store persistent cookie through profile for SlimerJS
View casperjs_authenticator.js
* This is a CasperJS script.
* It try to authenticate so the session cookie can be stored in current profile
* and then BackstopJS+CasperJS+SlimerJS can use the same cookie during tests.
* Scenario
* ========
kosiara / setup_howto.txt
Last active Apr 21, 2017
Setup Facebook React-native sample (empty) project on Ubuntu
View setup_howto.txt
# author:
# @Bartosz Kosarzycki
sudo apt-get install npm
sudo npm install -g react-native-cli
sudo ln -s /usr/bin/nodejs /usr/bin/node
cd /home/user/your/project/path
react-native init AwesomeProject
cd AwesomeProject
paulirish /
Last active Oct 9, 2020
How to view-source of a Chrome extension

Option 1: Command-line download extension as zip and extract

extension_id=jifpbeccnghkjeaalbbjmodiffmgedin   # change this ID
curl -L -o "$" "$extension_id%26uc" 
unzip -d "$extension_id-source" "$"

Thx to crxviewer for the magic download URL.

harlow /
Last active Oct 6, 2020
Job queues in Golang
sergiotapia / md5-example.go
Last active Sep 22, 2020
Golang - How to hash a string using MD5.
View md5-example.go
import (
func GetMD5Hash(text string) string {
hasher := md5.New()
return hex.EncodeToString(hasher.Sum(nil))

API workthough

  1. Open a browser

    # start an instance of firefox with selenium-webdriver
    driver = Selenium::WebDriver.for :firefox
    # :chrome -> chrome
    # :ie     -> iexplore
  • Go to a specified URL
chrishamant /
Created Jan 3, 2012
Example of Parallelized Multipart upload using boto
#!/usr/bin/env python
"""Split large file into multiple pieces for upload to S3.
S3 only supports 5Gb files for uploading directly, so for larger CloudBioLinux
box images we need to use boto's multipart file support.
This parallelizes the task over available cores using multiprocessing.
Usage: <file_to_transfer> <bucket_name> [<s3_key_name>]
nephics /
Created Aug 9, 2011
Test of experimental Tornado feature for a streaming request body handler
# Test of experimental Tornado feature for a streaming request body handler, see
# Client sending file to server
import tornado.httpclient as httpclient
karmi /
Created Dec 7, 2010
Desigining "trending topics in 24 hours sliding window" with Redis
# ------------------------------------------------------------------
# Desigining "trending topics in 24 hours sliding window" with Redis
# ------------------------------------------------------------------
redis-cli del tophashes:2010-12-07-08-00
redis-cli del tophashes:2010-12-07-09-00
redis-cli del tophashes:current
echo '=== 8:00 AM ==='
You can’t perform that action at this time.