Skip to content

Instantly share code, notes, and snippets.

View jpavley's full-sized avatar
💭
Working at the office 3 days a week!

John Pavley jpavley

💭
Working at the office 3 days a week!
View GitHub Profile
@htr3n
htr3n / macos-ramdisk.md
Last active June 28, 2024 01:39
Creating RAM disk in macOS

Built-in

diskutil erasevolume HFS+ 'RAM Disk' `hdiutil attach -nobrowse -nomount ram://XXXXX`

where XXXXX is the size of the RAM disk in terms of memory blocks.

Notes:

@JamesMessinger
JamesMessinger / README.md
Last active March 9, 2024 17:58
VSCode GitHub Markdown Theme

GitHub Markdown Theme for Visual Studio Code

This CSS stylesheet allows you to preview markdown files in VSCode using GitHub's mardown theme. This CSS was taken directly from the official GitHub Markdown repo. I replaced their top-level .markdown-body class with the body tag so it would work in VSCode, and added styling for the html tag to match GitHub's fixed-width container.

Instructions

  1. Copy the CSS file to your computer
    Copy the github-markdown.css file below to your computer. You can put it anywhere you want, but I chose to put it in the same folder as my VSCode settings file.

  2. Edit your VSCode settings
    If you want to use this theme for all of your projects, then edit your User Settings file. If you just want to use this them

@kharrison
kharrison / String.swift
Last active January 22, 2024 14:03
Swift String Playground Examples
// Swift Standard Librray - String
// Keith Harrison http://useyourloaf.com
// Import Foundation if you want to bridge to NSString
import Foundation
// ====
// Initializing a String
// ====
@jpavley
jpavley / data-source-methods.m
Last active December 19, 2015 01:08
data source methods for app delegates
- (void)awakeFromNib
{
NSLog(@"%@" , NSStringFromSelector(_cmd));
}
- (NSInteger)numberOfRowsInTableView:(NSTableView *)tv
{
NSLog(@"%@" , NSStringFromSelector(_cmd));
return (NSInteger)0;
}