Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Commit 68d2422

Browse files
committed
os: fixed lsb_release, closes #14
1 parent 55b78b9 commit 68d2422

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

pfetch

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,12 @@ get_os() {
154154
if command -v lsb_release; then
155155
distro=$(lsb_release -sd)
156156

157+
# lsb_release sometimes adds quotes around the output,
158+
# this simply remove quotes from the start/end if they
159+
# exist.
160+
distro=${distro##\"}
161+
distro=${distro%%\"}
162+
157163
else
158164
# Disable warning about shellcheck not being able
159165
# to read '/etc/os-release'. This is fine.

0 commit comments

Comments
 (0)