I'm sittig behind a firewall that doesn't allow ftp. I have a conection to a UNIX system, connecting throug SSH. Is it possible to redirect the ftp through the UNIX to my computer? (1 Reply)
Hi,
I need some help to achive the follwoing task:
I have a file named test that contain the following line:
'Hellow world','good morning'
I want to attach the content of this file to a variable named var , and then rediarect it to a second file bamed test_new.
The result should look like... (2 Replies)
Hi all hope you can help as I am going MAD!!! :eek:
The below is in a shell script but the redirection in the sed line does not work and outputs to the screen and the $fname_2 does note get created ?????
Can any one help ??
#!/bin/ksh
cd /app/
for fname in `ls -1 X*`
do
sed 1d $fname... (3 Replies)
I am using the time command in a script however the output of the time command will display on my screen but not my output file. Any Ideas on how to fix this?
> cat test.sh
#############################
#!/usr/bin/sh
for COMMAND in pwd
do
time ${COMMAND}
done | sed "s/^/ ... (4 Replies)
i need to output an ls command to a file but also capture any errors from that command and output them to a log file and the screen.
if it's only possible to output them to a log file and not the screen then that's fine.
this is what i've tried so far, but it won't populate log.txt. i've... (16 Replies)
Hello again,
What im trying to do is to redirect output from a cmd, from the root, to a file. But i guess thats illegal.
I just wanted to know the file size of all files in my system. So:
cd /
du -k
but i need to ouput this information to a 'sysfile.txt' file, or what... (2 Replies)
Hello all,
I have a script that I am trying to execute and redirect the output to a file, but I have trouble in redirection. The cron job is running properly as I see it in the mail.
This is what I am doing
In crontab file,
0 4 * * * somescript.sh > /some_location/`date '+%m%d%y_%H%M'`.log... (9 Replies)
Hello
I read a lot of post related to this topic, but nothing helped me. :mad:
I'm running a ksh script with subshell what processing some ldap command. I need to check output for possible errors.
#!/bin/ksh
...
readinput < $QCHAT_INPUT |&
while read -p line
do
echo $line
... (3 Replies)
I have a script to send an email like below. Problem is, the if ..fi block is not getting executed, and is coming as a part of the email body. Can anyone take a look at this? :confused:
Log file shows this:
SEND_MAIL.prog: line 64:
: command not found
echo "Input Parameters"
echo... (11 Replies)
Hi,
I have this string that I need to match and redirect to an actual live url.
I have tried what I know and it won't match. This is the url I want to match.
http://www.abc.com/smf_test/?topic=191.0;wap2
here is my attempt at a pattern match
RewriteCond %{REQUEST_URI} ^/smf_test/$... (0 Replies)
Discussion started by: sharingsunshine
0 Replies
LEARN ABOUT SUSE
code
code(n) [incr Tcl] code(n)
__________________________________________________________________________________________________________________________________________________NAME
code - capture the namespace context for a code fragment
SYNOPSIS
itcl::code ?-namespace name? command ?arg arg ...?
_________________________________________________________________DESCRIPTION
Creates a scoped value for the specified command and its associated arg arguments. A scoped value is a list with three elements: the
"@scope" keyword, a namespace context, and a value string. For example, the command
namespace foo {
code puts "Hello World!"
}
produces the scoped value:
@scope ::foo {puts {Hello World!}}
Note that the code command captures the current namespace context. If the -namespace flag is specified, then the current context is
ignored, and the name string is used as the namespace context.
Extensions like Tk execute ordinary code fragments in the global namespace. A scoped value captures a code fragment together with its
namespace context in a way that allows it to be executed properly later. It is needed, for example, to wrap up code fragments when a Tk
widget is used within a namespace:
namespace foo {
private proc report {mesg} {
puts "click: $mesg"
}
button .b1 -text "Push Me" -command [code report "Hello World!"]
pack .b1
}
The code fragment associated with button .b1 only makes sense in the context of namespace "foo". Furthermore, the "report" procedure is
private, and can only be accessed within that namespace. The code command wraps up the code fragment in a way that allows it to be exe-
cuted properly when the button is pressed.
Also, note that the code command preserves the integrity of arguments on the command line. This makes it a natural replacement for the
list command, which is often used to format Tcl code fragments. In other words, instead of using the list command like this:
after 1000 [list puts "Hello $name!"]
use the code command like this:
after 1000 [code puts "Hello $name!"]
This not only formats the command correctly, but also captures its namespace context.
Scoped commands can be invoked like ordinary code fragments, with or without the eval command. For example, the following statements work
properly:
set cmd {@scope ::foo .b1}
$cmd configure -background red
set opts {-bg blue -fg white}
eval $cmd configure $opts
Note that scoped commands by-pass the usual protection mechanisms; the command:
@scope ::foo {report {Hello World!}}
can be used to access the "foo::report" proc from any namespace context, even though it is private.
KEYWORDS
scope, callback, namespace, public, protected, private
itcl 3.0 code(n)