Skip to content

Instantly share code, notes, and snippets.

View mlgarchery's full-sized avatar
🧙‍♂️
Building mammouth.ai

Martial Garchery mlgarchery

🧙‍♂️
Building mammouth.ai
View GitHub Profile
@mlgarchery
mlgarchery / gist:0eef9570a35896e72ae4ed3ab12e9b77
Last active September 12, 2025 10:52
Note de bas de page markdown

Here is a simple footnote1.

A footnote can also have multiple lines2.

Footnotes

  1. My reference.

  2. To add line breaks within a footnote, prefix new lines with 2 spaces. This is a second line.

@mlgarchery
mlgarchery / better_git_config.md
Last active April 11, 2025 13:19
Better git aliases for `git log` and `git branch`

When you merge branches, you can be confused by the output git log gives you sometimes. The main issue is that by default git log use chronological order and not topological order --topo-order, which is the order of the commits when they appeared on their respective branch. This is disturbing to me. Look at it by youself:

image

The idea is to replace your daily use of git log with git l that use the --topo-order option.

@mlgarchery
mlgarchery / SQLITE->Neon.md
Last active March 25, 2025 16:45
Migrate from a SQLite database to a Postgres database

Migrating from SQLite (D1) to PostgreSQL (Neon)

As D1, a sqlite-compatible DB from Cloudflare, is limited to a maximum of 10GB, I needed to migrate my database to one that is famously capable of handling a numerous number of rows.

To export it I used the wrangler CLI:

npx wrangler d1 export my-db --remote --output="db.sql"