I see a couple of potential issue with this approach.
I still don't understand why you can't use the usual paradigm of passing vars with -v to awk and have to use this somewhat convoluted approach.
Any chance you can attach a sample file?
I will put together a sample directory and post it.
The -v method works for the comments and replace line, no matter if there are special characters or spaces. It is the $look_for line that is the problem. This version of the code does not work. The $look_for line is never found.
If you replace,
else if($0 ~ find_line)
with,
else if($0 ~ / PARAMETER \(SIZEXX = /)
then it will function. This is hard coding specifically for each item to find and so can't be used in a function. I read that the -v option presented difficulties when using characters that need to be escaped and that is when I switched to the temporary environment variables that I read about on a stackexchange post (I think). I don't understand why it works, but not in the function.
I will post some samples in a few minutes. I need another cup of coffee.
Hi ,
I have three funcions f1, f2 and f3 .
f1 calls f2 and f2 calls f3 .
I have a global variable "period" which i want to pass to f3 .
Can i pass the variable directly in the definition of f3 ?
Pls help .
sars (4 Replies)
Hi,
I have the following statement which parses a string for me and prints it out:
l_comp="dc000.runksh.test.ksh|
$g_sql/dc0000.runksh_test.sql|new.dat|control.ctl"
echo $l_comp | awk -F"|" '{ for ( i = 1; i <= NF; i++) { print $i; } } '
Rather then printing the data, I would like to... (5 Replies)
Hello.
Looking for a method of modularizing my bash script, I am stuck with such a problem. For example, I have:
MODULE_NAME="test"
FUNCTION_NAME="run"
How do I can a function with name test_run? (4 Replies)
Hello,
I have a problem with package and name space.
require "/Mehran/DSGateEngineLib/general.pl";
use strict;
sub System_Status_Main_Service_Status_Intrusion_Prevention
{
my %idpstatus;
my @result;
&General_ReadHash("/var/dsg/idp/settings",\%idpstatus);
#print... (4 Replies)
Dear all,
Could you please advice as I when call function i found the following error
" refills: command not found" note that refills is function name.
following also the function and how i call it
function refills
{
echo "formatting refills and telepin" >> $log
awk -F,... (20 Replies)
Hi,
I have the following code in which i am trying to find ceil of 10th & 11th fields. For finding ceil i have a function in the awk statement. When i test it for some values say on command line it gives correct response(say $10=0 & $11=750). But when the same value occurs in a file having more 3... (5 Replies)
I've created a tag in the makefile:
mytag: $(shell ${PWD}/script.sh)
When i do: make clean - the script is executed
When i perform make or make mytag the script is again executed with the output:
make: Nothing to be done for mytag
What i want ?
I want script.sh to be executed only... (0 Replies)
My requirement is to call function ("fun1") from awk, and print its returned value along with $0.
fun1()
{
t=$1
printf "%02d\n", $t % 60;
}
echo "Hi There 23" | awk '{print $0; system(fun1 $3)}'
Any suggestions what to be modified in above code to achieve requirement.. (5 Replies)
Discussion started by: JSKOBS
5 Replies
LEARN ABOUT MOJAVE
grub-mkrescue
GRUB-MKRESCUE(1) User Commands GRUB-MKRESCUE(1)NAME
grub-mkrescue - make a GRUB rescue image
SYNOPSIS
grub-mkrescue [OPTION...] [OPTION] SOURCE...
DESCRIPTION
Make GRUB CD-ROM, disk, pendrive and floppy bootable image.
--compress=no|xz|gz|lzo
compress GRUB files [optional]
-d, --directory=DIR
use images and modules under DIR [default=/usr/lib/grub/<platform>]
--fonts=FONTS
install FONTS [default=unicode]
--install-modules=MODULES
install only MODULES and their dependencies [default=all]
-k, --pubkey=FILE
embed FILE as public key for signature checking
--locale-directory=DIR use translations under DIR
[default=/usr/share/locale]
--locales=LOCALES
install only LOCALES [default=all]
--modules=MODULES
pre-load specified modules MODULES
--themes=THEMES
install THEMES [default=starfield]
-v, --verbose
print verbose messages.
--arcs-boot
enable ARCS (big-endian mips machines, mostly SGI) boot. Disables HFS+, APM, sparc64 and boot as disk image for i386-pc
--core-compress=xz|none|auto
choose the compression to use for core image
--label-bgcolor=COLOR
use COLOR for label background
--label-color=COLOR
use COLOR for label
--label-font=FILE
use FILE as font for label
-o, --output=FILE
save output in FILE [required]
--product-name=STRING
use STRING as product name
--product-version=STRING
use STRING as product version
--rom-directory=DIR
save ROM images in DIR [optional]
--sparc-boot
enable sparc boot. Disables HFS+, APM, ARCS and boot as disk image for i386-pc
--xorriso=FILE
use FILE as xorriso [optional]
-?, --help
give this help list
--usage
give a short usage message
-V, --version
print program version
Mandatory or optional arguments to long options are also mandatory or optional for any corresponding short options.
Generates a bootable CD/USB/floppy image. Arguments other than options to this program are passed to xorriso, and indicate source files,
source directories, or any of the mkisofs options listed by the output of `xorriso -as mkisofs -help'.
Option -- switches to native xorriso command mode.
Mail xorriso support requests to <bug-xorriso@gnu.org>.
REPORTING BUGS
Report bugs to <bug-grub@gnu.org>.
SEE ALSO grub-mkimage(1)
The full documentation for grub-mkrescue is maintained as a Texinfo manual. If the info and grub-mkrescue programs are properly installed
at your site, the command
info grub-mkrescue
should give you access to the complete manual.
grub-mkrescue (GRUB) 2.02-2ubuntu8.3 July 2018 GRUB-MKRESCUE(1)