screenfetch: update to 3.9.1

Changelog:
https://github.com/KittyKatt/screenFetch/releases/tag/v3.9.1

OK solene@ bcallah@
This commit is contained in:
cwen 2019-11-26 21:02:17 +00:00
parent c4ccbaaade
commit 29175d9a11
3 changed files with 4 additions and 35 deletions

View File

@ -1,11 +1,11 @@
# $OpenBSD: Makefile,v 1.5 2019/10/22 20:10:22 cwen Exp $
# $OpenBSD: Makefile,v 1.6 2019/11/26 21:02:17 cwen Exp $
COMMENT = display system information in the terminal for screenshots
PKGNAME = ${DISTNAME:L}
GH_ACCOUNT = KittyKatt
GH_PROJECT = screenFetch
GH_TAGNAME = v3.9.0
GH_TAGNAME = v3.9.1
CATEGORIES = sysutils misc

View File

@ -1,2 +1,2 @@
SHA256 (screenFetch-3.9.0.tar.gz) = 1t9O93Y/l2HYGMh4Rl1473AbcQAqUNTxUPZaMcwb6jc=
SIZE (screenFetch-3.9.0.tar.gz) = 77670
SHA256 (screenFetch-3.9.1.tar.gz) = qpfc0qhXauGN5sFsGXRKrhVzo9p1Qa9LmKkZMKMKMXg=
SIZE (screenFetch-3.9.1.tar.gz) = 77350

View File

@ -1,31 +0,0 @@
$OpenBSD: patch-screenfetch-dev,v 1.3 2019/10/22 20:10:23 cwen Exp $
Improve kernel version and architecture reporting and fix disk total usage
From https://github.com/KittyKatt/screenFetch/pull/648
Index: screenfetch-dev
--- screenfetch-dev.orig
+++ screenfetch-dev
@@ -1271,7 +1271,7 @@ detecthost () {
# Kernel Version Detection - Begin
detectkernel () {
if [[ "$distro" == "OpenBSD" ]]; then
- kernel=$(sysctl kern.version|awk -F'[ =:]' 'NR==1{print $3" "$4" "$5}')
+ kernel=$(uname -a | cut -f 3- -d ' ')
else
# compatibility for older versions of OS X:
kernel=$(uname -m && uname -sr)
@@ -1702,8 +1702,12 @@ DetectIntelGPU() {
detectdisk () {
diskusage="Unknown"
if type -p df >/dev/null 2>&1; then
- if [[ "${distro}" =~ (Free|Net|Open|DragonFly)BSD ]]; then
+ if [[ "${distro}" =~ (Free|Net|DragonFly)BSD ]]; then
totaldisk=$(df -h -c 2>/dev/null | tail -1)
+ elif [[ "${distro}" == "OpenBSD" ]]; then
+ totaldisk=$(df -Pk 2> /dev/null | awk '
+ /^\// {total+=$2; used+=$3; avail+=$4}
+ END{printf("total %.1fG %.1fG %.1fG %d%%\n", total/1048576, used/1048576, avail/1048576, used*100/total)}')
elif [[ "${distro}" == "Mac OS X" ]]; then
totaldisk=$(df -H / 2>/dev/null | tail -1)
else