Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
neofetch
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ximper Linux
neofetch
Commits
81db772a
Unverified
Commit
81db772a
authored
Mar 24, 2018
by
Herdiansyah
Committed by
GitHub
Mar 24, 2018
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #929 from konimex/win10fix
OS: Separate Windows 10 and ChromeOS into its own if clause
parents
deae19ac
74149371
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
16 deletions
+19
-16
CHANGELOG.md
CHANGELOG.md
+1
-0
neofetch
neofetch
+18
-16
No files found.
CHANGELOG.md
View file @
81db772a
...
@@ -36,6 +36,7 @@
...
@@ -36,6 +36,7 @@
-
Fixed detection bug with OpenWRT.
[
**@dawidd6**
](
https://github.com/dawidd6
)
-
Fixed detection bug with OpenWRT.
[
**@dawidd6**
](
https://github.com/dawidd6
)
-
Fixed detection bug with LEDE.
[
**@dawidd6**
](
https://github.com/dawidd6
)
-
Fixed detection bug with LEDE.
[
**@dawidd6**
](
https://github.com/dawidd6
)
-
Fixed detection bug with TrueOS.
[
**@dawidd6**
](
https://github.com/dawidd6
)
-
Fixed detection bug with TrueOS.
[
**@dawidd6**
](
https://github.com/dawidd6
)
-
Fixed detection bug with Windows Subsystem for Linux and Crouton when an OS without lsb_release is installed.
## General
## General
...
...
neofetch
View file @
81db772a
...
@@ -58,22 +58,7 @@ get_distro() {
...
@@ -58,22 +58,7 @@ get_distro() {
case
"
$os
"
in
case
"
$os
"
in
"Linux"
|
"BSD"
|
"MINIX"
)
"Linux"
|
"BSD"
|
"MINIX"
)
if
[[
"
$(
< /proc/version
)
"
==
*
"Microsoft"
*
||
if
[[
-f
"/etc/redstar-release"
]]
;
then
"
$kernel_version
"
==
*
"Microsoft"
*
]]
;
then
case
"
$distro_shorthand
"
in
"on"
)
distro
=
"
$(
lsb_release
-sir
)
[Windows 10]"
;;
"tiny"
)
distro
=
"Windows 10"
;;
*
)
distro
=
"
$(
lsb_release
-sd
)
on Windows 10"
;;
esac
elif
[[
"
$(
< /proc/version
)
"
==
*
"chrome-bot"
*
||
-f
"/dev/cros_ec"
]]
;
then
case
"
$distro_shorthand
"
in
"on"
)
distro
=
"
$(
lsb_release
-sir
)
[Chrome OS]"
;;
"tiny"
)
distro
=
"Chrome OS"
;;
*
)
distro
=
"
$(
lsb_release
-sd
)
on Chrome OS"
;;
esac
elif
[[
-f
"/etc/redstar-release"
]]
;
then
case
"
$distro_shorthand
"
in
case
"
$distro_shorthand
"
in
"on"
|
"tiny"
)
distro
=
"Red Star OS"
;;
"on"
|
"tiny"
)
distro
=
"Red Star OS"
;;
*
)
distro
=
"Red Star OS
$(
awk
-F
'[^0-9*]'
'$0=$2'
/etc/redstar-release
)
"
*
)
distro
=
"Red Star OS
$(
awk
-F
'[^0-9*]'
'$0=$2'
/etc/redstar-release
)
"
...
@@ -163,6 +148,23 @@ get_distro() {
...
@@ -163,6 +148,23 @@ get_distro() {
[[
-f
"/etc/pacbsd-release"
]]
&&
distro
=
"PacBSD"
[[
-f
"/etc/pacbsd-release"
]]
&&
distro
=
"PacBSD"
fi
fi
fi
fi
if
[[
"
$(
< /proc/version
)
"
==
*
"Microsoft"
*
||
"
$kernel_version
"
==
*
"Microsoft"
*
]]
;
then
case
"
$distro_shorthand
"
in
"on"
)
distro+
=
" [Windows 10]"
;;
"tiny"
)
distro
=
"Windows 10"
;;
*
)
distro+
=
" on Windows 10"
;;
esac
elif
[[
"
$(
< /proc/version
)
"
==
*
"chrome-bot"
*
||
-f
"/dev/cros_ec"
]]
;
then
case
"
$distro_shorthand
"
in
"on"
)
distro+
=
" [Chrome OS]"
;;
"tiny"
)
distro
=
"Chrome OS"
;;
*
)
distro+
=
" on Chrome OS"
;;
esac
fi
distro
=
"
$(
trim_quotes
"
$distro
"
)
"
distro
=
"
$(
trim_quotes
"
$distro
"
)
"
distro
=
"
${
distro
/
'NAME='
}
"
distro
=
"
${
distro
/
'NAME='
}
"
;;
;;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment