Topic "Custom Commands: prompt"

Author Message
Hackepeter

Guest


Hopefully I find a way to describe what I want to do...

I have some custome commands set to extract(grep) datasets from bigger file to an extra file with a special name.
her is my command:
Code:
cat ! | egrep '^E.!?input:?0000000000!' >extract_TR_###.file

At the position ### I want to set the filename to what I have typed in the prompt.
How can I do this? Is there a special variable used for what was passed by the input(prompt)?

Thanx
Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24991
Location: Prague, Czechia
Please read documentation.
_________________
Martin Prikryl
Hackepeter

Guest


Thanx,

but I think my question was not clear enough. Sorry for my english..

In the command I ask for a parameter to search for. OK

I want to write the grep-output to a file named with the search-parameter.
for instance:

If I search for the string 01234567 then I want to write a file wich is named: extract_01234567.file

My question was if this is possible without asking twice with an ?input-command

Thanx again
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24991
Location: Prague, Czechia
Sorry, I've missed that. It is not possible.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License