Skip to content

Instantly share code, notes, and snippets.

View copyleftdev's full-sized avatar
:octocat:
1337

L337[b211b7af]SIGMA copyleftdev

:octocat:
1337
View GitHub Profile
@ruanbekker
ruanbekker / aws_ssm_get_parameter.md
Created January 31, 2018 14:41
Getting Secrets from SSM using GetParameter Example with Python and Boto3

Bash Environment Example with SSM to get Parameter Values using GetParameter:

IAM Policy:

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "Stmt1517398919242",
@rushilgupta
rushilgupta / GoConcurrency.md
Last active May 14, 2024 06:30
Concurrency in golang and a mini Load-balancer

INTRO

Concurrency is a domain I have wanted to explore for a long time because the locks and the race conditions have always intimidated me. I recall somebody suggesting concurrency patterns in golang because they said "you share the data and not the variables".

Amused by that, I searched for "concurrency in golang" and bumped into this awesome slide by Rob Pike: https://talks.golang.org/2012/waza.slide#1 which does a great job of explaining channels, concurrency patterns and a mini-architecture of load-balancer (also explains the above one-liner).

Let's dig in:

Goroutines

@copyleftdev
copyleftdev / wikitodocx.py
Created April 5, 2016 17:47
convert wiki from text format to docx
import os
from docx import Document
import uuid
def getDocList(rootFoldr):
filelst = []
for(dirpath, _, files) in os.walk(rootFoldr):
for filename in files:
filepath = os.path.join(dirpath, filename)
@xero
xero / python-logo-ascii.txt
Created August 31, 2012 16:02
python logo ascii art
..:77I777777777777777777777I. .
..?77777777777777777777777777777$+..
. ~7777777I7777777777777777777777777$~..
.7I7777...7777777777777777777777777$7+.
.?7777.. ..77777777777777777777777$$7.
.77777 777777777777777777777$$$$$I
.77777.. ...7777777777777777777$$$$$$$$
.7777777 .77$777777777777777777$$$$$$$$
.77777777777777777777777777777$$$$$$$$$$
.77777777777777777777777777$$$$$$$$$$$$$