Skip to content

Instantly share code, notes, and snippets.

View ivanvanderbyl's full-sized avatar
🏝️

Ivan Vanderbyl ivanvanderbyl

🏝️
View GitHub Profile
Wordlist ver 0.732 - EXPECT INCOMPATIBLE CHANGES;
acrobat africa alaska albert albino album
alcohol alex alpha amadeus amanda amazon
america analog animal antenna antonio apollo
april aroma artist aspirin athlete atlas
banana bandit banjo bikini bingo bonus
camera canada carbon casino catalog cinema
citizen cobra comet compact complex context
credit critic crystal culture david delta
dialog diploma doctor domino dragon drama
const puppeteer = require('puppeteer');
const { expect } = require('chai');
describe('Duck Duck Go search using basic Puppeteer', () => {
let browser;
let page;
beforeEach(async () => {
browser = await puppeteer.launch();
[{"id":"1","name":"Sky Diving","morts":10},{"id":"2","name":"Motocycling","morts":10},{"id":"3","name":"Drink Driving","morts":15},{"id":"4","name":"Walking","morts":1}]
@ivanvanderbyl
ivanvanderbyl / CloudSQL-vs-Crunchy-vs-AlloyDB.md
Last active July 26, 2022 23:30
Benchmarks comparing Postgres hosting options on GCP using pgbench.

All tests conducted in us-central1 on GCP from an instance running in us-central1-a

Initialized with:

pgbench -i --foreign-keys -s 100

Tests run with:

@ivanvanderbyl
ivanvanderbyl / gist:4222308
Created December 6, 2012 06:55
Postgres 9.1 to 9.2 upgrade guide for Ubuntu 12.04
sudo add-apt-repository ppa:pitti/postgresql
sudo apt-get update
sudo apt-get install postgresql-9.2 postgresql-server-dev-9.2 postgresql-contrib-9.2
sudo su -l postgres
psql -d template1 -p 5433
CREATE EXTENSION IF NOT EXISTS hstore;
CREATE EXTENSION IF NOT EXISTS "uuid-ossp";
service postgresql stop
/usr/lib/postgresql/9.2/bin/pg_upgrade -b /usr/lib/postgresql/9.1/bin -B /usr/lib/postgresql/9.2/bin -d /var/lib/postgresql/9.1/main/ -D /var/lib/postgresql/9.2/main/ -O "-c config_file=/etc/postgresql/9.2/main/postgresql.conf" -o "-c config_file=/etc/postgresql/9.1/main/postgresql.conf"
package ptr
// Safe reads the point and returns the zero value of the type of
// the pointer is nil, otherwise it returns the value of the pointer.
// Usage:
// ptr.Safe(obj.SomePointerField)
func Safe[T any](v *T) T {
if v == nil {
return *new(T)
}
const path = require('path')
const semver = require('semver')
const fs = require('fs')
const prettier = require('prettier')
function main() {
let manifest = path.resolve('./public/manifest.json')
let manifestData = require(manifest)
let prevVersion = manifestData.version
// Stub out browser interface
interface Browser {
wait(_: any): Promise<void>
fill(selector: string, text: string): Promise<void>
}
export interface StepBase {
(stepName: string, options: StepOptions, testFn: TestFn): void
(stepName: string, testFn: TestFn): void
(stepName: string, ...optionsOrFn: any[]): void

This is a test of inline code

{
"firstName": "Teddy",
"lastName": "Smith",
"mobile": "${Random(0000000000,9999999999)}",
"email": "${RandomString(10,abcdefghijklmnopqrstuvwxyz1234567890)}@domain.ext",
"currencyCode": "AUD",
"currentMembershipStatus": "LVL 1 Member"
}