Skip to main content

All Questions

0 votes
1 answer
71 views

When is useful use "silent" for tty?

If the tty --help command is executed it shows tty --help Usage: tty [OPTION]... Print the file name of the terminal connected to standard input. -s, --silent, --quiet print nothing, only return ...
Manuel Jordan's user avatar
9 votes
1 answer
2k views

What does >&- do in a unix / linux terminal?

I'm not too knowledgeable in the Unix command line. I found this SO answer for using the tee command without outputting to stdout, by "closing stdout" with >&- like this: echo 'hello ...
Oneechan69's user avatar
-2 votes
2 answers
4k views

How to turn off colors for a specific command?

Is it possible to turn off colors for a specific command like ls, but without using the api of the command itself? Is there an env variable kind of thing that will turn off coloring for a command like ...
KMA Badshah's user avatar
-1 votes
2 answers
201 views

What is com command in linux?

I saw in a video on Youtube : $ sudo com /dev/ttyUSb0 115200 [sudo] password for xt003: setting speed 115200 C-a exit, C-a modem lines status [status]: RTS DTR What is com command? I searched for ...
mmj's user avatar
  • 109
16 votes
3 answers
59k views

Execute command without terminal output [duplicate]

Let me give a bit of background to my question. I am using a terminal RSS reader newsboat which allows for the usage of macros to operate on links. For example, I have a macro running cd ~/videos &...
user avatar
-2 votes
4 answers
512 views

Manipulate terminal input

Is there any way to manipulate terminal input before it gets executed? Example: apt-get update is entered in the terminal. Now I want to change it to sudo apt-get update before it gets executed. ...
ADDB's user avatar
  • 488
0 votes
1 answer
194 views

Delete file returned by "mpc search" with single command

using the mpc search command I can find a the filename of a song like so: mpc search title 'Two Weeks' The output would look like this: Grizzly Bear - Two Weeks.mp3 Since I also know the location ...
Ederbit's user avatar
  • 103
3 votes
2 answers
1k views

How can I type a command to execute when the current command completes?

I have a function (not) that displays a notification. Hence, I can use it to show when a command is complete. sleep 5; not However, sometimes I forget to add ;not. In OS X's terminal (a few years ago)...
Sparhawk's user avatar
  • 20.1k
15 votes
5 answers
18k views

How to recall a previous command (without execution) in order to change it?

I can't remember the trick where I could get the last command without running it: let's say I want to be be able to access the command !1255 when pressing the up arrow key and modify the command. So ...
Arturas M's user avatar
  • 254
5 votes
1 answer
51k views

command to clean up old log files

I was trying to automate some auto cleaning of my Ubuntu System, with Cron Jobs I tryed to simplify this: sudo find /var/log -type f -name "*.1.gz" -delete sudo find /var/log -type f -name "*.2.gz" -...
DiogoSaraiva's user avatar
0 votes
2 answers
314 views

What are the meanings of different Unix commands? [closed]

I am running Ubuntu 14.04 on my machine. I am feeling lost when I see different command line commands (or what exactly are they called?) like sudo, apt-get, mkdir, -R, -n etc. while installing ...
anujit's user avatar
  • 3
-5 votes
1 answer
74 views

In what directory can I find the list of terminal commands or the set of scripts that give each one its purpose/power?

Is it hidden or accessible? Also, can you create a new script and define a new command to execute system-wide by adding it to this directory and giving it the same privileges?
Dbo's user avatar
  • 107
1 vote
1 answer
565 views

Mysql import the most recent file from a directory

I have a directory with daily backups of my entire MySQL database. I want to import the most recent backup into the database. I know to import a backup I need to use mysql -u root -ppasswordhere &...
Ivan Dokov's user avatar
2 votes
3 answers
2k views

Using globbing/wildcards when Opening Files from Terminal

I have a folder A. Inside the folder, there are some files a,b,c,d and there is a subfolder, B, containing files e,f,g. Suppose I want to open files a,b,c,d: then I just type xdg-open *. However, ...
Newb's user avatar
  • 1,092