Since 2008 or 2009 I work on Apple hardware and OS: back then I grew tired of Linux desktop (which is going to be MASSIVE NEXT YEAR, at least since 2001), and switched to something that Just Works. Six years later, it less and less Just Works, started turning into spyware and nagware, and doesn't need much less maintenance than Linux desktop — at least for my work, which is system administration and software development, probably it is better for the mythical End User person. Work needed to get software I need running is not less obscure than work I'd need to do on Linux or othe Unix-like system. I am finding myself turning away from GUI programs that I used to appreciate, and most of the time I use OSX to just run a terminal, Firefox, and Emacs. GUI that used to be nice and unintrusive, got annoying. Either I came full circle in the last 15 years of my computer usage, or the OSX experience degraded in last 5 years. Again, this is from a sysadmin/developer ki
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- | |
| - name: Check status of jailing | |
| shell: "sysctl security.jail.jailed | cut -d: -f2 | tr -d ' '" | |
| register: is_jail | |
| when: "ansible_os_family == 'FreeBSD' " | |
| - name: Fetch and Install Updates | |
| command: "{{ item }}" | |
| when: "ansible_os_family == 'FreeBSD' and is_jail.stdout == '0'" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| ##Device = Desktops | |
| ##Screen = 1281px to higher resolution desktops | |
| */ | |
| @media (min-width: 1281px) { | |
| /* CSS */ | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Text-to-Speech on OSX | |
| // run: swift speech.swift "東京特許許可局" | |
| // build: xcrun -sdk macosx swiftc speech.swift && ./speech "東京特許許可局" | |
| // | |
| // for OSX, use NSSpeechSYnthesizer in AppKit, | |
| // (for iOS, use AVSpeechSynthesizer in AVFoundation) | |
| // | |
| // 11/9/2016 -- Swift 3.0 | |
| import Foundation |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // [Noted in the comments below on 2023-10 - this script might not work very well anymore due to Elon ruining Twitter] | |
| // [Updated 2021-01-18 w/new selectors] | |
| // go to your account Likes page and run this in the console: | |
| function scrollToLoadMore() { | |
| // keep scrolling if twitter tries to stop loading more. | |
| // scroll up, then down to force infinite load. | |
| window.scrollTo(0, 0); | |
| setTimeout(function() { | |
| window.scrollBy(0, 9999999999); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| set -e | |
| CONTENTS=$(tesseract -c language_model_penalty_non_dict_word=0.8 --tessdata-dir /usr/local/share/tessdata/ "$1" stdout -l eng | xml esc) | |
| hex=$((cat <<EOF | |
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
| <plist version="1.0"> |
Guide: Run FreeBSD 13.1-RELEASE for ARM64 in QEMU on Apple Silicon Mac (MacBook Pro M1, etc) with HVF acceleration (Hypervisor.framework)
This guide was adapted from https://gist.github.com/niw/e4313b9c14e968764a52375da41b4278#running-ubuntu-server-for-arm64
- Install Xcode from App Store or install Command Line Tools on your Mac running on Apple Silicon.
