From 4920d70b7738bdbf03456d99b0d768f731ed0902 Mon Sep 17 00:00:00 2001
From: Dan Church <amphetamachine@gmail.com>
Date: Sun, 28 Feb 2016 00:35:35 -0600
Subject: [PATCH] Fix 0 package count in Slackware

Fixes #112.

Rationale:
- By default in Slackware, /sbin and /usr/sbin aren't part of the user's
  PATH. (It's been this way since I started using it in 2004, version
  9.1)
- `type -p /path/to/binary` works just like it was used with a bare
  binary name.
---
 neofetch | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/neofetch b/neofetch
index ca630ff7..427d718a 100755
--- a/neofetch
+++ b/neofetch
@@ -574,7 +574,7 @@ getpackages () {
             elif type -p pacman >/dev/null 2>&1; then
                 packages="$(pacman -Qq --color never | wc -l)"
 
-            elif type -p pkgtool >/dev/null 2>&1; then
+            elif type -p /sbin/pkgtool >/dev/null 2>&1; then
                 packages="$(ls -1 /var/log/packages | wc -l)"
 
             elif type -p rpm >/dev/null 2>&1; then