kdump-lib.sh: add common function strip_comments
Add function strip_comments into kdump-lib.sh, since it's used by several files. Signed-off-by: Wade Mealing <wmealing@redhat.com> Signed-off-by: Baoquan He <bhe@redhat.com> Acked-by: Vivek Goyal <vgoyal@redhat.com>
This commit is contained in:
parent
a8921f04ae
commit
ee524473c8
@ -17,3 +17,8 @@ is_raw_dump_target()
|
|||||||
{
|
{
|
||||||
grep -q "^raw" /etc/kdump.conf
|
grep -q "^raw" /etc/kdump.conf
|
||||||
}
|
}
|
||||||
|
|
||||||
|
strip_comments()
|
||||||
|
{
|
||||||
|
echo $1 | sed -e 's/\(.*\)#.*/\1/'
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user