| Shortcut | Description | Overridable?[^1] |
|---|---|---|
Fn-A |
Navigate Dock | No |
Fn-Shift-A |
Launchpad | No |
Fn-C |
Control Center | No |
Fn-E |
Emoji & Symbols | Yes |
Fn-F |
Enter/Exit Full Screen | Yes |
Fn-H |
Desktop | No |
Fn-M |
Navigate Main Menu | Yes |
Fn-N |
Notifications | No |
| use framework "Foundation" | |
| use framework "NaturalLanguage" | |
| use framework "AVFoundation" | |
| -- https://www.macscripter.net/t/detect-language-from-sentence-for-speech-synthesizer/74560 | |
| (** | |
| * import Foundation | |
| * import NaturalLanguage | |
| * import AVFoundation |
| #!/usr/bin/env osascript -l JavaScript | |
| /** | |
| * ----------------------------------------------------------------------------- | |
| * Activate Sidecar/Screen Mirroring from Control Center | |
| * ----------------------------------------------------------------------------- | |
| * | |
| * Created on February 17, 2023 by Stephan Casas | |
| * Updated on May 18, 2023 by Stephan Casas | |
| * |
| #define STEP 12 | |
| void setup() { | |
| // 200 step per revolution motor driver on this pin. | |
| pinMode(STEP, OUTPUT); | |
| } | |
| void topSpeed_1Turn() { | |
| for (int i = 0; i < 200; i++) { | |
| // Issue 1 step. |
| const abortableSearchItems = ( | |
| searchString: string, | |
| signal: AbortSignal | |
| ): Promise<Item[]> => { | |
| if (signal.aborted) { | |
| return Promise.reject(new Error("searchAborted")); | |
| } | |
| return new Promise((resolve, reject) => { | |
| const abortSearchHandler = () => { |
| const app = Application.currentApplication() | |
| app.includeStandardAdditions = true | |
| function getJSON(path) { | |
| const fullPath = path.replace(/^~/, app.pathTo('home folder')) | |
| const contents = app.read(fullPath) | |
| return JSON.parse(contents) | |
| } | |
| function run() { |
Use these together with https://redsweater.com/fastscripts/ for global hotkey goodness in macOS
Requirements:
brew install fastscripts
Download all the scripts and put them in ~/Library/Scripts/
I have a git repo which compiles into a dist folder and generates a bunch binaries (executables).
The binaries and dist folders are .gitignore-ed and hence, are not included in the repo.
But I want to distribute a source + binaries snapshot zipfile.
I want them to contain:
a) all the sources
b) all the binaries
c) the dist folder (so that they can tweak it)
d) not the .git/ directory, not the hidden files like .cache or node_modules/ etc.
Unless otherwise noted (either in this file or in a file's copyright section) the contents of this gist are Copyright ©️2020 by Christopher Allen, and are shared under spdx:Creative Commons Attribution Share Alike 4.0 International (CC-BY-SA-4.) open-source license.
If you more tips and advice like these, you can become a monthly patron on my GitHub Sponsor Page for as little as $5 a month; and your contributions will be multipled, as GitHub is matching the first $5,000! This gist is all about Homebrew, so if you like it you can support it by donating to them or becoming one of their Github Sponsors.
- SC1000 $ is not used specially and should therefore be escaped.
- SC1001 This
\owill be a regular 'o' in this context. - SC1003 Want to escape a single quote? echo 'This is how it'\''s done'.
- SC1004 This backslash+linefeed is literal. Break outside single quotes if you just want to break the line.
- SC1007 Remove space after = if trying to assign a value (or for empty string, use var='' ... ).
- SC1008 This shebang was unrecognized. ShellCheck only supports sh/bash/dash/ksh. Add a 'shell' directive to specify.
- SC1009 The mentioned parser error was in ...
- SC1010 Use semicolo