Adds get_option_value() function to retrieve value of specified option from /etc/kdump.conf.
Bug-Url: https://bugzilla.redhat.com/1078134 Signed-off-by: Martin Perina mperina@redhat.com --- kdump-lib.sh | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/kdump-lib.sh b/kdump-lib.sh index 7103ba9..abf2eb3 100755 --- a/kdump-lib.sh +++ b/kdump-lib.sh @@ -75,3 +75,9 @@ get_root_fs_device() return }
+# get_option_value <option_name> +# retrieves value of option defined in kdump.conf +get_option_value() { + echo $(strip_comments `grep ^$1 /etc/kdump.conf | tail -1 | cut -d\ -f2-`) +} +
On Wed, Apr 02, 2014 at 03:35:20PM +0200, Martin Perina wrote:
Adds get_option_value() function to retrieve value of specified option from /etc/kdump.conf.
Bug-Url: https://bugzilla.redhat.com/1078134 Signed-off-by: Martin Perina mperina@redhat.com
Somehow this mail does not show up as part of same thread. Generally if I have to repost a single patch I take the original mail and do reply to that mail and post patch so that new mail shows up as part of original thread.
Thanks Vivek
kdump-lib.sh | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/kdump-lib.sh b/kdump-lib.sh index 7103ba9..abf2eb3 100755 --- a/kdump-lib.sh +++ b/kdump-lib.sh @@ -75,3 +75,9 @@ get_root_fs_device() return }
+# get_option_value <option_name> +# retrieves value of option defined in kdump.conf +get_option_value() {
- echo $(strip_comments `grep ^$1 /etc/kdump.conf | tail -1 | cut -d\ -f2-`)
+}
-- 1.8.3.1