• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 326
  • Last Modified:

UNIX command for edit a file

Dear experts,

What is the UNIX command to add a string "abc" to a file def.txt?

Thanks
0
isuhendro
Asked:
isuhendro
  • 2
1 Solution
 
alextoftCommented:
echo "abc" >> def.txt

or were you looking for something a little more sophisticated?
0
 
isuhendroAuthor Commented:
hi alexoft,

actually your command is work properly when i tested in shell.. but when i wrote under karajan script, it does not work.. just afraid karajan not supporting a kind of ">>" 
do you have any other option?
0
 
isuhendroAuthor Commented:
hi alexoft,

i managed to get the answer for karajan.
anyway, your answer is correct for shell. THANKS!
0

Featured Post

Fill in the form and get your FREE NFR key NOW!

Veeam is happy to provide a FREE NFR server license to certified engineers, trainers, and bloggers.  It allows for the non‑production use of Veeam Agent for Microsoft Windows. This license is valid for five workstations and two servers.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now