dotfiles: update

This commit is contained in:
Konstantin Bukley
2021-05-31 21:54:10 +03:00
parent 44f0fb889f
commit 2e19242843
4 changed files with 169 additions and 92 deletions

View File

@@ -109,6 +109,9 @@ alias rs='bin/rails s -p3001'
alias mux='tmuxinator start' alias mux='tmuxinator start'
alias ibrew='arch -x86_64 /usr/local/bin/brew'
alias mbrew='arch -arm64e /opt/homebrew/bin/brew'
yta() { yta() {
streamlink $1 audio_mp4 streamlink $1 audio_mp4
} }
@@ -132,7 +135,8 @@ alias fkill='fzf_kill'
# Homebrew stuff # Homebrew stuff
if [ -x /usr/local/bin/brew ]; then if [ -x /usr/local/bin/brew ]; then
export PATH=/usr/local/bin:/usr/local/sbin:$PATH # export PATH=/usr/local/bin:/usr/local/sbin:$PATH
export PATH=/opt/homebrew/bin:/opt/homebrew/opt:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/Apple/usr/bin:$PATH
export MANPATH=/usr/local/share/man:$MANPATH export MANPATH=/usr/local/share/man:$MANPATH
fi fi

View File

@@ -15,6 +15,32 @@
"mouse_motion_to_scroll.speed": 100 "mouse_motion_to_scroll.speed": 100
}, },
"rules": [ "rules": [
{
"description": "Change caps_lock to control if pressed with other keys, to escape if pressed alone.",
"manipulators": [
{
"from": {
"key_code": "caps_lock",
"modifiers": {
"optional": [
"any"
]
}
},
"to": [
{
"key_code": "left_control"
}
],
"to_if_alone": [
{
"key_code": "escape"
}
],
"type": "basic"
}
]
},
{ {
"description": "Tab Modifier Mode [Tab as Trigger Key]", "description": "Tab Modifier Mode [Tab as Trigger Key]",
"manipulators": [ "manipulators": [
@@ -1521,117 +1547,133 @@
"from": { "from": {
"key_code": "f1" "key_code": "f1"
}, },
"to": { "to": [
"consumer_key_code": "display_brightness_decrement" {
} "consumer_key_code": "display_brightness_decrement"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f2" "key_code": "f2"
}, },
"to": { "to": [
"consumer_key_code": "display_brightness_increment" {
} "consumer_key_code": "display_brightness_increment"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f3" "key_code": "f3"
}, },
"to": { "to": [
"key_code": "mission_control" {
} "key_code": "mission_control"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f4" "key_code": "f4"
}, },
"to": { "to": [
"key_code": "launchpad" {
} "key_code": "launchpad"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f5" "key_code": "f5"
}, },
"to": { "to": [
"key_code": "illumination_decrement" {
} "key_code": "illumination_decrement"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f6" "key_code": "f6"
}, },
"to": { "to": [
"key_code": "illumination_increment" {
} "key_code": "illumination_increment"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f7" "key_code": "f7"
}, },
"to": { "to": [
"consumer_key_code": "rewind" {
} "consumer_key_code": "rewind"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f8" "key_code": "f8"
}, },
"to": { "to": [
"consumer_key_code": "play_or_pause" {
} "consumer_key_code": "play_or_pause"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f9" "key_code": "f9"
}, },
"to": { "to": [
"consumer_key_code": "fastforward" {
} "consumer_key_code": "fastforward"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f10" "key_code": "f10"
}, },
"to": { "to": [
"consumer_key_code": "mute" {
} "consumer_key_code": "mute"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f11" "key_code": "f11"
}, },
"to": { "to": [
"consumer_key_code": "volume_decrement" {
} "consumer_key_code": "volume_decrement"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f12" "key_code": "f12"
}, },
"to": { "to": [
"consumer_key_code": "volume_increment" {
} "consumer_key_code": "volume_increment"
}
]
} }
], ],
"name": "work", "name": "work",
"parameters": { "parameters": {
"delay_milliseconds_before_open_device": 1000 "delay_milliseconds_before_open_device": 1000
}, },
"selected": true, "selected": false,
"simple_modifications": [ "simple_modifications": [],
{
"from": {
"key_code": "caps_lock"
},
"to": {
"key_code": "f18"
}
}
],
"virtual_hid_keyboard": { "virtual_hid_keyboard": {
"caps_lock_delay_milliseconds": 1000, "caps_lock_delay_milliseconds": 1000,
"country_code": 0, "country_code": 0,
"indicate_sticky_modifier_keys_state": true,
"keyboard_type": "ansi", "keyboard_type": "ansi",
"mouse_key_xy_scale": 100 "mouse_key_xy_scale": 100
} }
@@ -1678,117 +1720,144 @@
"from": { "from": {
"key_code": "f1" "key_code": "f1"
}, },
"to": { "to": [
"consumer_key_code": "display_brightness_decrement" {
} "consumer_key_code": "display_brightness_decrement"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f2" "key_code": "f2"
}, },
"to": { "to": [
"consumer_key_code": "display_brightness_increment" {
} "consumer_key_code": "display_brightness_increment"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f3" "key_code": "f3"
}, },
"to": { "to": [
"key_code": "mission_control" {
} "key_code": "mission_control"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f4" "key_code": "f4"
}, },
"to": { "to": [
"key_code": "launchpad" {
} "key_code": "launchpad"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f5" "key_code": "f5"
}, },
"to": { "to": [
"key_code": "illumination_decrement" {
} "key_code": "illumination_decrement"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f6" "key_code": "f6"
}, },
"to": { "to": [
"key_code": "illumination_increment" {
} "key_code": "illumination_increment"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f7" "key_code": "f7"
}, },
"to": { "to": [
"consumer_key_code": "rewind" {
} "consumer_key_code": "rewind"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f8" "key_code": "f8"
}, },
"to": { "to": [
"consumer_key_code": "play_or_pause" {
} "consumer_key_code": "play_or_pause"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f9" "key_code": "f9"
}, },
"to": { "to": [
"consumer_key_code": "fastforward" {
} "consumer_key_code": "fastforward"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f10" "key_code": "f10"
}, },
"to": { "to": [
"consumer_key_code": "mute" {
} "consumer_key_code": "mute"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f11" "key_code": "f11"
}, },
"to": { "to": [
"consumer_key_code": "volume_decrement" {
} "consumer_key_code": "volume_decrement"
}
]
}, },
{ {
"from": { "from": {
"key_code": "f12" "key_code": "f12"
}, },
"to": { "to": [
"consumer_key_code": "volume_increment" {
} "consumer_key_code": "volume_increment"
}
]
} }
], ],
"name": "wow", "name": "wow",
"parameters": { "parameters": {
"delay_milliseconds_before_open_device": 1000 "delay_milliseconds_before_open_device": 1000
}, },
"selected": false, "selected": true,
"simple_modifications": [ "simple_modifications": [
{ {
"from": { "from": {
"key_code": "right_command" "key_code": "right_command"
}, },
"to": { "to": [
"pointing_button": "button2" {
} "pointing_button": "button2"
}
]
} }
], ],
"virtual_hid_keyboard": { "virtual_hid_keyboard": {
"caps_lock_delay_milliseconds": 0, "caps_lock_delay_milliseconds": 0,
"country_code": 0, "country_code": 0,
"indicate_sticky_modifier_keys_state": true,
"keyboard_type": "ansi", "keyboard_type": "ansi",
"mouse_key_xy_scale": 100 "mouse_key_xy_scale": 100
} }

