My Windows-Client

# Terminal
Cmder (comemu)
http://cmder.net/

# Shells
## CMD,Powershell
Via Cmder.
For Windows Native binary (ruby, python installed via msi) .

## MSYS2
DO NOT inherit windows native env-val.
Install ruby or python, Msys2 builded tool via `pacman`
Any tools don't support pacman,（docker...) add $PATH individually.

```
pacman -S winpty
pacman -S python3-pip
pacman -S git
pacman -S vim
```
# Docker

## Docker & terminal
MSYS2 + mintty (ConEmu)

### Install winpty
`pacman -S winpty`

### `PATH` and Alias
```bash:.bashrc
export PATH=$PATH:/c/Program\ Files/Docker/Docker/resources/bin
alias d="winpty docker"
alias dc="winpty docker-compose"
```

## direnv
### via fish
1. install omf
2. `omf install direnv` but we must install direnv-bin manualy.

### via bash (old)
Download bin & set PATH.
add `eval "$(direnv hook bash)"`.

https://github.com/direnv/direnv/issues/343
`export GOPATH=$(pwd)` @ .envrc

# Shrink C Drive!
Don't touch `Windows\Installer`
Remove `Windows\LivekernelReports\*.dmp`
If `System32` so fat, hack `DriverStore` via DriverStoreExploer
 https://github.com/lostindark/DriverStoreExplorer

## `du` on windows
sysinternals!
https://technet.microsoft.com/ja-jp/sysinternals/du.aspx

# nodoka
key mapping
we must EOL only @ EOF (last line).

```104on109.nodoka
define KBD104on109

#def subst ~S-*半角/全角		= $GRAVE_ACCENT
def subst ~S-*YenSign       = $GRAVE_ACCENT
#def subst  S-*半角/全角		= $TILDE
def subst  S-*YenSign       = $TILDE
#def subst  A-半角/全角		= $ToggleIME
def subst  S-*_2		= $COMMERCIAL_AT
def subst  S-*_6		= $CIRCUMFLEX_ACCENT
def subst  S-*_7		= $AMPERSAND
def subst  S-*_8		= $ASTERISK
def subst  S-*_9		= $LEFT_PARENTHESIS
def subst  S-*_0		= $RIGHT_PARENTHESIS
def subst  S-*Hyphen		= $LOW_LINE
def subst ~S-*Caret		= $EQUALS_SIGN
def subst  S-*Caret		= $PLUS_SIGN
def subst ~S-*Atmark		= $LEFT_SQUARE_BRACKET
def subst  S-*Atmark		= $LEFT_CURLY_BRACKET
def subst ~S-*OpenBracket	= $RIGHT_SQUARE_BRACKET
def subst  S-*OpenBracket	= $RIGHT_CURLY_BRACKET
def subst ~S-*CloseBracket	= $REVERSE_SOLIDUS
def subst  S-*CloseBracket	= $VERTICAL_LINE
def subst  S-*Semicolon		= $COLON
def subst ~S-*Colon		= $APOSTROPHE
def subst  S-*Colon		= $QUOTATION_MARK
#def subst    *無変換		= *Space
#def subst    *変換		= *Space
#def subst    *ひらがな		= *Space
#def subst    *英数		= S-*英数
def subst *ReverseSolidus	= *RightShift

keymap Global
mod shift += ReverseSolidus
mod alt += ひらがな
key *ひらがな = *LeftAlt
mod control += 無変換
key *無変換 = *LeftControl
mod control += 変換
key *変換 = *RightControl
mod control += 英数
key *英数 = *LeftControl
```


# autohotkey (migrated to nodoka)
JIS-key  to US
`muhenkan` to Ctrl
`henakan` to Ctrl

`katakana-hiragana` key has two scan-codes when up and down, even if vk is one.  capslock => ctrl and `katakana-hiragana` key, set registory for other keys.

autohotkey's escape is ```
 
```text
#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn  ; Enable warnings to assist with detecting common errors.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.

#InstallKeybdHook
vk1Dsc07B::Ctrl
vk1Csc079::Ctrl

*"::send, @
*&::send, {^}
*'::send, &
*(::send, *
*)::send, (
*+0::send, )
*=::send, _
*^::send, =
*~::send, {+}
*@::send, [
*`::send, {{}
*[::send, ]
*{::send, {}}
*]::send, \
*}::send, |
*vkBA::send, '
*+::send, :
*+*::send, "
*\::send, {``}
*+\::send, {~}

```
# synergy
Now, $10 ...
Buy it!