Understand your Mac and iPhone more deeply by tracing the evolution of Mac OS X from prelease to Swift. John Siracusa delivers the details.
You've got two main options:
| { | |
| "name":"BT5.0 KB", | |
| "vendorId":"0x369b", | |
| "productId":"0x0051", | |
| "matrix":{"rows":4,"cols":17}, | |
| "firmwareVersion":0, | |
| "menus":[ | |
| { | |
| "label":"Lighting", | |
| "content":[ |
| #!/bin/bash | |
| # Run cputhrottle for a list of applications in order to limit their CPU usage. | |
| # This script needs `pidof` and `cputhrottle` installed, which can be installed from homebrew. | |
| # NOTE: This script was tested on MacOS only. | |
| if [[ $EUID > 0 ]]; then | |
| echo "Please run this script as root/sudo" | |
| exit 1 | |
| fi |
| #!/bin/sh | |
| #---------------------------------------------------------------------------------------------------------- | |
| # | |
| # Original author: Bracken King | |
| # https://www.lessannoyingcrm.com/blog/2010/08/149/create+application+shortcuts+in+google+chrome+on+a+mac | |
| # | |
| # Modified by: Gilberto R. Olimpio | |
| # | |
| # Changes: |
I bought M1 MacBook Air. It is the fastest computer I have, and I have been a GNOME/GNU/Linux user for long time. It is obvious conclusion that I need practical Linux desktop environment on Apple Silicon.
Fortunately, Linux already works on Apple Silicon/M1. But how practical is it?
| defaults write com.apple.Dock appswitcher-all-displays -bool true | |
| killall Dock |
| -- Inspired by Linux alt-drag or Better Touch Tools move/resize functionality | |
| function get_window_under_mouse() | |
| -- Invoke `hs.application` because `hs.window.orderedWindows()` doesn't do it | |
| -- and breaks itself | |
| local _ = hs.application | |
| local my_pos = hs.geometry.new(hs.mouse.getAbsolutePosition()) | |
| local my_screen = hs.mouse.getCurrentScreen() |
| #!/bin/bash | |
| # Inspired by | |
| # https://www.codeenigma.com/community/blog/using-mdbtools-nix-convert-microsoft-access-mysql | |
| # USAGE | |
| # Rename your MDB file to migration-export.mdb | |
| # run ./mdb2sqlite.sh migration-export.mdb | |
| # wait and wait a bit longer... | |
| mdb-schema migration-export.mdb sqlite > schema.sql |
| # Add extra room between lines (tested with mPlus Nerd Font) | |
| # Adjust space below the line | |
| defaults write com.macromates.TextMate fontLeadingDelta -float 0.5 | |
| # Adjust space above the line | |
| defaults write com.macromates.TextMate fontAscentDelta -float 0 | |
| # Reset to default | |
| defaults delete com.macromates.TextMate fontLeadingDelta |
| # inspired by https://github.com/junegunn/fzf/issues/868 | |
| function __fzf_ls_files | |
| git ls-tree -r --name-only HEAD 2>/dev/null; or fd --type f --hidden --follow --exclude .git | |
| end | |
| function __fzf_grep_last | |
| set -l cmd (commandline) | |
| # default complete all, and compatible with fzf `**<TAB>` | |
| if str_endswith "$cmd" ' '; or test $cmd = '**' |