waterloo3122 / open-source-docs

Apache License 2.0
0 stars 0 forks source link

hactonish related resoureces #82

Open waterloo3122 opened 5 years ago

waterloo3122 commented 5 years ago

brew

install

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

uninstall

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)"

brew install without update

HOMEBREW_NO_AUTO_UPDATE=1 brew install …

install zsh

brew install zsh
sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"

item2

brew cask install iterm2

wget http://ethanschoonover.com/solarized/files/solarized.zip

Command + ,
Profiles -> Colors -> Color Presets -> Import
solarized->iterm2-colors-solarized->Solarized Dark.itermcolors

change theme to agnoster

wget https://github.com/powerline/fonts/blob/master/Meslo%20Slashed/Meslo%20LG%20M%20Regular%20for%20Powerline.ttf change iterm font to Meslo LG M Regular for Powerline.ttf

brew install zsh-syntax-highlighting

vim ~/.zshrc 在最后一行增加下面配置: source /usr/local/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh

git clone https://github.com/zsh-users/zsh-autosuggestions ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions

vim ~/.zshrc plugins=(git zsh-autosuggestions zsh-syntax-highlighting)

Profiles -> Colors ->ANSI Colors->Bright->586e75

use command + . to hide or show iterm

iTerm2 配置代理
编辑~ vim ~/.zshrc,增加下面配置(使用的 shadowsocks):

# proxy list
alias proxy='export all_proxy=socks5://127.0.0.1:1080'
alias unproxy='unset all_proxy'

install emacs

install proxycap

install ShiftIt

install Dropbox

install sharemouse

clover

https://sourceforge.net/projects/cloverefiboot/files/latest/download

other stuff

brew install shadowsocks-libev brew cask install google-chrome brew cask install shiftit brew install tmux

set -s escape-time 0
unbind-key j
bind-key j select-pane -D
unbind-key k
bind-key k select-pane -U
unbind-key h
bind-key h select-pane -L
unbind-key l
bind-key l select-pane -R

bind -n M-k resize-pane -U 5
bind -n M-j resize-pane -D 5
bind -n M-h resize-pane -L 5
bind -n M-l resize-pane -R 5

添加id_rsa到mac的keychain

ssh-add -K ~/.ssh/[your-private-key] vim .ssh/config

Host *
  UseKeychain yes
  AddKeysToAgent yes
  IdentityFile ~/.ssh/id_rsa

chord 700 ~/.ssh chmod 600 ~/id_rsa

waterloo3122 commented 5 years ago

refer to zilongshanren's article

emacs

brew cask install emacs
brew tap caskroom/fonts
brew cask install font-source-code-pro
brew install grep 
brew install coreutils
cd ~
mv .emacs.d .emacs.d.bak
mv .emacs .emacs.bak

git clone https://github.com/syl20bnr/spacemacs ~/.emacs.d git clone https://github.com/waterloo3122/my_spacemacs_private.git ~/.spacemacs.d

waterloo3122 commented 5 years ago

synergy

https://github.com/brahma-dev/synergy-stable-builds/releases

generrate registry according to: https://mrlithium.blogspot.com/2017/06/synergy-serial-number-activation-key.html

waterloo3122 commented 5 years ago

other stuff

vim ./start-all.sh

echo 'existing pids are:'
ps axu |grep 'ss-local\|client_darwin_amd64'| grep -v 'grep'| awk '{print $2}'

ps axu |grep 'ss-local\|client_darwin_amd64'| grep -v 'grep' | awk '{print $2}' |xargs kill -9

nohup /Users/pp/kcptun/client_darwin_amd64 -c /Users/pp/kcptun/kcptun-config.json >> /Users/pp/kcptun/kcp.log 2>&1 &
sleep 1;
ss-local -c /Users/pp/kcptun/shadowsocks-kcptun.json >> /Users/pp/kcptun/ss.log 2>&1 &

echo "new pids are"
ps axu |grep 'ss-local\|client_darwin_amd64'|grep -v 'grep' | awk '{print $2}'
waterloo3122 commented 5 years ago

mac enable system wide proxy

System Proxy -> Network -> Advanced -> Proxies -> add whatever you need -> ok -> Click Apply to make setting effect

waterloo3122 commented 5 years ago

iterm2 config

禁用alt + 字符输入特殊字符 Cmd+., Profiles, Keys and choose Left option Key acts as: +Esc.

waterloo3122 commented 5 years ago

import icc or icm file 导入显示器的调色文件

  1. spotlight-》ColorSync Utility
  2. rename icm to icc
  3. place icc in /Users/pp/Library/ColorSync/Profiles

reference: http://www.howtoip.com/how-to-find-and-install-a-color-profile-on-windows-for-a-more-accurate-monitor/

waterloo3122 commented 5 years ago

ntfs related

brew install ntfs-3g sudo ntfs-3g /dev/disk2s2 /Volumes/ntfs shows

The disk contains an unclean file system (0, 0).
Metadata kept in Windows cache, refused to mount.
Falling back to read-only mount because the NTFS partition is in an
unsafe state. Please resume and shutdown Windows fully (no hibernation
or fast restarting.)

resolve: sudo ntfsfix /dev/disk2s2

waterloo3122 commented 5 years ago

install hardware monitor

https://github.com/chris1111/HWSensors-V6.26.1464-EFI 1 2

3

waterloo3122 commented 5 years ago

bbr

wget --no-check-certificate https://github.com/teddysun/across/raw/master/bbr.sh && chmod +x bbr.sh && ./bbr.sh

waterloo3122 commented 5 years ago

screen shareing 远程桌面到mac

on target machine

System Preferences sharing choose 'Screen Sharing' and 'Remote Login'

on your mac

spotlight search 'screen sharing' input the ip of the target machine