This file contains 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 python3 | |
"""Obtain a Facebook Access Token | |
From: https://github.com/dequis/purple-facebook/issues/445#issuecomment-967542766 | |
Changes: | |
- Ported to Python3 | |
- Auto generate the MACHINE_ID UUID | |
- Can set EMAIL from environment variable |
This file contains 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
/* | |
* Reliably write data to named pipe, udp style. | |
* | |
* Compile: | |
* cc npcat.c -o npcat | |
* | |
* Test npcat without reader: | |
* mkfifo kk | |
* dd if=/dev/random bs=1k count=1k | npcat kk 2>/dev/null | |
* |
This file contains 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
#!/bin/sh | |
MVIM_DIR="/Applications/MacVim.app/Contents/bin" | |
DEST_DIR="$HOME/.local/bin" | |
mkdir -p "$DEST_DIR" | |
( | |
cd "$MVIM_DIR" || { | |
echo "Cannot change to dir $MVIM_DIR" | |
exit 2 |
This file contains 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
In [93]: import os | |
In [94]: fd = os.open('fifo', os.O_RDONLY | os.O_NONBLOCK) | |
In [95]: f = os.fdopen(fd, 'rb') | |
In [96]: import select | |
In [97]: | |
...: while True: |
This file contains 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
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDlHZdV4yo/DXce1SB0vy6dUpLE+hZcbn3PegG79Lztkiwk4CPYTwKukl+RvD6jfCLKDMgKw4wC3c+EkDL1UHsCG6XCUCzEr6XZUlzwsfGbcqft2neg2xAcGywAR/BU0iJ4dE8wYM5cA+asiU+POixSLv+WiLnblxBjS1CNCnOcZCeA8Os6IbXKvJPnLc2dTXXuk+A4qALFCEp8PCwGvw7gJG9GC5+ZmyqQawFmEAy/8YrOFrcpdypsdOZKr39C/red1WYk74dmyL0T+s0aq1abvgDuvn2SindjXtkIKIysdmFXfWOmKPHNlqjuKzj42NkOCgIUjrAJ9OR+wnOvsaqwgCswJy0yeb9UHWQsbi9EKjWgRjgSpwvFGj4MfzntueaW7jpcVrYf7ZCOlC8SnlqzPE/9y1FcYdajYDAMbE9U+RRndaK2aowVa42wtd+boiB3z7pCdL30cGCLXgDgfQlHfQryoHNzTKf1/h5T28Yev5kZS1nvMwaVRW6mvlIKros= mac | |
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDdIYX93EEMsdOrRFdh+IqFhEPRiAnZA0b0vrLZ2ftxMGpTvbHSpg3e6+JfRCI/bCyusLJi2MjjHUtocuJrbhz5PBZ+hrQHHSI6Qch32IWsSnYlCb5meIC6s4AAQwECLCKOoHBKpqCEEgwP+Cwk1Cxrpg40BHpm23G+c15U1sBDP250y/FecoPms7sPICI+mzepPhbj99nAP2Jut55U7EbBtGM5OjBO8WFt8SJXjTvp57O+EC90PVQ3tKA5NIuOwp8U+tU9a1ME+9sMt4Yb9uYmQAGCyAq1J0kbHWxGC6si00S10LEJeiRhxkMFsva5QZlwFxdwL5UF1hhwtNhu+8u7 S | |
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDDrrjp8ZFSK6Hq4a8Q3tNQ30llvr+7NLWfnt1QOCAmZH+y |
This file contains 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
#!/bin/bash | |
PYCHARM_INSTALL_DIR="$HOME/local/pycharm/pycharm-community-2019.1.3" | |
http_proxy=fwdproxy:8080 https_proxy=fwdproxy:8080 wget -O /tmp/pycharm.tar.gz https://download.jetbrains.com/python/pycharm-community-2019.1.3.tar.gz | |
mkdir -p ~/local/pycharm | |
tar xzf /tmp/pycharm.tar.gz -C ~/local/pycharm | |
cd "$PYCHARM_INSTALL_DIR/bin" |
This file contains 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 logging | |
import urllib2 | |
import re | |
from contextlib import closing | |
def get_ip(url = "http://checkip.dyndns.org/"): | |
'''Get local machine (or router)'s external IP from a IP checking web | |
service. | |
url: the URL of the IP checking service. Default to |
This file contains 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
hQEMA+G25aaiqKwyAQf/UGHSm7hkA19eQbgESInCniq5Wesc1flXWacmB++3i5HQSrBWL4Bg/0nM | |
9tD41llLWzMr0PhBW6F8ThWmgh0QO9v3y9Dltx9BLXCYdqBBliPJgsWsYg2ML2yMEzNy2ns9gpdV | |
uU6k/YOPLGuKf1tPpv0TiWVekjccr5vinUvAu0DGgRBc3Gd0FtSLeulXZkfIXsS08YtSp++G6gg0 | |
lKRN4JxO5Q0OixQFe6+bRbIc7RI50iPPLIhWpQvubv/dTFJVIiwNe8aKsY+ymIneLRWDLz5h5DZ8 | |
HVFUotneXJKuzy1Xa4ltRPTF9BB5aJP1ny/3BRkFYnon8gLtwKqQgo9KHtJHARjSP3mmiHMJfutZ | |
zpd87AKcWhUrDtSGUG9bfX0SGyeAnaaEBo2p/mnOujLrcECjir2hkF3g3/sBZkXw/qk/eNJ/mL5u | |
cT4= |
This file contains 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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using System.Reflection; | |
using System.Linq.Expressions; | |
using System.Reflection.Emit; | |
using System.IO; |
This file contains 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
/* ~/Library/KeyBindings/DefaultKeyBinding.Dict | |
This file remaps the key bindings of a single user on Mac OS X 10.5 to more closely | |
match default behavior on Windows systems. This particular mapping assumes | |
that you have also switched the Control and Command keys already. | |
This key mapping is more appropriate after switching Ctrl for Command in this menu: | |
Apple->System Preferences->Keyboard & Mouse->Keyboard->Modifier Keys...-> | |
Change Control Key to Command | |
Change Command key to Control |
NewerOlder