Skip to content

Instantly share code, notes, and snippets.

View isaacgr's full-sized avatar

Isaac isaacgr

View GitHub Profile
@danawoodman
danawoodman / Using Golang templ with the Echo framework.md
Last active July 15, 2025 09:57
Using Golang templ with the Echo framework

Using Golang templ with the Echo framework

templ is a great view framework but there is no clear documentation (as of writing) showing how to use it with the Echo web framework. This short guide should show you how to set it up:

Install dependencies

Install templ and echo:

go get github.com/a-h/templ
@cm3z4
cm3z4 / config.txt
Last active May 8, 2025 23:38
RetroPie v4.8 Audio Fix for GPi CASE
# For more options and information see
# http://www.raspberrypi.org/documentation/configuration/config-txt.md
# Some settings may impact device functionality. See link above for details
# uncomment if you get no picture on HDMI for a default "safe" mode
#hdmi_safe=1
# uncomment this if your display has a black border of unused pixels visible
# and your display can output without overscan
#disable_overscan=1
@aymericbeaumet
aymericbeaumet / delete-likes-from-twitter.md
Last active September 13, 2025 02:19
[Recipe] Delete all your likes/favorites from Twitter

Ever wanted to delete all your likes/favorites from Twitter but only found broken/expensive tools? You are in the right place.

  1. Go to: https://twitter.com/{username}/likes
  2. Open the console and run the following JavaScript code:
setInterval(() => {
  for (const d of document.querySelectorAll('div[data-testid="unlike"]')) {
    d.click()
 }
@miharekar
miharekar / quotes.json
Last active November 29, 2023 09:34
Stoic Quotes JSON
This file has been truncated, but you can view the full file.
@amitripshtos
amitripshtos / exception_middleware.py
Created July 18, 2017 08:56
Exception handling middleware for aiohttp (python 3.5)
def json_error(status_code: int, exception: Exception) -> web.Response:
"""
Returns a Response from an exception.
Used for error middleware.
:param status_code:
:param exception:
:return:
"""
return web.Response(
status=status_code,
@v0lkan
v0lkan / docker-i-t-trivia.md
Last active July 25, 2023 04:35
docker run -i -t
docker run -i -t --name nodejs ubuntu:latest /bin/bash

So here, -i stands for interactive mode and -t will allocate a pseudo terminal for us.

Some more trivia about these flags.

@bishboria
bishboria / springer-free-maths-books.md
Last active September 14, 2025 20:30
Springer made a bunch of books available for free, these were the direct links
@spalladino
spalladino / mysql-docker.sh
Created December 22, 2015 13:47
Backup and restore a mysql database from a running Docker mysql container
# Backup
docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql
# Restore
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE
@whisperity
whisperity / daemon.sh
Last active March 15, 2019 01:05
Start arbitrary shell script as a background daemon from init.d
#!/bin/sh
### BEGIN INIT INFO
# Provides: scriptname
# Required-Start:
# Required-Stop:
# Default-Start: 2 3 4 5
# Default-Stop: S 0 1 6
# Short-Description: Script short description
# Description: Starts/Stops the script
@nathansmith
nathansmith / web-design-development-learning-resources.md
Last active August 2, 2025 01:31
Resources for learning web design & front-end development