Mercurial > repo
view lib/karma @ 12438:9e11a16f0c77 draft
<b_jonas> `` hg cat -r 12436 /hackenv/bin/\\( > /hackenv/bin/\\(
author | HackEso <hackeso@esolangs.org> |
---|---|
date | Sat, 11 Dec 2021 21:53:31 +0000 |
parents | 9b8fbae1571a |
children |
line wrap: on
line source
#!/bin/sh count () { hg log -k '> karma' --template '{desc}\n' | egrep '^<[^>]*> karma\'$1 | fgrep -vix "<$2> karma$1 $2" | cut -d' ' -f3 | fgrep -cix "$2" } plus=$(count + "$1") minus=$(count - "$1") echo $(($plus-$minus))