Say I write something like the following:
var1=1
var2=2
for int in 1 2
do
echo "\$var$int"
done
I want the output to be:
1
2
Instead I get something like:
$var1
$var2 (2 Replies)
Is there a simple way of determining whether a command line arguement is numeric or not?? I tried a search and didn't find anything similar...
This is the 2nd time I've made this post.... It didn't appear that the first one showed up ??
Sorry if this is a duplicate... (1 Reply)
Is there an easy way using a command or other routine for testing whether an argument on the command line is numeric? Just want to validate... I ran a search and didn't find a similar question....
Thx (3 Replies)
Can someone tell me how to change the first column in a very large 17k line file from a random 10 digit numeric value to a non numeric value. The format of lines in the file is:
1702938475,SNU022,201004
the first 10 numbers always begin with 170 (6 Replies)
Hi
I am looking for a unix command or a small shell script which can takes one parameter and then searches for the passed in the parameter in any or all files under say /home/dev/
Can anyone please help me on this? (3 Replies)
i am passing input parameter 'one_two' to the script , the script output should display the result as below
one_1two
one_2two
one_3two
if
then
echo " Usage : <$0> <DATABASE> "
exit 0
else
for DB in 1 2 3
do
DBname=`$DATABASE | awk -F "_" '{print $1_${DB}_$2}`
done
fi (5 Replies)
hi all,
i have a parameter file of following format, i want a method which can get the value of specific parameter.
parameter file format:
<Parameter Name="FileLocationWindows">
<Description>
The directory location of the logger file.
... (1 Reply)
Hi,
I have the following files.
->cat scr.sh
export TMP_DIR=/home/user/folder1
export TMP_DIR_2=/home/user/folder2
while read line
do
cat "$line"
done<file_list.dat
------------------------
-> cat file_list.dat
$TMP_DIR/file1.txt
$TMP_DIR_2/file2.txt
---------------------------
-> cat... (6 Replies)
Hi.
How do I achieve this
sh /EDWH-DMT02/script/MISC/exec_sql.sh "@/EDWH-DMT02/script/others/CSM_CKC/Complete_List.sql ${file_name}" Complete_List.txt
The /EDWH-DMT02/script/MISC/exec_sql.sh has two parameters and it's working fine with this
sh /EDWH-DMT02/script/MISC/exec_sql.sh... (7 Replies)
Discussion started by: aimy
7 Replies
LEARN ABOUT PHP
resizecons
RESIZECONS(8) Console Support RESIZECONS(8)NAME
resizecons - change kernel idea of the console size
SYNOPSIS
resizecons COLSxROWS
resizecons -lines ROWS
DESCRIPTION
The resizecons command tries to change the videomode of the console. There are several aspects to this: (a) the kernel must know about it,
(b) the hardware must know about it, (c) user programs must know about it, (d) the console font may have to be adapted.
(a) The kernel is told about the change using the ioctl VT_RESIZE. This causes the kernel to reallocate console screen memory for all vir-
tual consoles, and might fail if there is not enough memory. (In that case, try to disallocate some virtual consoles first.) If this
ioctl succeeds, but a later step fails (e.g., because you do not have root permissions), you may be left with a very messy screen.
The most difficult part of this is (b), since it requires detailed knowledge of the video card hardware, and the setting of numerous regis-
ters. Only changing the number of rows is slightly easier, and resizecons will try to do that itself, when given the -lines option. (Proba-
bly, root permission will be required.) The command resizecons COLSxROWS will execute restoretextmode -r COLSxROWS (and hence requires
that you have svgalib installed). Here COLSxROWS is a file that was created earlier by restoretextmode -w COLSxROWS. Again, either root
permissions are required, or restoretextmode has to be suid root.
In order to deal with (c), resizecons does a `stty rows ROWS cols COLS' for each active console (in the range tty0..tty15), and sends a
SIGWINCH signal to selection if it finds the file /tmp/selection.pid.
Finally, (d) is dealt with by executing a setfont command. Most likely, the wrong font is loaded, and you may want to do another setfont
yourself afterwards.
BUGS
resizecons does not work on all hardware. For example, it cannot be used on platforms other than x86 and x86_64. See the fbset(1) program
if you are looking for an alternative.
This command used to be called resize, but was renamed to avoid conflict with another command with the same name.
SEE ALSO setfont(8), stty(1), selection(1), restoretextmode(8), disalloc(8), fbset(1)Local 17 Jan 1995 RESIZECONS(8)