- ASCII WWDC - WWDC session transcripts.
- NSHipster - Cocoa weekly from Mattt Thompson. Creator of AFNetworking.
- objc.io - Great resource where each issue consists of a collection posts that all focus on one over arching topic such as testing, Auto Layout, Swift, etc.
- Mike Ash - Self described as "Wizard without portfolio" Mike Ash is very widely read in the Cocoa community.
- Bill Bumgarner's Stack Overflow answers - Long time Apple developer who provides well written answers to some of the hairier questions on ObjC and iOS.
- iOS Dev Weekly - Excellent and widely read weekly that aggregates some of the best writing in the Cocoa developer community.
- Stable Kernel - Joe Conway, one of the original authors of BNR's Beginning iOS book and former BNR engineer and instructor.
- [Big Nerd Ran
import difflib | |
import pygments | |
import pygments.lexers | |
import pygments.formatters | |
def read_file(fn): | |
with open(fn) as f: | |
return f.read() |
var fs = require('fs') | |
, net = require('net') | |
, http = require('http') | |
, port = process.env.PORT; | |
var app = function (req, res) { | |
res.writeHead(200, {'Content-Type': 'text/plain'}); | |
res.end('Hello World\n'); | |
}; |
# Live cells with < 2 living neighbors dies to underpop | |
# > 3 living neighbors dies to overpop | |
# Otherwise, lives! | |
# | |
# Dead cells with exactly 3 living neighbors is born | |
# . 0 . | |
# . 0 . | |
# . 0 . | |
# |
(function(){ | |
function useManifest(content){ | |
var tag; | |
var stylesheets = content.match(/\/css\/.*\.css/g); | |
for (var i=0; i<stylesheets.length; i++){ | |
tag = document.createElement('link'); | |
tag.href = stylesheets[i]; | |
tag.rel = "stylesheet"; | |
document.getElementsByTagName('head')[0].appendChild(tag); |
# first: | |
lsbom -f -l -s -pf /var/db/receipts/org.nodejs.pkg.bom | while read f; do sudo rm /usr/local/${f}; done | |
sudo rm -rf /usr/local/lib/node /usr/local/lib/node_modules /var/db/receipts/org.nodejs.* | |
# To recap, the best way (I've found) to completely uninstall node + npm is to do the following: | |
# go to /usr/local/lib and delete any node and node_modules | |
cd /usr/local/lib | |
sudo rm -rf node* |
import mongoose from 'mongoose'; | |
let schema = new mongoose.Schema({ | |
email: { type: String, required: true, unique: true }, | |
password: { type: String, required: true } | |
}); | |
schema.statics.findOrCreate = async (conditions, opt_attr) => { | |
let document = await User.findOne(conditions); |
This is about documenting getting Linux running on the late 2016 and mid 2017 MPB's; the focus is mostly on the MacBookPro13,3 and MacBookPro14,3 (15inch models), but I try to make it relevant and provide information for MacBookPro13,1, MacBookPro13,2, MacBookPro14,1, and MacBookPro14,2 (13inch models) too. I'm currently using Fedora 27, but most the things should be valid for other recent distros even if the details differ. The kernel version is 4.14.x (after latest update).
The state of linux on the MBP (with particular focus on MacBookPro13,2) is also being tracked on https://github.com/Dunedan/mbp-2016-linux . And for Ubuntu users there are a couple tutorials (here and here) focused on that distro and the MacBook.
Note: For those who have followed these instructions ealier, and in particular for those who have had problems with the custom DSDT, modifying the DSDT is not necessary anymore - se
port module Chat exposing (main) | |
-- https://github.com/elm-lang/core/issues/703 | |
import Json.Decode | |
import WebSocket | |
port messages : List String -> Cmd msg |
Random set of notes and links that have helped me in the saga to get Ubuntu 22.04 up and running on my 2017 MacBook Pro These notes are mainly for myself in the event that I have to do this again some day. But if you find them helpful, that's great.
Unfortunately the MacBookPro that I bought second hand turned out to be a dud with some serious hardware flaws that didn't show up until a couple of months after I'd bought it.
I've since purhcased another laptop so I'm not going to be able to maintain this GIST.
I'll leave it here for now in case others want to contribute updates, or clone it. If you feel it's out of date or misleading or a waste of time, let me know in the comments and I'll remove it.