I hereby claim:
- I am jessesquires on github.
- I am jsq (https://keybase.io/jsq) on keybase.
- I have a public key whose fingerprint is BBAE BA80 7CF2 7BC2 5E5C FB43 1537 66AC 1FA1 A758
To claim this, I am signing this object:
// https://wadetregaskis.com/swiftui-main-thread-hang-detector/ | |
var body: some View { | |
SomeRootView { | |
… | |
}.task { | |
let approximateGranularity = Duration.milliseconds(10) | |
let threshold = Duration.milliseconds(50) | |
let clock = SuspendingClock() |
-- Prompt to select the invoice | |
set theInvoice to choose file with prompt "Please select an invoice:" | |
-- Get enclosing folder name | |
tell application "Finder" to set destinationFolder to container of theInvoice | |
log "Destination folder: " & destinationFolder | |
tell application "Pages" | |
activate | |
open theInvoice |
import Cocoa | |
protocol Shape { } | |
struct Triangle: Shape { } | |
// Function signature requires a concrete type T, it is specialized by T | |
// Think of it as having a unique function per type: | |
// - `protoflip(_ s: Triangle) -> Shape` | |
// - `protoflip(_ s: Square) -> Shape` |
#!/usr/bin/swift sh | |
import Foundation | |
import PromiseKit // @mxcl ~> 6.5 | |
import Swifter // @mattdonnelly == b27a89 | |
let swifter = Swifter( | |
consumerKey: "FILL", | |
consumerSecret: "ME", | |
oauthToken: "IN", | |
oauthTokenSecret: "https://developer.twitter.com/en/docs/basics/apps/overview.html" |
I hereby claim:
To claim this, I am signing this object:
git config --global alias.trim '!f() { git branch | grep -v "\*" | xargs -n 1 git branch -D; }; f' |
--- | |
layout: null | |
--- | |
{ | |
"version": "https://jsonfeed.org/version/1", | |
"title": "{{ site.title }}", | |
"home_page_url": "{{ site.url }}", | |
"feed_url": "{{ site.url }}/feed.json", | |
"description": "{{ site.description }}", |
# blog post | |
# | |
# https://www.jessesquires.com/blog/customizing-git-log/ | |
git log --graph --pretty=format:'commit: %C(bold red)%h%Creset %C(red)<%H>%Creset %C(bold magenta)%d %Creset%ndate: %C(bold yellow)%cd %Creset%C(yellow)%cr%Creset%nauthor: %C(bold blue)%an%Creset %C(blue)<%ae>%Creset%n%C(cyan)%s%n%Creset' |
#import <Foundation/Foundation.h> | |
#include <dlfcn.h> | |
NSDictionary *FCPrivateBatteryStatus() | |
{ | |
static mach_port_t *s_kIOMasterPortDefault; | |
static kern_return_t (*s_IORegistryEntryCreateCFProperties)(mach_port_t entry, CFMutableDictionaryRef *properties, CFAllocatorRef allocator, UInt32 options); | |
static mach_port_t (*s_IOServiceGetMatchingService)(mach_port_t masterPort, CFDictionaryRef matching CF_RELEASES_ARGUMENT); | |
static CFMutableDictionaryRef (*s_IOServiceMatching)(const char *name); |