Skip to content

Instantly share code, notes, and snippets.

@jasonwiener
jasonwiener / tag.scpt
Created August 4, 2017 15:43
BBEdit wrap selection (or create empty) HTML tag with CSS class using AppleScript
-- tag input options:
-- div -> <div>{SELECTED TEXT IF ANY}</div>
-- div.myclass -> <div class="myclass">{SELECTED TEXT IF ANY}</div>
on splitText(theText, theDelimiter)
set AppleScript's text item delimiters to theDelimiter
set theTextItems to every text item of theText
set AppleScript's text item delimiters to ""
return theTextItems
end splitText
@jasonwiener
jasonwiener / movietransitions.swift
Created January 2, 2016 23:13 — forked from SheffieldKevin/movietransitions.swift
Make a movie with transitions with AVFoundation and swift
//
// main.swift
// mutablecomposition
//
// Created by Kevin Meaney on 24/08/2015.
// Copyright (c) 2015 Kevin Meaney. All rights reserved.
//
import Foundation
@jasonwiener
jasonwiener / hello world come on in the water's fine
Last active January 2, 2016 00:29
this is the description of the gist
<html>
<head>
<title>test</title></head>
<body>
<center>hello world</center>
</body>
</html>
{
"status": "success",
"now": 1377860542,
"data": {
"customer": "cus_1f0MLmnMDLhyok",
"object": "invoice",
"next_payment_attempt": null,
"attempted": true,
"livemode": false,
"lines": {
$ curl https://testdata.graph.fm/0c0e4da529453ae846f1140c55b747f8/d42a8bf2cb3edd0b2978569a2f908b8d/Stripe/invoices \
-X POST \
-d "id='cus_28vOEDlYZHvyYL'"
{
"status": "success",
"now": 1372448008,
"data": {
"veera": [
[
"allaivanova",
1369170417
]
],
{
"status": "success",
"now": 1369168001,
"data": [
"exists",
"added",
"added",
"added"
],
"took": "25.39ms"
{"status":"success","now":1369168460,"data":["adelewiener","judieschauer","veera","zauchka"],"took":"7.54ms"}
{
"status": "success",
}