Get rid of double quotes, dots in layout name

For some layouts (U.S for example) keyboard name in double quotes. But for Russian, Portuguese - not.
This commit is contained in:
Vlad Ro 2021-12-07 01:34:29 +01:00 committed by GitHub
parent f6a71a4a0b
commit 7c15a42a17
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,4 +1,4 @@
#!/bin/bash
set -euo pipefail
defaults read ~/Library/Preferences/com.apple.HIToolbox.plist AppleSelectedInputSources | grep "KeyboardLayout Name" | cut -f 2 -d "=" | tr -d ' ;'
defaults read ~/Library/Preferences/com.apple.HIToolbox.plist AppleSelectedInputSources | grep "KeyboardLayout Name" | cut -f 2 -d "=" | tr -d ' ;."'