Skip to content

Instantly share code, notes, and snippets.

@driquet
driquet / Task dashboard.md
Created May 20, 2024 12:54
Obsidian Workflow: Templates

[!warning] Past due

not done
due before today
hide recurrence rule
hide tags
group by function task.tags.sort().join(", ")
sort by priority
sort by due
hide task count
@driquet
driquet / semaphore_throttling.go
Last active February 27, 2024 13:30
Throttling in Golang with Semaphore Magic
// This code is licensed under the terms of the MIT license
// Source: https://driquet.info/throttling-semaphore/
package main
type token struct{}
// Semaphore represents a structure able to limit simultaneous access to a shared resource.
type Semaphore struct {
c chan token
}