Skip to content
View in the app

A better way to browse. Learn more.

Armbian Community Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

show armbian-package versions in login motd

Featured Replies

A while ago I did create  a armbian-package-information for at the motd of the login:

Now the line for the kernel does show 2 versions because there are "Version:" and "Config -Version:"

 

root@npi-neo2-24(192.168.6.24):~# dpkg -s linux-image-$BRANCH-$LINUXFAMILY|grep Version
Version: 5.96
Config-Version: 5.96

root@npi-neo2-24(192.168.6.24):~# dpkg -s linux-image-$BRANCH-$LINUXFAMILY|grep Version|cut -f 2 -d ' '
5.96
5.96

So I had to find another way/command to get the information once ;)
I did go back from "dpkg -s" to "dpkg -l" and greped there the version-info:

root@npi-neo2-24(192.168.6.24):~# dpkg -l | awk -v env_var="linux-image-$BRANCH-$LINUXFAMILY" '$2==env_var { print $3 }'
5.96

# end-part of /etc/update-motd.d/10-armbian-header
# NEW version
# ===============================================================================================================
ARMBIAN_bsp=$(more /etc/armbian-release|grep VERSION|cut -f 2 -d '=')
ARMBIAN_kernel=$(dpkg -l | awk -v env_var="linux-image-$BRANCH-$LINUXFAMILY" '$2==env_var { print $3 }')
ARMBIAN_uboot=$(dpkg -l | awk -v env_var="linux-u-boot-$BOARD-$BRANCH" '$2==env_var { print $3 }')
ARMBIAN_dtb=$(dpkg -l | awk -v env_var="linux-dtb-$BRANCH-$LINUXFAMILY" '$2==env_var { print $3 }')
ARMBIAN_firmware=$(dpkg -l | awk -v env_var="armbian-firmware" '$2==env_var { print $3 }')
ARMBIAN_config=$(dpkg -l | awk -v env_var="armbian-config" '$2==env_var { print $3 }')

printf 'package bsp-kernel[\e[0;91m%s\x1B[0m] u-boot[\e[0;91m%s\x1B[0m] dtb[\e[0;91m%s\x1B[0m] firmware[\e[0;91m%s\x1B[0m] config[\e[0;91m%s\x1B[0m]\n' "$ARMBIAN_kernel" "$ARMBIAN_uboot" "$ARMBIAN_dtb" "$ARMBIAN_firmware" "$ARMBIAN_config"
printf '\n'
# ===============================================================================================================

 

After successfully getting the kernel-version only once- I edited the other commands to the "dpkg -l" version - and the result is clear as before :)

 _   _ ____  _   _   _              ____
| \ | |  _ \(_) | \ | | ___  ___   |___ \
|  \| | |_) | | |  \| |/ _ \/ _ \    __) |
| |\  |  __/| | | |\  |  __/ (_) |  / __/
|_| \_|_|   |_| |_| \_|\___|\___/  |_____|

Welcome to Debian Buster with Armbian Linux 5.3.3-sunxi64
package bsp-kernel[5.98.191003] u-boot[5.96] dtb[5.98.191003] firmware[5.96] config[5.96]

The only drawback is, when you use a dev-kernel/-dtb on a next-installation (using other kernel via armbian-config) then $BRANCH is next and your kernel is dev :(

root@npi-neo2-24(192.168.6.24):~# dpkg -l|grep image
ii  linux-image-dev-sunxi64           5.98.191003                         arm64        Linux kernel, version 5.3.3-sunxi64
rc  linux-image-next-sunxi64          5.96                                arm64        Linux kernel, version 4.19.71-sunxi64

root@npi-neo2-24(192.168.6.24):~# dpkg -l|grep dtb
ii  linux-dtb-dev-sunxi64             5.98.191003                         arm64        Linux DTB, version 5.3.3-sunxi64


# ARMBIAN_kernel=$(dpkg -l | awk -v env_var="linux-image-$BRANCH-$LINUXFAMILY" '$2==env_var { print $3 }')
ARMBIAN_kernel=$(dpkg -l | awk -v env_var="linux-image-dev-$LINUXFAMILY" '$2==env_var { print $3 }')

# ARMBIAN_dtb=$(dpkg -l | awk -v env_var="linux-dtb-$BRANCH-$LINUXFAMILY" '$2==env_var { print $3 }')
ARMBIAN_dtb=$(dpkg -l | awk -v env_var="linux-dtb-dev-$LINUXFAMILY" '$2==env_var { print $3 }')

 

 

PS: I also did try - before this - the package apt-show-versions (lists available package versions with distribution)

but this takes much too long to resolve and needs this additionally package :(

 

 

package_info.jpg

Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.