Skip to content

Instantly share code, notes, and snippets.

@jedberg
jedberg / jedberg_hn_comments
Created August 29, 2025 20:48
all of jedbergs hacker news comments
This file has been truncated, but you can view the full file.
When I was in college, I figured out that the education you get doesn't really change. However, what does change is the people that you are associating with.<p>At the "elite" colleges, there is a greater percentage of smart students, which lends itself to more productive discussions and more difficult tests that force you to challenge yourself. Also, it is like the difference between the regular classes in high school and advanced classes -- in the advanced classes you cover the same material, but with greater breadth and a deeper understanding.<p>And the number 1 biggest advantage of going to an elite college is that you have a much better chance of meeting the world's future movers and shakers -- the people that will be the educational and business leaders of the next generation. That alone is a good reason to go to an elite college.<p>So I have to disagree, and say that there are indeed advantages to going to an elite college, just not the advantages that most people think.
I did read to the end, but I
# Configure the AWS provider
provider "aws" {
region = "us-east-1"
}
# Create the IAM admin user
resource "aws_iam_user" "admin" {
name = "admin"
}
@jedberg
jedberg / gist:143c12c79c7cba916a53f4f26ba1c11d
Last active August 10, 2020 23:50
Some utilities that are handy
# Convert fahrenheit to celcius
def f2c(temp):
c = ((temp-32)/9)*5
return round(c, 2)
# Check if a file is older than some number of seconds.
import time, os, stat
def file_too_old(pathname, seconds=600):
try:
os.stat(pathname)
@jedberg
jedberg / musicmaker.py
Created June 13, 2020 22:06
Make a random music URL
#!/usr/bin/env python
import random
import sys
base_url="https://music-grid.surge.sh/#"
def make_notes(rows=10):
notes_string = ""
# for each row...
for i in range(rows):
@jedberg
jedberg / corn soup.txt
Created March 30, 2020 04:11
Corn soup
Corn Soup
4 ears corn (or 1.5 cans or 3 cups frozen corn)
One can creamed corn
One can whole corn.
1 Tbsp extra virgin olive oil
2 tbsp kosher/sea salt (use half for table salt)
¼ tsp paprika
½ onion diced
2 Tbsp unsalted butter
#!/usr/bin/env python
from datetime import datetime as dt
from datetime import timedelta as td
from calendar import monthrange
import calendar
def make_bar(r):
return (int(round(r/10))*"*").ljust(10,'O')

Keybase proof

I hereby claim:

  • I am jedberg on github.
  • I am jedberg (https://keybase.io/jedberg) on keybase.
  • I have a public key whose fingerprint is EC1E 7C90 FEA6 613B B7FC B131 3522 6FA6 1622 9E7B

To claim this, I am signing this object:

@jedberg
jedberg / gist:4a048040c2c3c14452a8
Created February 11, 2015 21:37
my .screenrc
hardstatus alwayslastline "%{= kr}%?%-Lw%?%{= rw}%n*%f %t%?(%u)%?%{= kr}%?%+Lw%?%{= kr} %=%H %l | %c %m/%d/%Y"
escape `a
term xterm-color
vbell off
startup_message off
screen -t mail
screen -t root
screen -t local
@jedberg
jedberg / gist:1469730
Created December 12, 2011 23:56
Sample usage of DescribeInstanceStatus
regions = boto.ec2.regions()
for reg in regions:
conn = reg.connect()
instances = conn.get_all_instance_status()
for inst in instances:
if inst.events:
print "%s: %s\t%s" % (inst.id,
inst.events[0].description,
inst.events[0].not_after)