Welcome to the Linux Foundation Forum!

Bash script add text to the same line

HI again! I have a question about Kdialog. I'm using echo to append a text file. The script writes two lines of text to a pre chosen text file, lets say /user/Desktop/file.txt

I know this is a bit vague but I'm still new to scripting. Is it possible to append the text file so that both commands are run on the same line?

Thanks in advance

TheYikes

Answers

  • perhaps i should clarify things. I have a kdialog script that starts with a --fselect window followed by a combobox. So to begin with the --fselect chosen file is written to /home/Desktop/Attemp.txt. Here's where I'm confused. The second option is a combobox works but it seems to be adding the combobox to a new line in the text file. Is there any way to add both to a single line?

  • Would Adding && after the first help?

Categories

Upcoming Training