Compare commits
16 commits
Author | SHA1 | Date | |
---|---|---|---|
573b99f7cb | |||
c09d7c8298 | |||
7a063fa170 | |||
9d8acac656 | |||
1c484427e3 | |||
77e0b50336 | |||
06a4eb3876 | |||
905e11c8fa | |||
49354de8a5 | |||
6dbe52089f | |||
6bc504a4c9 | |||
800356790d | |||
299078645f | |||
9c8a39fe31 | |||
cc850ee668 | |||
826ed611b3 |
7 changed files with 65 additions and 5 deletions
12
README.md
12
README.md
|
@ -1,6 +1,9 @@
|
||||||
# abbiefetch
|
# abbiefetch
|
||||||
abbiefetch is a POSIX compliant fetch script intended to be as portable as possible to run on machines of any age. abbiefetch is not dependent on any specific shell and should run fine on any system with a POSIX compliant shell and Unix utilities.
|
abbiefetch is a POSIX compliant fetch script intended to be as portable as possible to run on machines of any age. abbiefetch is not dependent on any specific shell and should run fine on any system with a POSIX compliant shell and Unix utilities.
|
||||||
|
|
||||||
|
## Building
|
||||||
|
To build abbiefetch, clone this repository and run `./build.sh`. If you receive errors about `tee` having an invalid option then run `./build_alternate.sh`.
|
||||||
|
|
||||||
## Compatibility
|
## Compatibility
|
||||||
abbiefetch will attempt to gather as much information as possible on systems that don't have full compatibility and will provide you with a system type (and sometimes a subtype) to let you know what abbiefetch thinks your computer is running.
|
abbiefetch will attempt to gather as much information as possible on systems that don't have full compatibility and will provide you with a system type (and sometimes a subtype) to let you know what abbiefetch thinks your computer is running.
|
||||||
|
|
||||||
|
@ -8,12 +11,15 @@ abbiefetch will attempt to gather as much information as possible on systems tha
|
||||||
| - | - | - | - | - | - |
|
| - | - | - | - | - | - |
|
||||||
| `unknown` | Unknown kernel | | | None | Default when your system is unrecognised |
|
| `unknown` | Unknown kernel | | | None | Default when your system is unrecognised |
|
||||||
| `linux` | Linux | | 1.0.0 | Full | |
|
| `linux` | Linux | | 1.0.0 | Full | |
|
||||||
|
| `linux/android` | Linux | Android | `master` | Full | |
|
||||||
| `linux/chumby` | Linux | Chumby internet appliances | 1.0.0 | Full | Uses chumby specific tools. |
|
| `linux/chumby` | Linux | Chumby internet appliances | 1.0.0 | Full | Uses chumby specific tools. |
|
||||||
| `linux/proxmox` | Linux | Proxmox VE host | 1.0.0 | Full | |
|
| `linux/proxmox` | Linux | Proxmox VE host | 1.0.0 | Full | |
|
||||||
| `linux/rpi` | Linux | Raspberry Pi single board computer | 1.0.0 | Limited | Currently there are issues detecting the host machine and CPU. |
|
| `linux/rpi` | Linux | Raspberry Pi single board computer | 1.0.0 | Partial | Currently there are issues detecting the host machine and CPU. |
|
||||||
| `openbsd` | OpenBSD | | 1.0.0 | Full | |
|
| `openbsd` | OpenBSD | | 1.0.0 | Full | |
|
||||||
| `netbsd` | NetBSD | | 1.1.0 | Full | |
|
| `netbsd` | NetBSD | | 1.1.0 | Full | |
|
||||||
| `freebsd` | FreeBSD | | 1.1.0 | Full | |
|
| `freebsd` | FreeBSD | | 1.1.0 | Full | |
|
||||||
| `haiku` | Haiku | | 1.1.0 | Limited | |
|
| `freebsd/dfly` | FreeBSD | DragonFly BSD | `master` | Full | DragonFly is a fork of FreeBSD which is similar enough that no modifications need be made. |
|
||||||
|
| `haiku` | Haiku | | 1.1.0 | Partial | |
|
||||||
| `windows` | Microsoft Windows | | 1.2.0 | Full | Relies on wmic.exe and systeminfo.exe |
|
| `windows` | Microsoft Windows | | 1.2.0 | Full | Relies on wmic.exe and systeminfo.exe |
|
||||||
| `windows/cygwin` | Microsoft Windows | Cygwin | 1.2.0 | Full | Relies on wmic.exe and systeminfo.exe |
|
| `windows/cygwin` | Microsoft Windows | Cygwin | 1.2.0 | Partial | Relies on wmic.exe and systeminfo.exe, issues with machine detection |
|
||||||
|
| `illumos` | illumos | | `master` | Partial | |
|
||||||
|
|
10
build_alternate.sh
Executable file
10
build_alternate.sh
Executable file
|
@ -0,0 +1,10 @@
|
||||||
|
#!/bin/sh
|
||||||
|
cat probing.1 | tee abbiefetch
|
||||||
|
cat system_detection.2 | tee -a abbiefetch
|
||||||
|
cat hostname_username.3 | tee -a abbiefetch
|
||||||
|
cat processor_detection.4 | tee -a abbiefetch
|
||||||
|
cat kernel_info.5 | tee -a abbiefetch
|
||||||
|
cat gpu_detection.6 | tee -a abbiefetch
|
||||||
|
cat distro_machine_detection.7 | tee -a abbiefetch
|
||||||
|
cat display_results.8 | tee -a abbiefetch
|
||||||
|
chmod +x abbiefetch
|
|
@ -14,7 +14,11 @@ if [ -n "$kernel" ]; then
|
||||||
echo "krn: $kernel"
|
echo "krn: $kernel"
|
||||||
fi
|
fi
|
||||||
if [ -n "$distro" ]; then
|
if [ -n "$distro" ]; then
|
||||||
|
if [ "$system_type" = "windows" ]; then
|
||||||
echo "sys:$distro"
|
echo "sys:$distro"
|
||||||
|
else
|
||||||
|
echo "sys: $distro"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
if [ -n "$machine" ]; then
|
if [ -n "$machine" ]; then
|
||||||
echo "mac: $machine"
|
echo "mac: $machine"
|
||||||
|
|
|
@ -37,6 +37,15 @@ if [ "$subtype" = "proxmox" ]; then
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
if [ "$subtype" = "android" ]; then
|
||||||
|
if [ -n "$(getprop ro.product.manufacturer)$(getprop ro.product.model)" ]; then
|
||||||
|
machine="$(getprop ro.product.manufacturer) $(getprop ro.product.model)"
|
||||||
|
fi
|
||||||
|
if [ -n "$(getprop ro.build.version.release)" ]; then
|
||||||
|
distro="Android $(getprop ro.build.version.release)"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
if [ "$system_type" = "openbsd" ]; then
|
if [ "$system_type" = "openbsd" ]; then
|
||||||
if [ "$hasawk" -eq 1 ]; then
|
if [ "$hasawk" -eq 1 ]; then
|
||||||
distro="revision $(sysctl kern.osrevision | awk -F "=" '{print $2}')"
|
distro="revision $(sysctl kern.osrevision | awk -F "=" '{print $2}')"
|
||||||
|
@ -72,5 +81,9 @@ if [ "$system_type" = "windows" ] && [ -z "$machine"] && [ "$hassed" -eq 1 ]; th
|
||||||
if [ "$hasawk" -eq 1 ]; then
|
if [ "$hasawk" -eq 1 ]; then
|
||||||
distro="$(systeminfo.exe 2>/dev/null | grep -v "BIOS" | grep "OS Version" | awk -F ":" '{print $2}' | tr -s " ")"
|
distro="$(systeminfo.exe 2>/dev/null | grep -v "BIOS" | grep "OS Version" | awk -F ":" '{print $2}' | tr -s " ")"
|
||||||
fi
|
fi
|
||||||
machine="$(wmic.exe computersystem get Manufacturer,Model | sed -n 2p | head -n 1)"
|
if [ "$subtype" = "cygwin" ]; then
|
||||||
|
machine=0
|
||||||
|
else
|
||||||
|
machine="$(wmic.exe computersystem get Manufacturer | sed -n 2p | head -n 1 | tr -s " ")$(wmic.exe computersystem get Model | sed -n 2p | head -n 1)"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -4,3 +4,6 @@ fi
|
||||||
if [ -n "$(uname -s)" ] && [ -z "$kernel" ]; then
|
if [ -n "$(uname -s)" ] && [ -z "$kernel" ]; then
|
||||||
kernel="$(uname -s)"
|
kernel="$(uname -s)"
|
||||||
fi
|
fi
|
||||||
|
if [ "$system_type" = "illumos" ]; then
|
||||||
|
kernel="$(uname -v)"
|
||||||
|
fi
|
||||||
|
|
|
@ -28,6 +28,18 @@ if [ "$hassed" -eq 1 ] && [ "$system_type" = "windows" ] && [ -z "$processor" ];
|
||||||
processor="$(wmic.exe cpu get name | sed -n 2p | head -n 1)"
|
processor="$(wmic.exe cpu get name | sed -n 2p | head -n 1)"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
if [ "$subtype" = "android" ]; then
|
||||||
|
if [ -n "$(getprop ro.soc.manufacturer)$(getprop ro.soc.model)" ]; then
|
||||||
|
processor="$(getprop ro.soc.manufacturer) $(getprop ro.soc.model)"
|
||||||
|
elif [ -n "$(getprop ro.hardware.chipname)" ]; then
|
||||||
|
processor="$(getprop ro.hardware.chipname)"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
if [ "$hasawk" -eq 1 ] && [ "$system_type" = "illumos" ] && [ -z "$processor" ]; then
|
||||||
|
if [ -n "$(kstat | grep brand)" ]; then
|
||||||
|
processor="$(kstat | grep brand | head -n 1 | tr -s " " | awk -F "brand " '{print $2}')"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
if [ "$hassed" -eq 1 ] && [ "$hasawk" -eq 1 ] && [ -n "$processor" ]; then
|
if [ "$hassed" -eq 1 ] && [ "$hasawk" -eq 1 ] && [ -n "$processor" ]; then
|
||||||
if [ -n "$(echo $processor | awk -F "@" '{print $1}' | sed "s/Processor//g" | sed "s/CPU//g" | sed "s/(R)//g" | sed "s/(r)//g" | sed "s/(TM)//g" | sed "s/(tm)//g" | tr -s " ")" ]; then
|
if [ -n "$(echo $processor | awk -F "@" '{print $1}' | sed "s/Processor//g" | sed "s/CPU//g" | sed "s/(R)//g" | sed "s/(r)//g" | sed "s/(TM)//g" | sed "s/(tm)//g" | tr -s " ")" ]; then
|
||||||
processor="$(echo $processor | awk -F "@" '{print $1}' | sed "s/Processor//g" | sed "s/CPU//g" | sed "s/(R)//g" | sed "s/(r)//g" | sed "s/(TM)//g" | sed "s/(tm)//g" | tr -s " ")"
|
processor="$(echo $processor | awk -F "@" '{print $1}' | sed "s/Processor//g" | sed "s/CPU//g" | sed "s/(R)//g" | sed "s/(r)//g" | sed "s/(TM)//g" | sed "s/(tm)//g" | tr -s " ")"
|
||||||
|
|
|
@ -12,6 +12,11 @@ if [ "$(uname -s)" = "Linux" ] && [ "$system_type" = "unknown" ]; then
|
||||||
if [ "$?" -eq 0 ] && [ "$subtype" = "none" ]; then
|
if [ "$?" -eq 0 ] && [ "$subtype" = "none" ]; then
|
||||||
subtype="proxmox"
|
subtype="proxmox"
|
||||||
fi
|
fi
|
||||||
|
command -v getprop >>/dev/null
|
||||||
|
if [ "$?" -eq 0 ] && [ "$subtype" = "none" ]; then
|
||||||
|
subtype="android"
|
||||||
|
haslspci=0
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
if [ "$(uname -s)" = "OpenBSD" ] && [ "$system_type" = "unknown" ]; then
|
if [ "$(uname -s)" = "OpenBSD" ] && [ "$system_type" = "unknown" ]; then
|
||||||
system_type="openbsd"
|
system_type="openbsd"
|
||||||
|
@ -19,6 +24,10 @@ fi
|
||||||
if [ "$(uname -s)" = "FreeBSD" ] && [ "$system_type" = "unknown" ]; then
|
if [ "$(uname -s)" = "FreeBSD" ] && [ "$system_type" = "unknown" ]; then
|
||||||
system_type="freebsd"
|
system_type="freebsd"
|
||||||
fi
|
fi
|
||||||
|
if [ "$(uname -s)" = "DragonFly" ] && [ "$system_type" = "unknown" ]; then
|
||||||
|
system_type="freebsd"
|
||||||
|
subtype="dfly"
|
||||||
|
fi
|
||||||
if [ "$(uname -s)" = "NetBSD" ] && [ "$system_type" = "unknown" ]; then
|
if [ "$(uname -s)" = "NetBSD" ] && [ "$system_type" = "unknown" ]; then
|
||||||
system_type="netbsd"
|
system_type="netbsd"
|
||||||
fi
|
fi
|
||||||
|
@ -32,3 +41,6 @@ if [ "$?" -eq 0 ] && [ "$system_type" = "unknown" ]; then
|
||||||
subtype="cygwin"
|
subtype="cygwin"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
if [ "$(uname -o)" = "illumos" ] && [ "$system_type" = "unknown" ]; then
|
||||||
|
system_type="illumos"
|
||||||
|
fi
|
||||||
|
|
Loading…
Reference in a new issue