Skip to content

Instantly share code, notes, and snippets.

View jeffdev11's full-sized avatar

Jefferson jeffdev11

View GitHub Profile
@jeffdev11
jeffdev11 / index.md
Created April 25, 2023 04:52 — forked from GavinRay97/index.md
Hasura organization permissions

Introduction

This document outlines how to model a common organization-based permission system in Hasura. Let's assume that you have some table structure like the following:

Table Name Columns Foreign Keys
User id, name, email
Organization User id, user_id, organization_id user_id -> user.id, organization_id -> organization.id
Organization id, name
@jeffdev11
jeffdev11 / README.md
Last active August 15, 2023 21:30 — forked from midnightcodr/README.md
websocket performance test using ws
npm install yargs ws
node server.js
node client.js
@jeffdev11
jeffdev11 / write-two-millio-rows-of-csv-data-with-node-cluster.js
Created August 15, 2023 20:31 — forked from midnightcodr/write-two-millio-rows-of-csv-data-with-node-cluster.js
How to write two million rows of csv data using faker.js and node cluster
const faker = require('faker')
// const N = 30
const N = 2000000
const fs = require('fs')
const record = () => {
// faker.fake(
// '{{name.lastName}},{{name.lastName}},{{address.city}},{{address.county}},{{address.zipCode}},{{hacker.adjective}}\n'
return [
faker.name.firstName(),
faker.name.lastName(),

Oh my zsh.

Oh My Zsh

Install ZSH.

sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh

Install Oh my ZSH.

@jeffdev11
jeffdev11 / update-git.sh
Created October 29, 2024 20:20 — forked from YuMS/update-git.sh
Update git to latest version on Ubuntu
#!/bin/bash
sudo add-apt-repository -y ppa:git-core/ppa
sudo apt-get update
sudo apt-get install git -y