Scripts, tunning and hacks macOS
$ xcode-select --install
$ sudo spctl --master-disable
$ codesign --sign - --force --deep /path/to/app.app
$ sudo xattr -rd com.apple.quarantine /Applications/TheApp.app
$ sudo xattr -cr /Applications/TheApp.app
$ defaults -currentHost write -g AppleFontSmoothing -int 0
$ defaults write -g CGFontRenderingFontSmoothingDisabled -bool NO
$ sudo pkill bluetoothd
$ defaults write NSGlobalDomain NSAppSleepDisabled -bool YES
- Enable:
$ sudo nvram boot-args="-v"
- Disable:
$ sudo nvram boot-args=
$ sudo nano /etc/sysctl.conf
add:
net.inet.tcp.delayed_ack=0
Save and done!
Also (By Apple):
$ defaults write com.apple.desktopservices DSDontWriteNetworkStores -bool TRUE
Relogin to apply
Instalar desde https://ohmyz.sh/
Editar ~/.zshrc
y modicar o añadir las lineas a estos valores
ZSH_THEME="bira"
plugins=(git macos)
export EDITOR=nano
#.s. for nano
export VISUAL="$EDITOR"
#.s. for VisualCode
#export VISUAL="code --wait"
alias ll='ls -lha'
Editar el archivo ~/.bash_profile
o ~/.zshrc
según interprete de consola.
Añadir:
export EDITOR=nano
export VISUAL="$EDITOR"
Open a terminal:
$ cd ~/Library
$ mkdir KeyBindings
$ cd KeyBindings
$ nano DefaultKeyBinding.dict
Add all text:
{
"\UF729" = "moveToBeginningOfLine:"; /* Home */
"\UF72B" = "moveToEndOfLine:"; /* End */
"$\UF729" = "moveToBeginningOfLineAndModifySelection:"; /* Shift + Home */
"$\UF72B" = "moveToEndOfLineAndModifySelection:"; /* Shift + End */
"^\UF729" = "moveToBeginningOfDocument:"; /* Ctrl + Home */
"^\UF72B" = "moveToEndOfDocument:"; /* Ctrl + End */
"$^\UF729" = "moveToBeginningOfDocumentAndModifySelection:"; /* Shift + Ctrl + Home */
"$^\UF72B" = "moveToEndOfDocumentAndModifySelection:"; /* Shift + Ctrl + End */
}
- Fuente: https://support.apple.com/es-es/HT208209
- Acelerar la exploración en comparticiones de red:
$ defaults write com.apple.desktopservices DSDontWriteNetworkStores -bool TRUE
- Forzar al Finder para que recopile primero todos los metadatos:
$ defaults write com.apple.desktopservices UseBareEnumeration -bool FALSE
- Desactivar el almacenamiento en caché del directorio:
$ echo "[default]" | sudo tee -a /etc/nsmb.conf echo "dir_cache_off=yes" | sudo tee -a /etc/nsmb.conf
$ sudo killall -HUP mDNSResponder;sudo killall mDNSResponderHelper;sudo dscacheutil -flushcache;
$ sudo rm -rfv /Library/Caches/com.apple.iconservices.store; sudo find /private/var/folders \( -name com.apple.dock.iconcache -or -name com.apple.iconservices \) -exec rm -rfv {} \; ; sleep 3; sudo touch /Applications/*; killall Dock; killall Finder;
Need to grant Full Disk Access to Cron, Crontab
- Go to System Settings > Privacy & Security > Privacy > Full Disk Access
- And press +
- Navigate to the /usr/sbin folder with Finder. (You can do that with CMD + SHIFT + G and entering the path.)
- Add
cron
app binary - Navigate to the /usr/bin folder with Finder. (You can do that with CMD + SHIFT + G and entering the path.)
- Add
crontab
app binary
You can do the same with rsync if needed.
To show the executable path use which
ex: $ which rsync