Date: Fri, 14 Nov 2025 14:40:44 GMT From: Alexander Ziaee <ziaee@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 42d9ae4945f2 - main - freebsd-tips: Add a shell function for laptops Message-ID: <202511141440.5AEEeiVN067927@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch main has been updated by ziaee: URL: https://cgit.FreeBSD.org/src/commit/?id=42d9ae4945f281d12f3ef96cdbd7356e067f8b18 commit 42d9ae4945f281d12f3ef96cdbd7356e067f8b18 Author: Alexander Ziaee <ziaee@FreeBSD.org> AuthorDate: 2025-11-14 14:40:44 +0000 Commit: Alexander Ziaee <ziaee@FreeBSD.org> CommitDate: 2025-11-14 14:40:53 +0000 freebsd-tips: Add a shell function for laptops MFC after: 3 days Reviewed by: pauamma_gundo.com Differential Revision: https://reviews.freebsd.org/D53748 --- usr.bin/fortune/datfiles/freebsd-tips | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/usr.bin/fortune/datfiles/freebsd-tips b/usr.bin/fortune/datfiles/freebsd-tips index 6a2b59ff5fa7..379f772fea88 100644 --- a/usr.bin/fortune/datfiles/freebsd-tips +++ b/usr.bin/fortune/datfiles/freebsd-tips @@ -860,3 +860,11 @@ When netstat reports every 8 seconds, it tells traffic in bits per second: $ netstat -I bge0 8 % +Using vt(4) on a laptop? Try this sh(1) function. It provides an "h" +command that prints the last 22 commands executed, the time, remaining +battery life, and current working directory: + +h() { fc -l -22; printf "%s\n" "`date +%H:%M` -- `apm -l`% -- `pwd`"; } + + -- Alexander Ziaee <ziaee@FreeBSD.org> +%home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202511141440.5AEEeiVN067927>
