Skip to content

Instantly share code, notes, and snippets.

View pmuens's full-sized avatar

Philipp Muens pmuens

View GitHub Profile
@moncho
moncho / boostrap_faas_arm.md
Last active May 12, 2017 19:33 — forked from alexellis/boostrap_faas_arm.md
FaaS serverless framework bootstrap for Raspberry Pi

FaaS serverless framework bootstrap for Raspberry Pi

This bootstraps FaaS onto your Raspberry Pi or ARM board with Docker.

Any Linux/UNIX process can be made a serverless function. Communication with functions is via an API gateway with an easy to use UI portal.

https://github.com/alexellis/faas

Here's the one-shot equivalent from the TestDrive guide

@Rich-Harris
Rich-Harris / prepack-svelte.md
Last active May 19, 2022 11:02
Is Prepack like Svelte?

Note: I'm not involved in Prepack in any way — please correct me if I say anything incorrect below!

A few people have asked me if Prepack and Svelte are similar projects with similar goals. The answer is 'no, they're not', but let's take a moment to explore why.

What is Prepack?

Prepack describes itself as a 'partial evaluator for JavaScript'. What that means is that it will run your code in a specialised interpreter that, rather than having some effect on the world (like printing a message to the console), will track the effects that would have happened and express them more directly.

So for example if you give it this code...

@cmatskas
cmatskas / serverlessVariables.ps1
Created April 29, 2017 07:47
Setting up Serverless variables
# Bash
export azureSubId='<subscriptionId>'
export azureServicePrincipalTenantId='<tenantId>'
export azureServicePrincipalClientId='<servicePrincipalName>'
export azureServicePrincipalPassword='<password>'
# Poweshell
$env:azureSubId='<your subscription Id>'
$env:azureServicePrincipalTenantId='<your Azure Tenant ID>'
$env:azureServicePrincipalClientId='<your Azure Application ID>'
@yomimono
yomimono / mirageos-unikernels-miragesdk.md
Last active May 16, 2017 07:11
mirageos/unikernels update from docker internal systems summit, 20 april 2017

MirageOS/Unikernels (but secretly something else)

  • speaking now: @mindypreston (@yomimono on github)

Very Quick MirageOS Update

  • we released version 3.0 in February
  • tl;dr: supports KVM via the solo5 project
    • better errors
  • better logs
@aparrish
aparrish / understanding-word-vectors.ipynb
Last active May 8, 2025 14:50
Understanding word vectors: A tutorial for "Reading and Writing Electronic Text," a class I teach at ITP. (Python 2.7) Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@mthenw
mthenw / aws_whitelist.json
Last active April 20, 2017 21:12
List of aws-sdk functions tracked by aws-xray-sdk-core's captureAWS
{
"services": {
"dynamodb": {
"operations": {
"batchGetItem": {
"request_descriptors": {
"RequestItems": {
"get_keys": true,
"rename_to": "table_names"
}
@HyperBrain
HyperBrain / package-plugin-lifecycle.md
Last active November 24, 2023 04:56
Serverless - Package/Deploy plugin lifecycle changes

Overview

Currently the Serverless framework only offers lifecycle events that are bound to commands and also are very coarse. Each core plugin only exposes the events that are defined by the framework. This is suboptimal for plugin authors as they want to hook special events within the deployment process.

The PR adds fine grained lifecycles to the AWS deployment process (see below for the current implementation process) and makes the package/deploy plugin implementation non-breaking.

@myshov
myshov / function_invocation.js
Last active August 19, 2024 12:23
11 Ways to Invoke a Function
console.log(1);
(_ => console.log(2))();
eval('console.log(3);');
console.log.call(null, 4);
console.log.apply(null, [5]);
new Function('console.log(6)')();
Reflect.apply(console.log, null, [7])
Reflect.construct(function(){console.log(8)}, []);
Function.prototype.apply.call(console.log, null, [9]);
Function.prototype.call.call(console.log, null, 10);
@depp
depp / problem.cpp
Last active December 21, 2021 19:04
A Faster Solution
// Faster solution for:
// http://www.boyter.org/2017/03/golang-solution-faster-equivalent-java-solution/
// With threading.
// g++ -std=c++11 -Wall -Wextra -O3 -pthread
// On my computer (i5-6600K 3.50 GHz 4 cores), takes about ~160 ms after the CPU
// has warmed up, or ~80 ms if the CPU is cold (due to Turbo Boost).
// How it works: Start by generating a list of losing states -- states where the
// game can end in one turn. Generate a new list of states by running the game
@johncmckim
johncmckim / package.json
Last active May 1, 2017 17:31
Prune Lambda Functions - PLEASE REVIEW AND USE AT YOUR OWN RISK
{
"dependencies": {
"aws-sdk": "^2.7.10",
"bluebird": "^3.4.6",
"lodash": "^4.17.2",
"moment": "^2.17.1"
}
}