Skip to content

Instantly share code, notes, and snippets.

View elithrar's full-sized avatar
🌐
Helping make the Internet better.

Matt Silverlock elithrar

🌐
Helping make the Internet better.
View GitHub Profile

week 1 - one-offs

  • [ ] level to 60
  • [ ] covenant story quests
    • [ ] unlocking buildings & mission table
  • [ ] torghast intro quests
  • [ ] level your professions
  • [ ] obtain available legendary recipes (drop locations)
  • [ ] obtain available conduits (drop locations)
import SwiftUI
import MapKit
import PlaygroundSupport
struct Location {
var title: String
var latitude: Double
var longitude: Double
}
(function(){function t(e,r,n){function i(s,a){if(!r[s]){if(!e[s]){var c="function"==typeof require&&require;if(!a&&c)return c(s,!0);if(o)return o(s,!0);var u=new Error("Cannot find module '"+s+"'");throw u.code="MODULE_NOT_FOUND",u}var l=r[s]={exports:{}};e[s][0].call(l.exports,function(t){var r=e[s][1][t];return i(r||t)},l,l.exports,t,e,r,n)}return r[s].exports}for(var o="function"==typeof require&&require,s=0;s<n.length;s++)i(n[s]);return i}return t})()({1:[function(t,e,r){
// Require our cheerio dependency.
const cheerio = t("cheerio");
// Add the fetch listener.
addEventListener('fetch', event => {
event.respondWith(fetchAndModify(event.request))
})
@jessfraz
jessfraz / boxstarter.ps1
Last active July 7, 2024 22:46
Boxstarter Commands for a new Windows box.
# Description: Boxstarter Script
# Author: Jess Frazelle <jess@linux.com>
# Last Updated: 2017-09-11
#
# Install boxstarter:
# . { iwr -useb http://boxstarter.org/bootstrapper.ps1 } | iex; get-boxstarter -Force
#
# You might need to set: Set-ExecutionPolicy RemoteSigned
#
# Run this boxstarter by calling the following from an **elevated** command-prompt:
##
## HTTP Router benchmarks -- August 31st, 2017 running Go 1.9.0
##
## This benchmark suite is based on https://github.com/julienschmidt/go-http-routing-benchmark
## using the most up-to-date version of each pkg as of today. Each router has their own
## pros and cons, so consider the designs of each router to suit your application.
##
[peter@pak ~/Dev/go/src/github.com/pkieltyka/go-http-routing-benchmark]$ go test -v -bench="Chi" .
@chrisveness
chrisveness / crypto-pbkdf2.js
Last active December 21, 2023 19:20
Uses the SubtleCrypto interface of the Web Cryptography API to hash a password using PBKDF2, and validate a stored password hash against a subsequently supplied password. Note that both bcrypt and scrypt offer better defence against ASIC/GPU attacks, but are not available within WebCrypto.
/**
* Returns PBKDF2 derived key from supplied password.
*
* Stored key can subsequently be used to verify that a password matches the original password used
* to derive the key, using pbkdf2Verify().
*
* @param {String} password - Password to be hashed using key derivation function.
* @param {Number} [iterations=1e6] - Number of iterations of HMAC function to apply.
* @returns {String} Derived key as base64 string.
*
var sumoURL = process.env.SUMO_ENDPOINT,
zoneID = process.env.CLOUDFLARE_ZONE_ID,
cloudflareAuthEmail = process.env.CLOUDFLARE_AUTH_EMAIL,
cloudflareAuthKey = process.env.CLOUDFLARE_AUTH_KEY,
sourceCategoryOverride = process.env.SOURCE_CATEGORY_OVERRIDE || 'none',
sourceHostOverride = process.env.SOURCE_HOST_OVERRIDE || 'api.cloudflare.com',
sourceNameOverride = process.env.SOURCE_NAME_OVERRIDE || zoneID;
var https = require('https');
var zlib = require('zlib');
func merge(l, r []int) []int {
ret := make([]int, 0, len(l)+len(r))
for len(l) > 0 || len(r) > 0 {
if len(l) == 0 {
return append(ret, r...)
}
if len(r) == 0 {
return append(ret, l...)
}
if l[0] <= r[0] {
@orcaman
orcaman / MergeSort.go
Created January 1, 2017 20:39
MergeSort.go
// MergeSort sorts the slice s using Merge Sort Algorithm
func MergeSort(s []int) []int {
if len(s) <= 1 {
return s
}
n := len(s) / 2
var l []int
@jessicard
jessicard / macarons.md
Last active February 3, 2023 03:53
Macarons!

Basic macaron shell recipe

  • This will make approximately 100 shells, or about 4 dozen cookies
  • When practicing, I generally half this recipe to only make 1 sheet of cookies
  • When making macarons, you will generally flavor the filling but not the shells
  • You want to make the macarons the day before the event. You will store them in the refrigerator over night, and then take them out a few hours before to come to room temperature. This is because macarons are best when "ripened", or allowed to sit for at least one night and have the filling seep into the shells a bit. Otherwise, straight out of the oven, they can be too crunchy or hard
  • Macarons shells freeze well! Filled macarons can also freeze well depending on the filling. Buttercream fillings freeze great. Put the cookies into an airtight container before freezing
  • Everyones baking temperature and baking time vary depending on their oven - you might have to experiment a bit!
  • _I always separate egg whites myself by cracking the egg, p