Skip to content

Instantly share code, notes, and snippets.

View zephoon's full-sized avatar
🎯
Focusing

ZefengYu zephoon

🎯
Focusing
View GitHub Profile
@wonderbeyond
wonderbeyond / Dockerfile
Last active August 14, 2019 13:08
Dockerfile: python3+pipenv+sanic+gunicorn
FROM python:3.6
RUN /bin/echo -e \
"deb http://mirrors.aliyun.com/debian/ jessie main non-free contrib\n"\
"deb http://mirrors.aliyun.com/debian/ jessie-proposed-updates main non-free contrib\n"\
"deb-src http://mirrors.aliyun.com/debian/ jessie main non-free contrib\n"\
"deb-src http://mirrors.aliyun.com/debian/ jessie-proposed-updates main non-free contrib\n"\
> /etc/apt/sources.list
# build deps
@geoffreydhuyvetters
geoffreydhuyvetters / react_fiber.md
Last active August 15, 2024 15:17
What is React Fiber? And how can I try it out today?
//
// SimpleScrollingStack.swift
// A super-simple demo of a scrolling UIStackView in iOS 9
//
// Created by Paul Hudson on 10/06/2015.
// Learn Swift at www.hackingwithswift.com
// @twostraws
//
import UIKit
@KhepryQuixote
KhepryQuixote / PyPubChemXtractor.py
Last active November 17, 2023 09:53
Python 3 script to extract Chemical Abstract Society Registry Numbers (CASRNs) from PubChem's CID Synonym file.
# -*- coding: utf-8 -*-
'''
Name: PyPubChemXtractor.py
Author: Khepry Quixote
Date: 11 Nov 2014
Language: Python 3.4
Narrative:
This Python 3.4 program will extract CASRN values from PubChem's
@KhepryQuixote
KhepryQuixote / PyTorStemPrivoxy.md
Last active September 9, 2023 20:36
Python script to connect to Tor via Stem and Privoxy, requesting a new connection (hence a new IP as well) as desired.

Crawling Anonymously with Tor in Python

adapted from the article "Crawling anonymously with Tor in Python" by S. Acharya, Nov 2, 2013.

The most common use-case is to be able to hide one's identity using TOR or being able to change identities programmatically, for example when you are crawling a website like Google and you don’t want to be rate-limited or blocked via IP address.

Tor

Install Tor.

import Foundation
extension String
{
var length: Int {
get {
return countElements(self)
}
}
@patrickhammond
patrickhammond / android_instructions.md
Last active December 25, 2024 17:03
Easily setup an Android development environment on a Mac

Here is a high level overview for what you need to do to get most of an Android environment setup and maintained.

Prerequisites (for Homebrew at a minimum, lots of other tools need these too):

  • XCode is installed (via the App Store)
  • XCode command line tools are installed (xcode-select --install will prompt up a dialog)
  • Java

Install Homebrew:

ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)"