Skip to content

Instantly share code, notes, and snippets.

@abathur

abathur/log.console Secret

Last active Apr 8, 2021
Embed
What would you like to do?
saving a few milis
╓─[ nixpkgs ] rmlint.darwin.support ~/work/nixpkgs
╚═> abathur on 0d5099a0 $ KIWI_COMMAND='if [ "$(id -u)" -ne 0 ]; then echo "$(date "+%Y-%m-%d.%H:%M:%S") $(pwd) $(history 1)" __ ~/.logs/bash-history-$(date "+%Y-%m-%d").log; fi'
Wed Apr 07 2021 19:27:00 -->
Wed Apr 07 2021 19:27:00 (917µs)
╓─[ nixpkgs ] rmlint.darwin.support ~/work/nixpkgs
╚═> abathur on 0d5099a0 $ eval ${KIWI_COMMAND}
Wed Apr 07 2021 19:27:05 -->
2021-04-07.19:27:05 /Users/abathur/work/nixpkgs 1220 Apr 07 19:27:05>eval ${KIWI_COMMAND} __ /Users/abathur/.logs/bash-history-2021-04-07.log
Wed Apr 07 2021 19:27:05 (28.1ms)
╓─[ nixpkgs ] rmlint.darwin.support ~/work/nixpkgs
╚═> abathur on 0d5099a0 $ eval ${KIWI_COMMAND}
Wed Apr 07 2021 19:27:08 -->
2021-04-07.19:27:08 /Users/abathur/work/nixpkgs 1220 Apr 07 19:27:05>eval ${KIWI_COMMAND} __ /Users/abathur/.logs/bash-history-2021-04-07.log
Wed Apr 07 2021 19:27:08 (29.6ms)
╓─[ nixpkgs ] rmlint.darwin.support ~/work/nixpkgs
╚═> abathur on 0d5099a0 $ ABA_COMMAND='if [[ $EUID -ne 0 ]]; then printf "%(%Y-%m-%d.%H:%M:%S)T $PWD %s $(history 1) __ ~/.logs/bash-history-$(printf "%(%Y-%m-%d)T").log \n"; fi'
Wed Apr 07 2021 19:27:29 -->
Wed Apr 07 2021 19:27:29 (912µs)
╓─[ nixpkgs ] rmlint.darwin.support ~/work/nixpkgs
╚═> abathur on 0d5099a0 $ eval ${ABA_COMMAND}
Wed Apr 07 2021 19:27:51 -->
2021-04-07.19:27:51 /Users/abathur/work/nixpkgs 1222 Apr 07 19:27:51>eval ${ABA_COMMAND} __ ~/.logs/bash-history-2021-04-07.log
Wed Apr 07 2021 19:27:51 (8.218ms)
╓─[ nixpkgs ] rmlint.darwin.support ~/work/nixpkgs
╚═> abathur on 0d5099a0 $ eval ${ABA_COMMAND}
Wed Apr 07 2021 19:27:53 -->
2021-04-07.19:27:53 /Users/abathur/work/nixpkgs 1222 Apr 07 19:27:51>eval ${ABA_COMMAND} __ ~/.logs/bash-history-2021-04-07.log
Wed Apr 07 2021 19:27:53 (8.100ms)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment