Skip to content

Instantly share code, notes, and snippets.

View Oyelowo's full-sized avatar

Oyelowo

  • North America
View GitHub Profile
@Oyelowo
Oyelowo / grokking_to_leetcode.md
Created September 17, 2023 18:10 — 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

@Oyelowo
Oyelowo / err.md
Last active May 8, 2023 17:41
ise aws bucket

I have a bucket ra.kama.com. how can i investigate why bucket uses ACLs and if i can change the permissions somehow on AWS:

"aws: cloudformation:stack-name": "prod-go-subdomain-cdk-stack' ChatGPT To investigate why a bucket is using ACLs and to change its permissions on AWS, you can follow these steps:

Go to the Amazon S3 console and select the bucket "ra.kama.com" that you want to investigate.

Click on the "Permissions" tab and review the current ACLs (Access Control List) that are applied to the bucket. ACLs determine who can access the objects in the bucket and what level of access they have.

@Oyelowo
Oyelowo / tmux-cheat-sheet.md
Created February 13, 2023 16:06 — forked from michaellihs/tmux-cheat-sheet.md
tmux Cheat Sheet
@Oyelowo
Oyelowo / init.lua
Created January 31, 2023 11:23
my-neovim-setup
-- AstroNvim Configuration Table
-- All configuration changes should go inside of the table below
-- You can think of a Lua "table" as a dictionary like data structure the
-- normal format is "key = value". These also handle array like data structures
-- where a value with no key simply has an implicit numeric key
local config = {
-- Configure AstroNvim updates
@Oyelowo
Oyelowo / argo.yaml
Last active December 13, 2022 19:29
This file has been truncated, but you can view the full file.
definitions:
io.argoproj.common.Amount:
description: Amount represent a numeric amount.
type: number
io.argoproj.common.Backoff:
description: Backoff for an operation
properties:
duration:
$ref: '#/definitions/io.argoproj.common.Int64OrString'
@Oyelowo
Oyelowo / esmodule-imports-js-extension_append
Created November 30, 2022 16:04
Use this to rename imports to include .js extensions for new esmodule import format
Search with in vscode:
(\bfrom\s+["']\..*)(["'])
replace with:
$1.js$2
@Oyelowo
Oyelowo / argoEventsSchema.yaml
Created November 3, 2022 04:06
Argo events json schema
This file has been truncated, but you can view the full file.
$id: http://events.argoproj.io/events.json
$schema: http://json-schema.org/schema#
definitions:
io.argoproj.common.Amount:
description: Amount represent a numeric amount.
type: number
io.argoproj.common.Backoff:
description: Backoff for an operation
properties:
@Oyelowo
Oyelowo / k3s-on-multipass-vm-m1-mac.sh
Created October 17, 2022 21:41
Launch a lightweight virtual machine on M1 MAC with k3s installed: https://github.com/canonical/multipass
# Virtual machine multipass
brew install --cask multipass
multipass launch --name k3s --mem 4G --disk 40G
multipass shell k3s
# From inside the VM run:
ubuntu@k3s:~$ curl -sfL https://get.k3s.io | sh -
@Oyelowo
Oyelowo / README.md
Created June 25, 2022 12:37 — forked from exupero/README.md
Alias a domain to a local port (Mac)

I run a lot of web servers for different projects, all of them on different ports. Generally I start with port 8000 and increment from there as I spin up new servers, but it became tiresome to remember what projects were running on which ports and what the next available port was.

/etc/hosts won't let you specify a port, but a combination of aliasing 127.0.0.1 to 127.0.0.X, forwarding ports from 8000 to 80, and adding the 127.0.0.X IP under an alias in /etc/hosts did work.

This script finds the next available value of X, aliases it with ifconfig, forwards the given port to port 80 with ipfw, and adds a new entry to /etc/hosts that aliases the IP to the domain you want.

Now I can add a server alias with sudo domain-alias funproject 8000, run the web server at 127.0.0.X:8000, and load up http://funproject/ in my browser.

(Because I needed it to work on a Mac, I couldn't use iptables. ipfw seems to work, though its manpage claims it's deprecated and pfctl is the way to go. I wasn't able to figure

@Oyelowo
Oyelowo / blog1
Created June 1, 2022 15:12
Blogpost1
The nuances of Rust's `impl Trait` syntactic sugar
A brief discussion in a discord channel about language design is the motivation behind this writing.
What happens when you have gthe function below:
```rs
trait Speed { }
fn get_oyelowo(arg1: impl Speed , arg2: impl Speed) {