mirror of
https://git.adityakumar.xyz/dwmbar.git
synced 2024-12-22 21:22:52 +00:00
Add os-release module
Prints your distro's name
This commit is contained in:
parent
ae937dfd0f
commit
e5b929d981
1 changed files with 14 additions and 0 deletions
14
modules/os-release
Normal file
14
modules/os-release
Normal file
|
@ -0,0 +1,14 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Prints out your OS name
|
||||
|
||||
PREFIX=' '
|
||||
|
||||
get_os_name()
|
||||
{
|
||||
OS=$(cat /etc/os-release | head -n 1 | sed 's/NAME=//g')
|
||||
|
||||
echo "$PREFIX$OS"
|
||||
}
|
||||
|
||||
get_os_name
|
Loading…
Reference in a new issue