Skip to content

Instantly share code, notes, and snippets.

View naltun's full-sized avatar
🕊️
Free/Libre Software to the rescue

Noah Altunian naltun

🕊️
Free/Libre Software to the rescue
View GitHub Profile
@timvisee
timvisee / falsehoods-programming-time-list.md
Last active May 31, 2025 21:15
Falsehoods programmers believe about time, in a single list

Falsehoods programmers believe about time

This is a compiled list of falsehoods programmers tend to believe about working with time.

Don't re-invent a date time library yourself. If you think you understand everything about time, you're probably doing it wrong.

Falsehoods

  • There are always 24 hours in a day.
  • February is always 28 days long.
  • Any 24-hour period will always begin and end in the same day (or week, or month).
@attacus
attacus / riot-matrix-workshop.md
Last active April 8, 2025 08:18
Create your own encrypted chat server with Riot and Matrix

This guide is unmaintained and was created for a specific workshop in 2017. It remains as a legacy reference. Use at your own risk.

Running your own encrypted chat service with Matrix and Riot

Workshop Instructor:

This workshop is distributed under a CC BY-SA 4.0 license.

What are we doing here?

@baweaver
baweaver / ruby_books.md
Last active April 11, 2025 11:21
A list of books for learning and expanding on your Ruby knowledge.

Ruby Book List

Learning Ruby

You're taking your first steps into Ruby

A good introduction to programming in general. Easy on newer programmers.

@JayGoldberg
JayGoldberg / is_ipv4.go
Last active May 12, 2019 12:50
determines if a string is a valid IPv4 address in golang, but the correct way to do this is to use net.ParseIP() and check for err
package main
import (
"fmt"
"strconv"
)
import "strings"
func is_ipv4(host string) bool {
parts := strings.Split(host, ".")
####### License: MIT
"""MIT License
Copyright (c) 2015 Aaron Hall
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
@inaz2
inaz2 / traceroute.py
Last active June 26, 2024 14:19
Python implementation of traceroute
# references:
# Learning by doing: Writing your own traceroute in 8 easy steps (Ksplice Blog)
# https://blogs.oracle.com/ksplice/entry/learning_by_doing_writing_your
import sys
import socket
def traceroute(dest_addr, max_hops=30, timeout=0.2):
proto_icmp = socket.getprotobyname('icmp')
proto_udp = socket.getprotobyname('udp')
@mcandre
mcandre / brew-clear-cache.md
Last active February 25, 2025 20:35
Homebrew: Clearing cache and updating Casks

Clear Homebrew cache

$ brew cleanup --prune=all

Update Casks

Once the cache is cleared, brew cask will see the latest versions of all Casks.

@roachhd
roachhd / README.md
Last active May 26, 2025 16:15
Basics of BrainFuck

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

BrainFuck Programming Tutorial by: Katie

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

INTRODUCTION

@thebucknerlife
thebucknerlife / authentication_with_bcrypt_in_rails_4.md
Last active March 12, 2025 18:03
Simple Authentication in Rail 4 Using Bcrypt

#Simple Authentication with Bcrypt

This tutorial is for adding authentication to a vanilla Ruby on Rails app using Bcrypt and has_secure_password.

The steps below are based on Ryan Bates's approach from Railscast #250 Authentication from Scratch (revised).

You can see the final source code here: repo. I began with a stock rails app using rails new gif_vault

##Steps