Skip to content

Instantly share code, notes, and snippets.

View alessandrostone's full-sized avatar

Alessandro Aresta alessandrostone

View GitHub Profile
@acarabott
acarabott / faust-macos-homebrew.md
Last active February 27, 2021 23:36
Instructions for building Faust and FaustLive on macOS with Homebrew

Building Faust on macOS with Homebrew

If you haven't installed Homebrew get it from https://brew.sh/

Faust

git clone git@github.com:grame-cncm/faust.git
cd faust
@lattner
lattner / async_swift_proposal.md
Last active August 4, 2026 00:17 — forked from oleganza/async_swift_proposal.md
Concrete proposal for async semantics in Swift

Async/Await for Swift

Introduction

Modern Cocoa development involves a lot of asynchronous programming using closures and completion handlers, but these APIs are hard to use. This gets particularly problematic when many asynchronous operations are used, error handling is required, or control flow between asynchronous calls gets complicated. This proposal describes a language extension to make this a lot more natural and less error prone.

This paper introduces a first class Coroutine model to Swift. Functions can opt into to being async, allowing the programmer to compose complex logic involving asynchronous operations, leaving the compiler in charge of producing the necessary closures and state machines to implement that logic.

@ereli
ereli / countries.sql
Last active January 6, 2026 21:57 — forked from adhipg/countries.sql
Sql dump of all the Countries, Country Codes, Phone codes. PostgreSQL compatible
CREATE SEQUENCE country_seq;
CREATE TABLE IF NOT EXISTS country (
id int NOT NULL DEFAULT NEXTVAL ('country_seq'),
iso char(2) NOT NULL,
name varchar(80) NOT NULL,
nicename varchar(80) NOT NULL,
iso3 char(3) DEFAULT NULL,
numcode smallint DEFAULT NULL,
phonecode int NOT NULL,
@DejanEnspyra
DejanEnspyra / Obfuscator.swift
Created May 31, 2017 17:51
Obfuscation of hard-coded security-sensitive strings.
//
// Obfuscator.swift
//
// Created by Dejan Atanasov on 2017-05-31.
//
import Foundation
class Obfuscator: AnyObject {
@sebble
sebble / stars.sh
Last active September 15, 2026 19:58
List all starred repositories of a GitHub user.
#!/bin/bash
USER=${1:-sebble}
STARS=$(curl -sI https://api.github.com/users/$USER/starred?per_page=1|egrep '^Link'|egrep -o 'page=[0-9]+'|tail -1|cut -c6-)
PAGES=$((658/100+1))
echo You have $STARS starred repositories.
echo
@oubiwann
oubiwann / appify.sh
Last active September 24, 2026 06:31 — forked from advorak/appify.sh
appify — create the simplest possible Mac app from a shell script (adds an application icon)
#!/usr/bin/env bash
#
# appify — create the simplest possible Mac app from a shell script
#
# v5.0.0
#
# Copyright (c) Thomas Aylott <http://subtlegradient.com/>
# Modified by Mathias Bynens <http://mathiasbynens.be/>
# Modified by Andrew Dvorak <http://OhReally.net/>
# Rewritten by Duncan McGreggor <http://github.com/oubiwann/>
@nfreear
nfreear / leaflet-js-audio-map.html
Last active January 24, 2025 23:42
Leaflet.JS audio-player map example (Mapbox)
<!doctype html> <title> *Leaflet.JS audio-player example </title>
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.0-rc.3/dist/leaflet.css" />
<style>
body { font: .92em sans-serif; color: #333; background: #fefefe; max-width: 80em; margin: 0 auto; }
h1, h2 { font-weight: normal; margin: 0.6em 0; }
.leaflet-popup-content { margin: 9px; }
.leaflet-popup-content-wrapper { border-radius: 6px; }
@alessandrostone
alessandrostone / python
Last active November 12, 2016 17:12
easiest server ever
┌─────────────────────────────────────────────────────────────────────────────┐
│ __ │
│.-----.---.-.-----.--.--.-----.-----| |_ .-----.-----.----.--.--.-----.----.│
│| -__| _ |__ --| | | -__|__ --| _||__ --| -__| _| | | -__| _|│
│|_____|___._|_____|___ |_____|_____|____||_____|_____|__| \___/|_____|__| │
│ |_____| │
│ │
└─────────────────────────────────────────────────────────────────────────────┘
# python -m SimpleHTTPServer 8000 python 2.*

🌁📉🌁🌁⬜⬜⬜🌁⬜🌁📃⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜📃🏭📃🌁📃📃🌁📃📃🏂🏂🎂📃🌁🌁🏭📃🏢🏭🎂📃🏭📃🏢📃⛲⛲🕕⬜📩🔳🍧💈📤🎲📤📉🌁🌁📃🌁⬜📈⬜⬜⬜⬜🌁⬜⬜⬜⬜⬜🌁
⬜🌁🌁⬜⬜⬜🌁🌁🌁📃📃⬜⬜⬜⬜⬜⬜🌁⬜⬜⬜⬜⬜⬜⬜⬜🌁🌁🌁🌁📃📃🌁📃💬🏢💬🌁🌁🌁🌁📃🏭💬💬🏭📃🌁🏭💬🏂⛲⛲📂⬜🌄🌄⚾📱💈📱🕖🏭📈📃🌁⬜⬜📈⬜⬜⬜🌁📝📝⬜⬜⬜⬜⬜
⬜⬜⬜⬜⬜🌁🌁🌁📃🌁🌁🌁🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁📃📃🌁📃🌁📃💬📂🏢🌁📃🏢📃📃💬🏭💬🏢🏢🏢🏢🏂⛲📖⛲🔣📉💬💌🌄📤💈👟🎲🎂🌁🌁🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁⬜⬜⬜⬜
⬜⬜⬜⬜⬜⬜🌁🌁📃📃📃📃📃⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁🏭📃📃🌁📃💬🎂🔳📂🏂📃📉📉🌁⬜⬜🗼🗼🗼🗼📈📃📃📃📃🌁🎂🕓⚾📱💈💈🍜📈⬜🌁📃⬜🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜
⬜⬜⬜⬜⬜⬜🌁📃📃📃📃🏭📃⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁🌁🌁🌁🌁📃🏂🏢📃🕕🍚🌁⬜🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁🌁🎂🔳📧👀🔩🍧🐹🌁🌁🌁⬜⬜📈🌁🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜
⬜⬜⬜⬜⬜🌁💬🏂📃📃🌁📃📃⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁🌁📃🏭🏭🍚🏂🏢🏂🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜📝🕕🎲🔏🔘🐚📩🌁⬜⬜🌁🌁🌁🗼🌁🌁🌁⬜⬜⬜🌁🌁🌁🌁⬜
⬜⬜⬜📜🌁📃🏂🏢📃🏢🏢🏢🏭🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁🌁🌁🌁📈📑🎡🏢🏢📃🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜📃📠😰💌🎹📤⛅🎂⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜📃📃
⬜⬜⬜🌁🏭🏭📃🏢🏢🏢🏢🏢📃⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁🌁🌁⬜⬜🌁🎡⬜🌁🏢🏢🌁🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁💬📜💑🌄📤🏦🔤🏭⬜⬜⬜⬜⬜⬜🌁🌁📈🌁🌁📃🌁🌁🌁🏭💬
⬜🏭📃📃📃📃📃📂🏂🌁💬🏢📃⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁🌁🌁⬜⬜🌁🏭🌁🗼💬🔳📃📃📉🗼🌁🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜🌁🎂📝📜🐹🔘👀🎹💬📝🌁📈🌁🌁🌁📈📃📃📈📃📈📃📃🏭🏭🏂
🌁🌁📃📃📃📃🏢🏂📃📃🌁📃📃🌁⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜⬜📈📃🏂📈💬📃📉🏭📈📃🏭📈📈⬜⬜🌁📃⬜⬜⬜⬜⬜⬜📈🎂🏂📄🎂💌🔘🐚😱🎂📃📈📈🏭📈📈📈📃📈📈📈📈📃🏭📃📃💬

@chockenberry
chockenberry / finder_icons.sh
Last active February 10, 2024 19:05
A simple shell script to turn the Finders desktop icons on and off
#!/bin/sh
defaults read com.apple.finder CreateDesktop > /dev/null 2>&1
enabled=$?
if [ "$1" = "off" ]; then
if [ $enabled -eq 1 ]; then
defaults write com.apple.finder CreateDesktop false
osascript -e 'tell application "Finder" to quit'
open -a Finder