Questions tagged [cat]
A UNIX utility for concatenating files or input streams together. Do not use for questions about the animal.
143
questions
0
votes
1
answer
180
views
Are there any good ways of stopping, avoiding or killing "cat bombs" (catting a large file) when using a remote session ssh or tmux?
A common problem is when you have a remote session open (ssh or tmux for example) and you accidentally cat a large file. The screen starts dumping text and you can't kill it. I am guessing those udp ...
0
votes
3
answers
2k
views
perform cat via ssh, send text or file via ssh
Greetings I am making a script to automate the sending of public keys but I cannot send my file or variable through ssh either by "echo or cat"
2
votes
1
answer
325
views
How to pipe stdout into stdin of optipng?
Is there any way to do something like this: (or why below code doesn't work?)
type input.png | optipng -out output.png
p.s: type is Windows version of cat Unix command
0
votes
1
answer
1k
views
(base) cat command doesn't work
as a newcomer to the world of Ubuntu, I was testing cat command. After creating a file with JOE, I tried to see its content with cat.
(base) someone@computer:~$ cat sth.txt
However, the result is:
...
0
votes
1
answer
693
views
Using cat in conky_parse doesn't work
I'm trying to show the name of my shell in conky. I can capture the name of the shell using this command:
cat /proc/$$/comm
But when I use this in my script.lua file, like this:
text = 'Shell: ' .. ...
0
votes
1
answer
33
views
How to add a counter starting from a number other than 1?
I have a file where I need to add 200 more lines, but I'd like to know how to renumber them automatically. The file has the following structure:
col1\tcol2\tdb4444\tcol4\tcol5\tcol6\tcol7\tcol8\tcol9\...
0
votes
1
answer
1k
views
How can I detect/remove special characters from this short text file?
This is the contents of a short text file created by an AppleScript written by someone else:
Search time: Sunday April 28, 2019 at 07:21:07
Search complete. Nothing found.
But, when I use cat I get ...
3
votes
0
answers
11k
views
CMD equivalent of cat >> text.txt
type >> text.txt doesn't work on Windows. I want it to prompt me to enter text into the document and then allow me to finish by entering control + d.
42
votes
2
answers
6k
views
Why can I cat /dev?
I can cat /dev, I can ls /dev, I can't less /dev. Why does cat let me cat this directory but no other directories?
6
votes
1
answer
3k
views
Cat hangs when attempting to read empty STDIN
My script attempts to gather information that may or may not be present in STDIN at execution time, but cat hangs if the pipe is empty. How can I ensure that my script skips this step if this there is ...
3
votes
1
answer
2k
views
What is the "next cell character" when coping and pasting from a table?
You know when you copy a row from a table and paste it into another one it is in the correct place. So what is the character that is between cell values when this operation is performed.
Eg. I have ...
0
votes
1
answer
411
views
What is the Unix equivalent of `cat` for TempleOS?
If I want to cat or a list the contents of a file on the page, what is the TempleOS-equivalent of that command?
2
votes
1
answer
1k
views
cat and grep with a huge file - Broken pipe
I am tryting to cat and grep a huge 40 GB file. After some output, my process get killed.
Any idea what can be the issue? Using OSX
[1] 37392 broken pipe cat output.txt |
37393 killed ...
1
vote
1
answer
2k
views
Append to compressed log
There is a couple of z-utilities (zless, zcat), which are able to read contents of zipped file in transparent manner.
Is it possible to append to compressed log file (in either format, not ...
19
votes
7
answers
55k
views
Cat command and echo
I'd like to concatenate the output from echo with content of a file. I've tried the following comand:
echo "abc" | cat 1.txt > 2.txt
but the 2.txt file only contains the content from 1.txt. Why ...