Horje
Another linux info Code Example
Another linux info
OS=$(awk '/DISTRIB_ID=/' /etc/*-release | sed 's/DISTRIB_ID=//' | tr '[:upper:]' '[:lower:]')
ARCH=$(uname -m | sed 's/x86_//;s/i[3-6]86/32/')
VERSION=$(awk '/DISTRIB_RELEASE=/' /etc/*-release | sed 's/DISTRIB_RELEASE=//' | sed 's/[.]0/./')

if [ -z "$OS" ]; then
    OS=$(awk '{print $1}' /etc/*-release | tr '[:upper:]' '[:lower:]')
fi

if [ -z "$VERSION" ]; then
    VERSION=$(awk '{print $3}' /etc/*-release)
fi

echo $OS
echo $ARCH
echo $VERSION




Shell

Related
unset git commit encoding Code Example unset git commit encoding Code Example
pip install psycopg2 error Code Example pip install psycopg2 error Code Example
ubuntu 19.10 eoan update error Code Example ubuntu 19.10 eoan update error Code Example
powershell number of possible commands Code Example powershell number of possible commands Code Example
how to conda install flask-whooshalchemy Code Example how to conda install flask-whooshalchemy Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
10