S
S
Sergey2015-11-04 05:19:44
linux
Sergey, 2015-11-04 05:19:44

How to create a file with text from the console in linux without redirecting input / output streams and sed?

The fact is that there is a web project that executes commands on a different server remotely. Therefore, I/O flows do not work there. If I do the command "echo '123" > test.file", then the file is created empty. I tried to do it with sed, but it does not work. Are there other ways to create a file with text through terminal commands?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
Y
Yuri, 2015-11-04
@modestguy

touch filename

R
Ruslan Fedoseev, 2015-11-04
@martin74ua

ssh -c "echo 123 > file.txt"
and everything will work....

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question