From: Steven Cole <elenstev@mesatop.com>
To: linux-kernel@vger.kernel.org
Cc: alan@lxorguk.ukuu.org.uk, reiser@namesys.com
Subject: [PATCH] Modify scripts/ver_linux to display reiserfsprogs version
Date: Tue, 6 Feb 2001 20:49:11 -0700 [thread overview]
Message-ID: <01020620491101.00881@localhost.localdomain> (raw)
Here is a patch to the linux/scripts/ver_linux script which adds
the reiserfsprogs utils to the items checked. If the reiserfsprogs
have not been installed, the modified script outputs nothing for
the Reiserfsprogs line (output looks the same as now).
The current version of reiserfsck does not have a "-V" or "--version"
option, but the version number is printed on the same line as "reiserfsprogs",
like this:
[root@localhost scripts]# reiserfsck --somethingbogus
<-------------reiserfsck, 2000------------->
reiserfsprogs 3.x.0b
reiserfsck: unrecognized option `--somethingbogus'
[the rest of the response snipped]
If reiserfsprogs reiserfsck is modified someday to respond to a
version option, then these two new lines in ver_linux can be simplified.
I'm sure that someone else can code something more elegantly, but
the following output was provided with the patched ver_linux script:
[root@localhost scripts]# ./ver_linux
-- Versions installed: (if some fields are empty or look
-- unusual then possibly you have very old versions)
Linux localhost.localdomain 2.4.1-ac4 #1 Tue Feb 6 17:16:08 MST 2001 i686 unknown
Kernel modules 2.4.2
Gnu C 2.95.3
Gnu Make 3.79.1
Binutils 2.10.0.24
Linux C Library 2.1.3
Dynamic linker ldd (GNU libc) 2.1.3
Procps 2.0.7
Mount 2.10o
Net-tools 1.57
Console-tools 0.2.3
Reiserfsprogs 3.x.0b
Sh-utils 2.0
Modules Loaded
Here is the patch, against 2.4.1-ac4.
Steven
--- linux/scripts/ver_linux.orig Tue Feb 6 14:28:34 2001
+++ linux/scripts/ver_linux Tue Feb 6 14:34:24 2001
@@ -29,6 +29,8 @@
# while console-tools needs 'loadkeys -V'.
loadkeys -V 2>&1 | awk \
'(NR==1 && ($2 ~ /console-tools/)) {print "Console-tools ", $3}'
+reiserfsck --bogusarg 2>&1 | grep reiserfsprogs | awk \
+'NR==1{print "Reiserfsprogs ", $NF}'
expr --v 2>&1 | awk 'NR==1{print "Sh-utils ", $NF}'
X=`cat /proc/modules | sed -e "s/ .*$//"`
echo "Modules Loaded "$X
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
reply other threads:[~2001-02-07 3:46 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=01020620491101.00881@localhost.localdomain \
--to=elenstev@mesatop.com \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=reiser@namesys.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox