From d6bbbecda972e0539d43e007befe46f4871fcc41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Se=C3=A1n=20Healy?= Date: Sat, 18 Apr 2026 01:24:30 +0100 Subject: [PATCH] Add script and README --- README.md | 24 ++++++++++++++++++++++++ al.sh | 7 +++++++ 2 files changed, 31 insertions(+) create mode 100644 README.md create mode 100755 al.sh diff --git a/README.md b/README.md new file mode 100644 index 0000000..b5c5741 --- /dev/null +++ b/README.md @@ -0,0 +1,24 @@ +# al: the activity logger + +al is a simple CLI-based tool for logging your mouse and keyboard activity to a +file. This can be useful for time and sleep tracking. + +## Installation + +```{bash} +make +``` + +# Usage + +Run the bash script `al.sh` to start al in a TMUX session. + +```{bash} +./al.sh +``` + +Alternatively, run al directly: + +```{bash} +./al | tee -a ~/.history/activity_log.csv +``` diff --git a/al.sh b/al.sh new file mode 100755 index 0000000..719c4a7 --- /dev/null +++ b/al.sh @@ -0,0 +1,7 @@ +#!/usr/bin/bash +if [ "$TMUX" ]; then + mkdir -p ~/.history + ./al | tee -a ~/.history/activity_log.csv +fi +tmux new-session -d -s activity-logger $0 +tmux set-option -t activity-logger remain-on-exit on