Questions tagged [echo]

echo is a common command to print a message onto an output device, like a display

Filter by
Sorted by
Tagged with
1
vote
2answers
49 views

(git) Bash: how exactly does a line break differ from \n in a variable?

My apologies, I must have made some mistakes when performing the initial tests, as after putting everything into a single script the xxd output does indeed always match the stdouput. The entire script ...
0
votes
0answers
34 views

use echo to write to file and include single quotes

I have the command here doctl compute ssh testdroplet --ssh-command 'echo -e "import http.server\nimport socketserver\nfrom http import HTTPStatus\n\nclass Handler(http.server....
0
votes
1answer
51 views

Supress stdout except for echo commands but show stderr

I have put a very large bash script together that installs packages and configures a LAMP stack etc. With any scripting I usually do, I like to tidy it up by using echo commands to let the user ...
0
votes
2answers
47 views

7zip password protected zip - SHOW the password that i type

wondered if, when i unzip a pasword protected file and it says "enter the password, it will not be echoed" if i could see either what i type or paste (echoed!) OR a ***** to show that what i'...
0
votes
0answers
26 views

Command prompt Echo with Plink

good day, I tried to use the format below for my plink and when I went to login with the username I changed the password on it didn't accept the new password. so my question is, when using "(...
1
vote
0answers
41 views

CMD echo working with PLINK>exe

good day, I tried to use the format below for my plink and when I went to login with the username I changed the password on it didn't accept the new password. so my question is, when using "(...
0
votes
1answer
35 views

Create a Automate script and use another script is echo password

I have created a fully automated script which uses ssh login to login from one server to another and do some file operation, but the script is not fully automated as it prompts for a password, we do ...
6
votes
3answers
2k views

How do I create a command on Windows without having to create a file?

I want to create the command hello without having to create a file like hello.bat. I want the command without the file. The command must execute an echo Hello World!. Is there a way to do it on ...
0
votes
1answer
29 views

Is it possible to make a bash script to simplify using echo to overwrite the same text file with new text?

What I'm trying to do is simplify using echo as I will be overwriting the same file each time with different text. Currently I'm using this in the terminal: echo "blah blah blah blah" > /home/...
1
vote
1answer
42 views

What is echo doing?