9
macos
View File

@@ -17,9 +17,10 @@ while true; do sudo -n true; sleep 60; kill -0 "$$" || exit; done 2>/dev/null &
############################################################################### ###############################################################################
# Set computer name (as done via System Preferences → Sharing) # Set computer name (as done via System Preferences → Sharing)
#sudo scutil --set ComputerName "0x6D746873" # sudo scutil --set ComputerName "hostname"
#sudo scutil --set HostName "0x6D746873" # sudo scutil --set HostName "hostname"
#sudo scutil --set LocalHostName "0x6D746873" # sudo scutil --set LocalHostName "hostname"
#sudo defaults write /Library/Preferences/SystemConfiguration/com.apple.smb.server NetBIOSName -string "0x6D746873" #sudo defaults write /Library/Preferences/SystemConfiguration/com.apple.smb.server NetBIOSName -string "0x6D746873"
# Set standby delay to 24 hours (default is 1 hour) # Set standby delay to 24 hours (default is 1 hour)
@@ -130,7 +131,7 @@ defaults write com.apple.screensaver askForPassword -int 1
defaults write com.apple.screensaver askForPasswordDelay -int 0 defaults write com.apple.screensaver askForPasswordDelay -int 0
# Save screenshots to the desktop # Save screenshots to the desktop
defaults write com.apple.screencapture location -string "${HOME}/Desktop" defaults write com.apple.screencapture location -string "${HOME}/Screenshot"
# Save screenshots in PNG format (other options: BMP, GIF, JPG, PDF, TIFF) # Save screenshots in PNG format (other options: BMP, GIF, JPG, PDF, TIFF)
defaults write com.apple.screencapture type -string "png" defaults write com.apple.screencapture type -string "png"

View File

@@ -27,6 +27,9 @@ syntax on
" ======================================================== " ========================================================
" -> Plugins " -> Plugins
" ======================================================== " ========================================================
"
" curl -fLo ~/.vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
"
call plug#begin('~/.vim/plugged') call plug#begin('~/.vim/plugged')