Skip to content

Instantly share code, notes, and snippets.

/*
Erica Sadun, http://ericasadun.com
Cross Platform Defines
Apple Platforms Only
Will update to #if canImport() when available
*/
@yossorion
yossorion / what-i-wish-id-known-about-equity-before-joining-a-unicorn.md
Last active April 2, 2025 01:50
What I Wish I'd Known About Equity Before Joining A Unicorn

What I Wish I'd Known About Equity Before Joining A Unicorn

Disclaimer: This piece is written anonymously. The names of a few particular companies are mentioned, but as common examples only.

This is a short write-up on things that I wish I'd known and considered before joining a private company (aka startup, aka unicorn in some cases). I'm not trying to make the case that you should never join a private company, but the power imbalance between founder and employee is extreme, and that potential candidates would

namespace ServiceCommon.Utilities
{
using System;
using System.Collections;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Orleans.Runtime;
@mltucker
mltucker / playstore.go
Created December 16, 2016 19:20
Standalone (Play Store only) go-iap for GAE
package yourgaeproject
// go-iap doesn't work for GAE since we need to use urlfetch
//
// Copy this source file to your GAE to your project.
//
// The API is mostly the same as go-iap. I prefixed some stuff since this file lives within my GAE project's package.
// client, err := PlaystoreNew(ctx, jsonKey)
//
// purchase, err := client.VerifyProduct("com.you.yourapp", productId, purchaseToken)
@lazymutt
lazymutt / report_critical_update_versions.py
Last active May 3, 2023 08:01
parses update versions, some managed by `sudo softwareupdate --background-critical`, ported from an applescript found at https://www.jamf.com/jamf-nation/discussions/19111/xprotect-status-extension-attribute
#!/usr/bin/python
# Copyright (c) 2019 University of Utah Student Computing Labs. ################
# All Rights Reserved.
#
# Permission to use, copy, modify, and distribute this software and
# its documentation for any purpose and without fee is hereby granted,
# provided that the above copyright notice appears in all copies and
# that both that copyright notice and this permission notice appear
# in supporting documentation, and that the name of The University
using UnityEngine;
using System.Collections;
using System.Runtime.InteropServices;
[ExecuteInEditMode]
public class ParticlePerlinTurbulence
: MonoBehaviour
{
private ParticleSystem system;
private ParticleSystem.Particle[] particles;
@JasonKleban
JasonKleban / LiteEvent.ts
Last active November 5, 2024 18:59
TypeScript LiteEvent Events implementation
interface ILiteEvent<T> {
on(handler: { (data?: T): void }) : void;
off(handler: { (data?: T): void }) : void;
}
class LiteEvent<T> implements ILiteEvent<T> {
private handlers: { (data?: T): void; }[] = [];
public on(handler: { (data?: T): void }) : void {
this.handlers.push(handler);
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
@Jpoliachik
Jpoliachik / index.ios.js
Last active August 17, 2021 10:27
ReactNative LayoutAnimation Example
'use strict';
import React, {
AppRegistry,
Component,
StyleSheet,
Text,
View,
TouchableOpacity,
LayoutAnimation,
} from 'react-native';
@nkjzm
nkjzm / RichtextAlphaAdapter.cs
Last active March 15, 2016 20:51
UnityでTextのアルファ値をリッチテキスト使用時にも適用するスクリプト (UniRx未使用バージョン)
using UnityEngine;
using UnityEngine.UI;
using System;
using System.Text.RegularExpressions;
using System.Collections;
public class RichtextAlphaAdapter : MonoBehaviour
{
private Text text;
private Regex regex;