Recently, I noticed that echos in which I include lots of "!" result in weird stuff. For example: echo !! gives me: echo rm -r * 1000 rm -r * 1000 (rm -r * was the last command I executed before ...
3
votes
2answers
380 views

redirect echo in a cmd batch file to a variable fail

I use the below function to check if echo is set on or off, and as you can see it pipes echo statuse and then uses the output to set a flag: FUNCTION :echos echo > echo.txt & rem pipe ech ...
0
votes
2answers
6k views

How to connect Echo Dot to University protected wifi

I recently won an Echo dot in a Hackathon and I was very excited to try it out but sadly the dot does not connect to 'Eduroam', the university network. The Uni site says that eduroam uses '802.1x ...
0
votes
1answer
1k views

whitespace padding a file length using echo in a windows batch file

I'm using a for loop in a windows .bat file to make a text-file listing files in directories. FOR /R %%G in (*) DO ( ECHO %%~zG %%~nxG >> zzz-list.txt ) [Phone won't let me input a tab ...
0
votes
0answers
293 views

Blue Snowball Ice usb mic has echo sound

I use the Blue Snowball Ice usb mic. I have put mic around 6 - 12 inches from my mouth. I have used screen cast ometic Normalize and Reduce Noice functionalities of that tool. But I can hear a big ...
0
votes
1answer
88 views

My echo file is returning the incorrect order for files

So I'm using FFmpeg to join a list of .ts files together, to do this I need to create an echo file with all the names of the .ts files in chronological order. The files are all named as numbers, in my ...
1
vote
1answer
35 views

Dir piped into Set

Im trying to make a program that selects a file name, then pipes it into a variable. My Attempt: Dir /B "C:\Program Files (x86)\ServerMaster\Internals\Versions\Van1" | (set /p myVar= & set myVar)...
1
vote
1answer
280 views

Difference between echo $(cal) and echo “$(cal)” [duplicate]

I'm using echo $(cal) and echo "$(cal)"in Linux and it gives me different results as in the picture. The double quotes should not interfere with $ in this case, so what gives the echo "$(cal)" that ...
0
votes
2answers
98 views

How to redirect output to a file so the previous redirected output is not lost?

I'm quite new to all this, trying to run a basic batch file to output some commands to a document. It works fine until I add some more echos in. Example: echo "Failed Drives" > Report.rtf ...
1
vote
2answers
1k views

bash script:echo output garbled and in wrong order

I am having an issue with a bash script that is echoing output in an unexpected order. The script is as follows. The problem is with the output of lines 30-32. 1 IFS=$'\n' 2 i=1 3 bluered="" 4 ...
0
votes
1answer
1k views

How to read a .txt file in a batch script on a network? [closed]

I'm making a little game because I was bored and I want it to work in a LAN network, my map files are in a shared file. When I try to echo the contents nothing comes out. Here is the code: ( ...
0
votes
1answer
176 views

Add variable space at the end of line in file

I want to add white space at the end of each line. Number of white space is in variable. If number of white space is fixed then I can use this command sed 's/$/ /g' for two spaces. space_variable=...
1
vote
0answers
68 views

Can't access server with username that has spaces

I amn trying to test out how PsExec work. However, even when I'm trying to simply send a 'echo Hello', with the correct password and everything, it says that couldn't access the other computer. Here'...
0
votes
1answer
175 views

How reinstall the /bin/echo in my debian?

Something wrong for my /bin/echo command. sudo ls -al /bin/echo -rwxr-xr-x 1 root utmp 0 Nov 11 18:05 /bin/echo method1 to fix it: I knew that /bin/echo is in coretils. Remove coreutils first then ...
0
votes
3answers
1k views

find: ‘echo’: Permission denied

It is my os info: sudo uname -a Linux machine 4.9.0-8-amd64 #1 SMP Debian 4.9.110-3+deb9u6 (2018-10-08) x86_64 GNU/Linux Files beginning at test in /tmp. ls -al test* -rw-r--r-- 1 debian9 ...
0
votes
1answer
547 views

How to create a file with multiple lines and / - Windows Command Prompt

How can I create a file with multiple lines, / and " ? I am trying to create a scss file where I the text has multiple lines, / and " Is there any way where I don't have Here is the code I have ...
1
vote
0answers
200 views

Batch Banner colored only

I would like to have the banner that I call always in red let's say and all the other text be white. How can I do ? Thank you. :BANNER CLS echo ___ _ _____ echo ...
1
vote
1answer
193 views

Set arbitrary text to windows clipboard

I'm using clip to set text on the clipboard. To do that, I use echo. echo Works|clip The problem is when the text contains special characters, eg. | ". echo (TRUE|FALSE)|clip echo " is a Quote Mark|...
1
vote
1answer
4k views

use echo and another command in the same line in batch file

For for this code echo x set /p "a=>" result will be x set /p "a=>" The result i want is x> Please help,thanks
35
votes
2answers
5k views

What is wrong with “echo $(stuff)” or “echo `stuff`”?

I used one of the following echo $(stuff) echo `stuff` (where stuff is e.g. pwd or date or something more complicated). Then I was told this syntax is wrong, a bad practice, non-elegant, excessive, ...
0
votes
2answers
814 views

Echo: Multiple commands

Hoi everybody, I am currently struggling with having to execute multiple commands in an echo. The following line is an example of the problem I am having: echo (cd .. && pwd) The idea is, ...
3
votes
1answer
6k views

append to end to line without newline

When i try to append to the end of a file it creates a new line. Now I have tried to fix this with echo -n but that doenst work. So what am I trying. I'm trying to get the following result: Hello ...
0
votes
1answer
38 views

How to echo from web to a file in windows terminal?

What I want is to run a command in a terminal that will download a Visual Studio git ignore raw file, save it to .gitignore file in a folder where my terminal is opened on my Windows 10 machine. I've ...
2
votes
1answer
2k views

Eval and echo use together

I want to know if the code below can be improved of how it is written is the way to write it. If it wasn't clear I am a newbie to bash but my script completes its purpose. This code is trying to ...
1
vote
2answers
49 views

Bash echo from input file with additional data

I currently have thousands of .jdx files and I've managed to find a way to get the lines I need from the files echoed into a new file. What I cant seem to do is get the additional data I need to be ...
4
votes
2answers
1k views

Writing ECHO output to VBS File not working

I am writing a Batch Script that creates a VB Script by echoing each line and directing the output to the created file. It works for the most part, except for two lines that get Command Line variables ...
2
votes
1answer
59 views

echo command issue on Unix server

I am trying to copy some configurations to unix endpoint using below echo command, after copying i see few characters are missing or sometimes gets prefixes. example below. need your suggestion here....
20
votes
1answer
10k views

Why does `echo -e “\\\SOME_TEXT”` show only one backslash?

Could some one explain what is happening behind the scenes in character escaping in Linux shell? I tried the following and googled a lot, without any success in understanding what (and how) is going ...
1
vote
1answer
1k views

Using watch command with “echo -e”

I want to monitor rows of a dynamic file and I use watch command for this. I have 2 files: test-status and iplist_test. I control something in iplist_test and I type this output to test-status. ...
1
vote
3answers
182 views

Why is the output of this echo command over-running into multiple lines?

I have a directory of photos whose names are the time and date the photo was taken. E.g: ~$ ls directory -1 2003-09-15 03.30.33.jpg 2004-05-04 12.45.28.jpg 2004-05-04 12.45.51.jpg However, if I run ...
31
votes
2answers
103k views

Path Environment Variable Windows 10. Echo %Path% on command prompt shows only %Path% [duplicate]

My variable value in path is as follows C:\ProgramData\Oracle\Java\javapath;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;C:\Program ...
0
votes
1answer
143 views

Echo Variable To File Without New Lines

I want to get rid of new lines in Echo then suffix a file with them. files=$(cat ./Temp/files.txt) prefixedfiles=$(cat ./Temp/prefixedfiles.txt) echo "$files" >> generatedscript sed -e 's/^/...
0
votes
1answer
1k views

Replace line feed with a character

I want to replace \n with a character. echo -n "s\n" |tr "\n" "a" s\n Why can't get sa as result?
0
votes
0answers
432 views

CECHO echoing a big ASCII art

I went online and found a tool called cecho which is batch file's echo with color. I have a big piece of ASCII art(237 x 57 char) and I want to use cecho to color them. As far as I know, I have to ...
0
votes
1answer
416 views

I have a wonder for ARP echo issue

I am studying for network and I have a question for ARP echo issue. I use Wireshark for packet capture, and I OS is windows 7. contents ARP Basics ARP stands for Address Resolution Protocol. When ...
25
votes
2answers
5k views

Why use echo before installing new software?

I am new to the computing world. While installing ROS Indigo, the first step directs me to use the following code: sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" &...
0
votes
1answer
3k views

Batch variable echo

I'm trying to save user input variables from a batch file into a text file. So that some javascript can read the file to use the variables. This is what I have so far: :varecho echo %GAMEPIN% > ...
0
votes
1answer
714 views

Alexa setup not recognizing router password

After I choose my WiFi router in the Alexa app, I'm asked to enter my router password. For some odd reason, Alexa won't take it. Tried resetting my Arris router/cable modem AND Alexa and got nada. Any ...
1
vote
1answer
769 views

How to do division and rounding within the string?

I am new in scripting and I'm working with a tool which is exactly like windows cmd. My input text file is : age=min;age_1D_param_min_64;meas_time = My batch file reads the lines from this input and ...
0
votes
0answers
1k views

Automatically create subfolders by date and move files into subfolder at the end of the day

I use the software iSpy to record audio and I have set it up to save the recordings to a folder. The problem is that there is no organization at all, so I have thousands of audio recordings in one ...
1
vote
1answer
87 views

Batch echo command issue

It is inside the 2 pauses. I cannot understand why it is not working. Do mind the rest. It is a part of TGBF. As far as I can tell the text after the echo is an error, but I don't know why? Does it ...