Skip to content

Instantly share code, notes, and snippets.

@arielazem
arielazem / vault-golang-login
Created February 4, 2025 05:08 — forked from jun06t/vault-golang-login
Golang Vault Login Sample
package main
import (
"encoding/json"
"fmt"
"net/http"
"time"
"github.com/hashicorp/vault/api"
"github.com/hashicorp/vault/builtin/credential/aws"
@arielazem
arielazem / grokking_to_leetcode.md
Created October 4, 2024 06:25 — forked from tykurtz/grokking_to_leetcode.md
Grokking the coding interview equivalent leetcode problems

GROKKING NOTES

I liked the way Grokking the coding interview organized problems into learnable patterns. However, the course is expensive and the majority of the time the problems are copy-pasted from leetcode. As the explanations on leetcode are usually just as good, the course really boils down to being a glorified curated list of leetcode problems.

So below I made a list of leetcode problems that are as close to grokking problems as possible.

Pattern: Sliding Window

@arielazem
arielazem / close_notifications_applescript.js
Created March 6, 2023 19:06 — forked from lancethomps/close_notifications_applescript.js
AppleScript to close all notifications on macOS Big Sur, Monterey, and Ventura
function run(input, parameters) {
const appNames = [];
const skipAppNames = [];
const verbose = true;
const scriptName = "close_notifications_applescript";
const CLEAR_ALL_ACTION = "Clear All";
const CLEAR_ALL_ACTION_TOP = "Clear";
@arielazem
arielazem / inventory.sh
Created February 17, 2020 21:09
Dynamic nomad-based ansible inventory
#!/bin/bash
### Generate dynamic nomad-based ansible inventory
# Script to be executed on Ansible server
# It will query Nomad API to retrieve the list of running servers
# based on that it will group them by node class and additional groups
# Give the script as an inventory file input to ansible
# Usage:
# ansible web -i inventory.sh -m ping