Skip to content

Instantly share code, notes, and snippets.

View xbeta's full-sized avatar
🏠
Working from home

Sam Xiao xbeta

🏠
Working from home
  • San Francisco, CA
  • 11:10 (UTC -07:00)
  • LinkedIn in/samxsxiao
View GitHub Profile
@xbeta
xbeta / How to Get Into Y Combinator.md
Last active August 29, 2015 14:07
How to Get Into Y Combinator

How to Get Into Y Combinator

original : https://www.aptible.com/blog/y_combinator.html

Chas Ballew

18 SEPTEMBER 2014 Having just come through Y Combinator, we frequently get asked whether it was worth it. The answer is absolutely yes, no hesitation. While the experience is still fresh, I want to encourage you to apply for the next cycle and give some advice for getting in.

Apply Now

@xbeta
xbeta / Schumpeter - Entrepreneurs anonymous.md
Last active August 29, 2015 14:07
Schumpeter - Entrepreneurs anonymous

Schumpeter Entrepreneurs anonymous

Instead of romanticising entrepreneurs people should understand how hard their lives can be

Sep 20th 2014 | From the print edition

SEVEN years ago Joe Jones (not his real name) left his job with a big NASDAQ-listed company to strike out on his own. He was sick of corporate life and he wanted to test his inner mettle. But being an entrepreneur proved far harder than he had imagined: a succession of potholes, speed bumps and dead-ends rather than a high road to prosperity. He found he had “lost his levers of control”: all the things his former employer had provided for him, from administrative support to a social network. He had to learn how to do all sorts of things he had not thought about before. The responsibility of meeting his payroll was “overwhelming”. The worry about every detail of his life—could he afford to keep his car, or pay the mortgage on his house?—was all-consuming. He took to drinking. Mr Jones eventually joined Alcoholics Anonymous and turned h

@xbeta
xbeta / README.md
Last active May 8, 2025 19:40
Macbook Pro Bluetooth + WiFi 2.4GHz interference fix for Mavericks
@xbeta
xbeta / install.sh
Last active August 29, 2015 14:06
tmux + iTerm2 integration
# install tmux 1.8+
# on OSX, use iTerm2 and follow this guide: http://www.railsonmaui.com/blog/2014/03/11/rocking-with-tmux-tmuxinator-and-iterm2-for-rails-development/
#
ssh login@hostname -t 'tmux -CC attach || tmux -CC'
# Fixing clipboard on OSX
brew install reattach-to-user-namespace --wrap-pbcopy-and-pbpaste
# Boost Productivity with tmux and iTerm2 workspace
# http://www.huyng.com/posts/productivity-boost-with-tmux-iterm2-workspaces/
@xbeta
xbeta / Using_PSSH
Last active August 29, 2015 14:03
How to use PSSH
$ pssh --inline -h address.txt -p 5 -t 30 -x "-T -O StrictHostKeyChecking=no" -I < tasks.sh
-p : number of max concurrent connections
-t : timeout limit
-h : host files
-x : extra SSH binding arguments
--inline : display stdout and stderr as each host completes
-I : read input and send to each ssh process, used with command scripts
#!/bin/sh
PORT=4200
sudo launchctl unload /Library/LaunchDaemons/com.crashplan.engine.plist
sudo sed -i '' "s/\(<servicePort>\)[^<]*/\1$PORT/" /Library/Application\ Support/CrashPlan/conf/my.service.xml
sed -i '' "s/#*\(servicePort=\).*/\1$PORT/" /Applications/CrashPlan.app/Contents/Resources/Java/conf/ui.properties
defaults write /Applications/CrashPlan.app/Contents/Resources/CrashPlan\ menu\ bar.app/Contents/Info CPPort $PORT
sudo launchctl load /Library/LaunchDaemons/com.crashplan.engine.plist

Keybase proof

I hereby claim:

  • I am xbeta on github.
  • I am samxiao (https://keybase.io/samxiao) on keybase.
  • I have a public key whose fingerprint is 8B7E E725 CAB8 A94B 2141 96FB 0F63 1E71 7A82 FE4C

To claim this, I am signing this object:

defmodule SecureRandom do
@moduledoc """
Ruby-like SecureRandom module.
## Examples
iex> SecureRandom.base64
"xhTcitKZI8YiLGzUNLD+HQ=="
iex> SecureRandom.urlsafe_base64(4)
$ brew install redis
$ redis-server