#!/bin/ksh
c=0
while [[ ! -f /tmp/unex && $c -lt 10 ]]; do
echo /tmp/unex NOT found, iter : $c;
((c = $c + 1));
sleep 2;
done
(note that ksh is in /bin instead of /usr/bin on my system) and the file /tmp/unex does not exist; I get the output:
Code:
/tmp/unex NOT found, iter : 0
/tmp/unex NOT found, iter : 1
/tmp/unex NOT found, iter : 2
/tmp/unex NOT found, iter : 3
/tmp/unex NOT found, iter : 4
/tmp/unex NOT found, iter : 5
/tmp/unex NOT found, iter : 6
/tmp/unex NOT found, iter : 7
/tmp/unex NOT found, iter : 8
/tmp/unex NOT found, iter : 9
Hello everyone,
how can I send output to the screen from a running script or tcl, in such a way that if a loop is executing I will see the rolling counter on my screen as the records are processed in the loop. I do not want the screen to scroll, though. In other words can a var's value be painted... (2 Replies)
The scenario is like this :
I need to read records from a file one by one and increment counter1, if a certain field matches with a number say "40"..the script should increment the counter2 and also extract a corresponding field from the same line and adding them one by one and redirecting the the... (5 Replies)
Hi,
hope I am posting in the right section.
My problem is that I have 2 or more arguments passed and I want to check if the arguments passed exists or not.
The first argument should not exist and the remaining others should exist.
example:
./shells.sh argument1 argument2 argument3
... (5 Replies)
Hello Everyone,
I'm in need of assistance on creating a script with a counter on a certain string.
Basically this script opens a log file and displays certain log data. There are two key words in the log. START and FINISH. In between the START and FINISH is a variable ACTNUMBER. It will... (1 Reply)
hello,
File 1
main Group sub group
MIT VAR_1D_DATA_TYPE 23-03-2012
MIT VAR_1D_DATA_TYPE 22-03-2012
MIT VAR_10D_DATA_TYPE 23-03-2012
MIT VAR_10D_DATA_TYPE 22-03-2012
MIT ... (0 Replies)
I want to run my shell script to the limit number.Suppose I know in advance that MAX=5 then I want that my script run 5 times only.Something like below$ vi testingMAX=5COMMAND="ssh -l stpuser VHLDVWSAD001 /projects/st/utils/deploy/deployall.sh >/dev/null 2>&1 &" ; sleep 20;count=0while... (2 Replies)
Hi,
I am working on a script where I need to add one functionality i.e. to could the number of tar files at particular location...but the script is working in below way.
1) create sandbox
2) Drop old member function
3) addmember function
4) Apply checkpoint lable
5) Resync operation(This... (1 Reply)
Hi friends, I just want to try some thing with shell using loop and counter
I have 30 Directory, in each directory number of files say 5, 10, 20 etc...
directory_1
directory_2
directory_n
what I want to do is read files from directory_1 say 5 files
if my counter is like this
m=2000 ... (6 Replies)
Hello,
I have currently coded a bash script below in which it does the following:
# Archives compressed file from another location.
Basically it moves *.gz files to another location.
The script also sends an email whenever a new compressed file is placed. This is the issue that i... (5 Replies)
Hi!
Can anyone explain this? The counter CDR_count should go on forever, but it suddenly resets at every step of the FOR loop (I know this because $_file has exactly 378 records). However, the counter reset is OUTSIDE the FOR loop. What's going on??
#!/bin/bash
if || ; then
echo
... (8 Replies)
Discussion started by: Flavius
8 Replies
LEARN ABOUT DEBIAN
gtk2::treeselection
Gtk2::TreeSelection(3pm) User Contributed Perl Documentation Gtk2::TreeSelection(3pm)NAME
Gtk2::TreeSelection - wrapper for GtkTreeSelection
HIERARCHY
Glib::Object
+----Gtk2::TreeSelection
METHODS
integer = $selection->count_selected_rows
boolean = $selection->iter_is_selected ($iter)
o $iter (Gtk2::TreeIter)
selectionmode = $selection->get_mode
$selection->set_mode ($type)
o $type (Gtk2::SelectionMode)
boolean = $selection->path_is_selected ($path)
o $path (Gtk2::TreePath)
$selection->select_all
$selection->set_select_function ($func, $data=undef)
o $func (scalar)
o $data (scalar)
$selection->select_iter ($iter)
o $iter (Gtk2::TreeIter)
$selection->select_path ($path)
o $path (Gtk2::TreePath)
$selection->select_range ($start_path, $end_path)
o $start_path (Gtk2::TreePath)
o $end_path (Gtk2::TreePath)
$selection->selected_foreach ($func, $data=undef)
o $func (subroutine)
o $data (scalar)
Call $func on every selected row in $selection's view.
iter = $tree_selection->get_selected
(model, iter) = $tree_selection->get_selected
Since most of the time you are only interested in the iter, "get_selected" returns only the iter in scalar context.
@paths = $selection->get_selected_rows
Returns the Gtk2::TreePath of each selected row, or an empty list if no rows are selected. The model is not returned, as documented in the
C API reference. To get the model, try "$selection->get_tree_view->get_model".
treeview = $selection->get_tree_view
$selection->unselect_all
$selection->unselect_iter ($iter)
o $iter (Gtk2::TreeIter)
$selection->unselect_path ($path)
o $path (Gtk2::TreePath)
$selection->unselect_range ($start_path, $end_path)
o $start_path (Gtk2::TreePath)
o $end_path (Gtk2::TreePath)
Since: gtk+ 2.2
scalar = $selection->get_user_data
SIGNALS
changed (Gtk2::TreeSelection)
ENUMS AND FLAGS
enum Gtk2::SelectionMode
o 'none' / 'GTK_SELECTION_NONE'
o 'single' / 'GTK_SELECTION_SINGLE'
o 'browse' / 'GTK_SELECTION_BROWSE'
o 'multiple' / 'GTK_SELECTION_MULTIPLE'
o 'extended' / 'GTK_SELECTION_EXTENDED'
SEE ALSO
Gtk2, Glib::Object
COPYRIGHT
Copyright (C) 2003-2011 by the gtk2-perl team.
This software is licensed under the LGPL. See Gtk2 for a full notice.
perl v5.14.2 2012-05-27 Gtk2::TreeSelection(3pm)