aboutsummaryrefslogtreecommitdiff
path: root/scripts/sdep-clear
blob: 98599ef7cfc1923e2d8d2e4f155c4d7d1751c6ca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/sh

# Removes old events from specified file (default: $sdepdata/once).

# Usage: sdep-clear [file]

sdepdata="${XDG_DATA_HOME:-$HOME/.local}/sdep"

file="$sdepdata/${1:-once}"
temp=$(mktemp)

sdep -t <"$file" >"$temp"
mv "$temp" "$file"

Generated with cgit - Back to sebastiano.tronto.net