Skip to content

Instantly share code, notes, and snippets.

@lambrospetrou
lambrospetrou / tailwind.config.js
Created August 29, 2024 07:45 — forked from eduardolat/tailwind.config.js
Regex for TailwindCSS + Gomponents
/** @type {import('tailwindcss').Config} */
module.exports = {
// Change this to your project source folder
content: ['./web/**/*.go'],
plugins: [],
theme: {
extend: {},
}
}
@lambrospetrou
lambrospetrou / falsehoods-programming-time-list.md
Created August 4, 2024 10:17 — forked from timvisee/falsehoods-programming-time-list.md
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).
@lambrospetrou
lambrospetrou / unixhttpc.go
Last active July 8, 2017 10:13 — forked from teknoraver/unixhttpc.go
HTTP over Unix domain sockets in golang
package main
import (
"context"
"flag"
"fmt"
"io"
"net"
"net/http"
"os"
@lambrospetrou
lambrospetrou / node-and-npm-in-30-seconds.sh
Created May 20, 2016 23:16 — forked from isaacs/node-and-npm-in-30-seconds.sh
Use one of these techniques to install node and npm without having to sudo. Discussed in more detail at http://joyeur.com/2010/12/10/installing-node-and-npm/ Note: npm >=0.3 is *safer* when using sudo.
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc
. ~/.bashrc
mkdir ~/local
mkdir ~/node-latest-install
cd ~/node-latest-install
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1
./configure --prefix=~/local
make install # ok, fine, this step probably takes more than 30 seconds...
curl https://www.npmjs.org/install.sh | sh