diff --git a/README.md b/README.md index b679ed9f..22804fea 100644 --- a/README.md +++ b/README.md @@ -283,7 +283,7 @@ alias fetch2="fetch \ Possible values: name, speed, tiny, on, off --kernel_shorthand on/off Shorten the output of kernel --uptime_shorthand on/off Shorten the output of uptime (tiny, on, off) - --gpu_shorthand on/off Shorten the output of GPU + --gpu_shorthand on/off Shorten the output of GPU (tiny, on, off) --gtk_shorthand on/off Shorten output of gtk theme/icons --gtk2 on/off Enable/Disable gtk2 theme/icons output --gtk3 on/off Enable/Disable gtk3 theme/icons output diff --git a/config/config b/config/config index 6026ab9e..f390f7de 100644 --- a/config/config +++ b/config/config @@ -102,7 +102,7 @@ cpu_shorthand="off" # GPU # Shorten output of the getgpu funcion -# --gpu_shorthand on/off +# --gpu_shorthand on/off/tiny gpu_shorthand="on" diff --git a/neofetch b/neofetch index cb84eafb..08930e26 100755 --- a/neofetch +++ b/neofetch @@ -123,7 +123,7 @@ cpu_shorthand="off" # GPU # Shorten output of the getgpu funcion -# --gpu_shorthand on/off +# --gpu_shorthand on/off/tiny gpu_shorthand="on" @@ -1000,17 +1000,27 @@ getgpu () { ;; esac - if [ "$gpu_shorthand" == "on" ]; then - gpu=${gpu// Rev\. ?} - gpu=${gpu//AMD*\/ATI\]/AMD} - gpu=${gpu// Tahiti} - gpu=${gpu// PRO} - gpu=${gpu// OEM} - gpu=${gpu// Mars} - gpu=${gpu// Series} - gpu=${gpu// Controller} - gpu=${gpu/\/*} - fi + case "$gpu_shorthand" in + "on" | "tiny") + gpu=${gpu// Rev\. ?} + gpu=${gpu//AMD*\/ATI\]/AMD} + gpu=${gpu// Tahiti} + gpu=${gpu// PRO} + gpu=${gpu// OEM} + gpu=${gpu// Mars} + gpu=${gpu// Series} + gpu=${gpu// Controller} + gpu=${gpu/\/*} + + case "$gpu_shorthand" in + "tiny") + gpu=${gpu/Graphics } + gpu=${gpu/GeForce } + gpu=${gpu/Radeon } + ;; + esac + ;; + esac gpu="${gpu}${count}" } @@ -2327,7 +2337,7 @@ usage () { cat << EOF Possible values: name, speed, tiny, on, off --kernel_shorthand on/off Shorten the output of kernel --uptime_shorthand on/off Shorten the output of uptime (tiny, on, off) - --gpu_shorthand on/off Shorten the output of GPU + --gpu_shorthand on/off Shorten the output of GPU (tiny, on, off) --gtk_shorthand on/off Shorten output of gtk theme/icons --gtk2 on/off Enable/Disable gtk2 theme/icons output --gtk3 on/off Enable/Disable gtk3 theme/icons output diff --git a/neofetch.1 b/neofetch.1 index 28f43ac2..ffa0aca9 100644 --- a/neofetch.1 +++ b/neofetch.1 @@ -45,7 +45,7 @@ Shorten the output of kernel Shorten the output of uptime (tiny, on, off) .TP .B \--gpu_shorthand 'on/off' -Shorten the output of GPU +Shorten the output of GPU (tiny, on, off) .TP .B \--gtk_shorthand 'on/off' Shorten output of gtk theme/icons