lkml.org 
[lkml]   [2009]   [Aug]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] scripts/ver_linux
Hi there,

sometimes I'm using scripts/ver_linux to quickly have an overview of my
(build-)environment. The output is usually a bit off, since I don't have
"kbd" or "console-tools" installed and don't have /sbin:/usr/sbin in my
PATH. The patch below makes scripts/ver_linux print a better result,
compared to its original output:

-module-init-tools found
+module-init-tools 3.4
+e2fsprogs 1.41.3
+jfsutils 1.1.12
+reiserfsprogs 3.6.19
+reiser4progs 1.0.6
+xfsprogs 2.9.8
Linux C Library 2.7
Procps 3.2.7
-Kbd loadkeys:
+Net-tools 1.60
Sh-utils 6.10

Signed-off-by: Christian Kujau <lists@nerdbynature.de>

--- linux-2.6-git/scripts/ver_linux.orig 2009-08-14 07:47:12.185695350 +0200
+++ linux-2.6-git/scripts/ver_linux 2009-08-14 07:47:23.642348227 +0200
@@ -4,6 +4,7 @@
# /bin /sbin /usr/bin /usr/sbin /usr/local/bin, but it may
# differ on your system.
#
+PATH="$PATH":/sbin:/usr/sbin
echo 'If some fields are empty or look unusual you may have an old version.'
echo 'Compare to the current minimal requirements in Documentation/Changes.'
echo ' '
@@ -76,7 +77,7 @@ ifconfig --version 2>&1 | grep tools | a

# Kbd needs 'loadkeys -h',
loadkeys -h 2>&1 | awk \
-'(NR==1 && ($3 !~ /option/)) {print "Kbd ", $3}'
+'(NR==1 && ($1 = /^loadkeys/)) {print "Kbd ", $3}'

# while console-tools needs 'loadkeys -V'.
loadkeys -V 2>&1 | awk \
--
BOFH excuse #17:

fat electrons in the lines


\
 
 \ /
  Last update: 2009-08-14 07:59    [W:0.050 / U:0.428 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site