Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env python
from __future__ import print_function
import sys
import platform
import os.path
import os
import subprocess
from distutils import spawn
@myyc
myyc / .zshrc
Last active December 22, 2019 12:09
source ~/.zplug/init.zsh
zplug "lib/git", from:oh-my-zsh
zplug "lib/history", from:oh-my-zsh
zplug "plugins/colored-man-pages", from:oh-my-zsh, defer:2
zplug "zsh-users/zsh-history-substring-search", defer:2
zplug "zsh-users/zsh-syntax-highlighting", defer:2
zplug "zsh-users/zsh-autosuggestions", defer:2
# remap prefix to Control + a
set -g prefix C-a
unbind C-b
bind C-a send-prefix
# force a reload of the config file
unbind r
bind r source-file ~/.tmux.conf
unbind C-v
PROMPT='%{$fg[magenta]%}★ %B%c%b $(git_prompt_info)% %{$fg[white]%}> %{$reset_color%}'
ZSH_THEME_GIT_PROMPT_PREFIX="%{$fg[blue]%}#%{$fg[red]%}"
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$fg[green]%} "
@myyc
myyc / my.emacs
Last active August 29, 2015 13:57
(global-linum-mode t)
(setq prelude-guru nil)
(setq mac-option-modifier 'nil)
(setq mac-right-option-modifier 'nil)
(setq mac-right-command-modifier 'meta)
(define-key smartparens-mode-map (kbd "C-<left>") 'backward-word)
(define-key smartparens-mode-map (kbd "C-<right>") 'forward-word)
module RndCrap where
import System.Random
import qualified Data.Text as T
import qualified Data.Text.IO as TIO
boxm :: Float -> Float -> (Float, Float)
boxm u v = (r*cos(t), r*(sin(t)))
where r = sqrt (-2 * log u)
t = 2*pi*v