Skip to content

Instantly share code, notes, and snippets.

@tombigel
tombigel / README.md
Last active March 18, 2025 18:49 — forked from a2ikm/limit.maxfiles.plist
How to Change Open Files Limit on OS X and macOS Sierra (10.8 - 10.12)

How to Change Open Files Limit on OS X and macOS

This text is the section about OS X Yosemite (which also works for macOS Sierra) from https://docs.basho.com/riak/kv/2.1.4/using/performance/open-files-limit/#mac-os-x

The last time i visited this link it was dead (403), so I cloned it here from the latest snapshot in Archive.org's Wayback Machine https://web.archive.org/web/20170523131633/https://docs.basho.com/riak/kv/2.1.4/using/performance/open-files-limit/

Mac OS X

To check the current limits on your Mac OS X system, run:

@chmurph2
chmurph2 / sodastream_diy.soulver
Created September 6, 2017 19:01
SodaStream DIY Recoup and Calculations
@tl;dr
5.3 months // how often 3 sparkling water drinkers will go through a 20 lbs CO2 tank
$90 // SodaStream
$29 // 20 lbs tank refill every 6 months, at Robert's Oxygen in Dulles, VA
$201 // initial investment in tank, refill attachments/adapter, first CO2 fill
5.4 months // time to recoup initial equipment investment (sans SodaStream)
@initial equipment costs (excluding SodaStream, which we got as a gift)
diy_tank_20lbs = $115 + $21.34 shipping // 20 lb CO2 tank
adapter_kit = $30 // kit to attach tank to sodastream bottle to refill (tubes, connectors, valves)
@RobTrew
RobTrew / dtSheetMMDPrettyPrinted.js
Last active October 3, 2022 18:22
Selected DEVONthink Sheet -> DEVONthink markdown record (pretty-printed MMD table)
((options) => {
'use strict';
// (NB JavaScript for Automation – JXA: Save as .scpt )
// Selected DEVONthink Sheet -> DEVONthink markdown record (MMD table)
// (New record containing MMD table created is same group as selection)
// Uses original fileName stem, with '.md' appended.
// This is the *whitespace pretty-printed* version
@RobTrew
RobTrew / dtSheetTableMMD.js
Last active October 3, 2022 18:43
Selected DEVONthink Sheet -> DEVONthink markdown record (MMD table)
((options) => {
'use strict';
// (NB JavaScript for Automation – JXA: Save as .scpt )
// Selected DEVONthink Sheet -> DEVONthink markdown record (MMD table)
// (New record containing MMD table created is same group as selection)
// Uses original fileName stem, with '.md' appended.
// Default alignment string is centered ':--:'
@thespacedoctor
thespacedoctor / papers-anno2md.py
Last active May 5, 2021 15:59
[papers-anno2md] A Script for macOS Papers.app: Convert Papers PDF Annotations to Markdown Notes and Add to the General Notes Section for the Publication #papers #annotations #markdown
#!/usr/local/bin/python
# encoding: utf-8
"""
*Convert Papers PDF Annotations to Markdown Notes and Add to the General Notes Section for the Publication*
:Author:
David Young
:Date Created:
August 30, 2017
@kaisermann
kaisermann / macOS.md
Last active January 1, 2024 06:09
Useful CLI

MacOS exclusive

  • Open and bring to front a specific app
osascript -e "tell application \"APP\" -e "activate" -e "end tell"
osascript -e 'tell app "Terminal" to activate'
osascript -e 'tell app "Terminal" to do script "cmatrix"'
@IskenHuang
IskenHuang / things-to-fantastical.applescript
Created August 12, 2017 15:08
Things3 complete todos create calendar event to fantastical.
(*
## Goal
This script is make new calendar event to fantastical2 from things3 complete todos in 'Logbook' on specified date.
## How to use:
* Default is today
* `$ osascript things-to-fantastical.applescript`
* The specified date
* `$ osascript things-to-fantastical.applescript 2017/08/12`
*)
@AlexanderWillner
AlexanderWillner / things.sh
Last active September 15, 2023 07:29 — forked from avdgaag/things.sh
Command-line read-only interface to your local Things database of to do items.
Moved to https://github.com/alexanderwillner/things.sh/
@galderz
galderz / clean-install-high-sierra-apfs.md
Last active July 3, 2019 21:11
How To Clean Install High Sierra on APFS-formatted main HD

Clean Install High Sierra on APFS-formatted main HD

Installation Steps

  1. From 10.11 or 10.12 systems, format an external hard drive with at least 500gb with "Mac Os Extended Journaled".
  2. Download High Sierra Beta and install it in the external hard drive.
  3. When the system reboots and finishes installation, it will boot from the external HD. Go to Preferences and change Startup Disk to be main HD.
  4. Reboot and press Option key when the computer makes a beep and select external HD to boot from it.
  5. Once booted again into external HD, format main HD to be APFS.
@BretFisher
BretFisher / pcat-install.sh
Last active April 15, 2025 04:14
On macOS: Install pygmentize and alias pcat for shell code syntax highlighting
# first install pygmentize to the mac OS X or macOS system with the built-in python
sudo easy_install Pygments
# then add alias to your ~/.bash_profile or ~/.bashrc or ~/.zshrc etc.
alias pcat='pygmentize -f terminal256 -O style=native -g'