Skip to content

Instantly share code, notes, and snippets.

@aerickt
Created August 2, 2021 17:14
Show Gist options
  • Save aerickt/2b023c44377f830b4e0e619b1e653ef6 to your computer and use it in GitHub Desktop.
Save aerickt/2b023c44377f830b4e0e619b1e653ef6 to your computer and use it in GitHub Desktop.
Plover Stroke Counter
#!/bin/bash
cd ~/.config/plover
raw=($(cut -c-10 strokes.log))
dates=($(echo "${raw[@]}" | tr ' ' '\n' | sort -u | tr '\n' ' '))
for i in "${dates[@]}"; do
count=$(cat strokes.log | grep -c "$i")
string="${i} ${count}"
echo "$string"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment