Questions about using the command-line interface (CLI).

learn more… | top users | synonyms (6)

2
votes
5answers
856 views

Is there any command in Linux which does not make a system call? [on hold]

I was reading about system calls and I got a doubt whether any command runs without making even a single system call. If not then what is the command with minimum number of system calls? I used strace ...
21
votes
5answers
21k views

How do I download the command-line emacs instead of the GUI one?

I used sudo apt-get install emacs to download emacs. I expected the command-line emacs to start when I ran emacs but instead the GUI emacs started. How can I download the command-line emacs?
54
votes
15answers
41k views

Running a .desktop file in the terminal

From what I can gather, .desktop files are shortcuts that allow application's settings to be customized. For instance, I have lots of them in my /usr/share/applications/ folder. If I open that ...
0
votes
1answer
24 views

renaming files script error

I wrote code to change the name of bulk of file it should replace spaces with underscores and lowercase all the file name .. this is the code for file in *; do mv "$file" `echo $file | sed -e 's/ ...
0
votes
1answer
26 views

Changing themes and environment variables :: 14.04 lts

Hey i'm having problems trying to find an editor for the theme color options, particularly pertaining to the field color and text color for general windows. I downloaded the new version of the ...
2
votes
2answers
75 views

Why is my repetition condition with grep range not working?

Searched for a solution on SO, Ask and Unix/Linux but I am lost trying to figure out how to write a conditional with a grep range: Go through: 1-20_something 100-200_something 2-100_something ...
0
votes
1answer
13 views

Continuous logging of a filtered TCP stream

I am trying to log messages from a program "adsbox" that sends text lines on TCP port 30003. These lines are ADS-B messages received from passing airplanes. The rate is a couple of lines per second. ...
0
votes
0answers
19 views

Matlab Installation in Ubuntu 12.04 via terminal

Whenever I try to install Matlab 2014a in my ubuntu 12.04 via termianl then it shows the following error: fixme:heap:HeapSetInformation 0x2c4000 0 0x23fce0 4 fixme:win:RegisterDeviceNotificationA ...
0
votes
0answers
33 views

ElementaryOS Freya Installing RVM and ruby problems [closed]

Hi i have problem installing RVM and Ruby itself with ElementaryOS freya. I have installed RVM but when i try to install ruby running. rvm install 2.2 i get this. Searching for binary rubies, this ...
9
votes
1answer
214 views

gedit top menu invisible when started from terminal and using x11-Forwarding

Given: I'm using export $(dbus-launch) in my /etc/bash.bashrc file as I'm normally running under a non-admin user and need to su - admin to do anything dangerous. Normal behaviour: Go to dash, open ...
1
vote
1answer
49 views

Script to open terminal in particular directory, in particular workspace, then VIM to a particular file

Bonus: vsplit to another file. ;) I have 9 workspaces, and often have multiple terminals running VIM on different files. The setup is pretty standard for a project—but I have to go about opening ...
0
votes
2answers
498 views

What does the “apt-get dselect-upgrade” command do?

When running the command apt-get I got all the possible options and commands for apt-get. But one of these commands and definitions I have not seen before: dselect-upgrade - Follow dselect selections ...
0
votes
1answer
123 views

How to Compress (More than one at a time) PDF files from terminal

I work with lots of rather large imaged documents ranging from a few bites to multiple gigs of data per file. I need these documents to take up less storage space and especially to be more ...
28
votes
2answers
39k views

Is it possible to clean the APT cache from the command line?

I ask because Ubuntu Tweak's Janitor is frozen due to the sheer number of packages in the cache that accumulated during the upgrade from 12.10 to 13.04.
1
vote
4answers
204 views

Grep strings in a subgroup of lines in txt file

I have a file that looks like this AAA_21 PF13304.1 x_00004 AAA_22 PF13401.1 x_00004 SMC_N PF02463.14 x_00004 AAA_29 PF13555.1 x_00004 ...
0
votes
2answers
200 views

Start an aliased application from shell passing relative path of a document

I "aliased" a shell command in this way: alias "myapplication"="/home/manuel/myapp/bin/startapp.sh" Now i'd like to pass to it a relative file-path where i am when i execute the aliased command, ...
6
votes
3answers
8k views

using grep with pipe and ampersand to filter errors from find

I am using cygwin to find a file on the cygdrive. However I need to suppress the permission denied messages (otherwise the results get hidden in the error messages). The following command works: ...
0
votes
0answers
23 views

Make terminal look the same for all users

I know that probably his might be a really dumb question, but I don't know exactly what should I google to make this work the way I want. I have a server with Ubuntu 14.04. The idea is that the only ...
0
votes
4answers
77 views

How to uninstall app from sudo command in the terminal [closed]

Keepass2 has been installing for 6 hours. Im not able to remove app.
13
votes
4answers
54k views

How to search for files containing specific word?

How to search for files containing specific word?
0
votes
2answers
23 views

How can I force terminal to always open in a specific desktop, regardless of which one I'm in when I press the shortcut

Basically the title. Using Lubuntu 14.04. Use case: I have two desktops, I'm in #1, I press Ctl Alt T , it opens in Desktop 2. I'm in #2, press Ctl Alt T it opens in Desktop 2.
4
votes
2answers
437 views

What's the difference between + and = when using chmod?

I read everything about chmod, but I don't get something. If I write chmod u=rwx file this "affects" me for all rights on the file, and if I write chmod u+rwx file this "adds" me all the rights on the ...
2
votes
1answer
24 views

How to check the default handler for a specific file type in Terminal?

I often come across file types which I am not sure of, but yet need to open, but as I don't know what the default file handler on my system is for that specific file type (and sometimes the file ...
4
votes
1answer
103 views

How to add flags and/or arguments to a command in the 'sudoers' file

How would I add flags and/or arguments to allow users in the sudoers file to run certain parts of commands, such as only allowing a user to run sudo rm and not sudo rm -rf? I am using 14.04. # # ...
1
vote
0answers
24 views

DD command to copy broken drive HELP! [closed]

I want to copy the data of a broken hard drive to an other. Arrive to the conclusion: dd if=/dev/disk2 of=/dev/disk3 bs=4k conv=notrunc, noerror but here is the answer: dd: unknown conversion ...
0
votes
0answers
15 views

blinking mouse cursor [on hold]

weeks ago I installed Ubuntu on my brother's computer, the following days he told me than his mouse cursor was blinking and he couldn't use it. I have an idea, there was this unknow screen in the ...
0
votes
1answer
72 views

error installing mongodb on trusty

I'm trying to install mongodb on the trusty tahr following this tutorial: http://docs.mongodb.org/manual/tutorial/install-mongodb-on-ubuntu/. When running the first command (sudo apt-key adv ...
17
votes
1answer
23k views

Arrow keys, tab-complete not working

I have installed ubuntu minimal(mini.iso) on my vm. I then used recovery mode to login as root and create an account with useradd -m admin and then set a password with passwd admin. When I login on ...
0
votes
0answers
19 views

Xilinx ISE in Ubuntu

I recently installed Xilinx ISE 14.7, which works so far, but everytime I bring up a terminal window, now, I get the following lines in the terminal window before my cursor prompt. . ...
0
votes
0answers
22 views

rc.local commands execution

The general idea is: I have developed a script.sh (in java) that take a value from a .txt where a python code is saving data from a sensor, (with a specific range of time). This value is up to the ...
1
vote
1answer
43 views

How do I run this script with sudo from the command-line? [duplicate]

I have the following script in my user's bin directory; let's pretend the filename is 'myScript': #!/bin/bash python3 /myPath/myProgram.py "$@" From the commandline, if I type myScript, it ...
4
votes
3answers
9k views

How do you view file permissions?

I want to know how to see the permissions a particular file has. Which command should I type in the terminal? However, I don't want to change it.
2
votes
1answer
220 views

Where's my phone mounted to browse it from shell? [duplicate]

I have connected a smartphone and would like to copy some file onto it using midnight commander. I've found out that the mount point is mtp://[usb:002,004]/Card/ however when I try to run cd ...
1
vote
2answers
74 views

The foreground color changes after `ls` command

I change shell's foreground color with echo -ne '\e[1;31m' command but when I execute ls command the foreground color reverts back to the original previous color. This weird behavior doesn't occur ...
0
votes
0answers
33 views

Different terminal color for local and ssh (ALL ssh connections) [duplicate]

I want to use different colors for gnome terminal when I (1) work local on my computer (for example, green font) and (2) remote by ssh (using ssh keys) (for example, red font). I found many answers, ...
0
votes
1answer
24 views

how to export folder specific environment variables?

I have two projects on my computer that require JAVA_HOME to point to jdk7 and 8 respectively. Right now I'm working around this by having 2 files in my home folder that i source to set JAVA_HOME ...
21
votes
8answers
12k views

Is there a web based terminal/ssh client?

I'm at a public place, windows computers galore (library). I'm sshing into my ubuntu server box somewhere else. I open command prompt and remember that I read "you will be banned from using the ...
2
votes
2answers
66 views

How to embed a terminal into the desktop on Ubuntu?

I'm pretty new on Linux, so sorry if it's dumb, but is there a way to embed the terminal into my desktop? And btw, if the anwser is yes, can I embed another terminal on the side who only shows my ...
9
votes
7answers
3k views

How can I modify my `ls` command?

When I type ls, i get the normal list, or when I type ls -la I get a details version with everything... But I hate the layout of ls, it's just unintuitive for most of my use. Is there some way I can ...
0
votes
1answer
32 views

12 Hour Time Instead Of 24 in linux [duplicate]

I want to set my linux machine box 12 hours format,how to set it ,please advise I am able to display with #date +%r,but wanted to set it permanently
0
votes
1answer
92 views

How do I export a variable to the `sh` shell? [duplicate]

Calling export MYVAR=/path/to/whatever from .bashrc obviously works for bash but not for the sh shell. Unfortunately, the Matlab launcher seems hell-bent on using sh and not bash. As such, the ...
2
votes
1answer
281 views

How to permanantly change the color scheme of the terminal?

I have just installed solarized color scheme for ubuntu gnome terminal. I have followed this tutorial. eval dircolors ~/.dircolor - this command s causing problems. When I use this command, it ...
6
votes
4answers
13k views

How to count number of files in a directory but not recursively

Simple question I'm sure. I've seen an answer that show how to do it including subdirectories, but I want to know how many files (not folders) are in the current directory only. Thanks.
0
votes
1answer
46 views

how to configure terminal in a text boot?

I use tmux in xterm and gnome-terminal.Configuring gnome-terminal's background and foreground is not an issue as it can be easily done through gui itself.Few things to mention: I can configure ...
0
votes
1answer
32 views

How to change file text content only with Shell Script commands?

In a file, there is: sd5_crypt UUID=1337 none luks,discard I'd like to change it to: sd5_crypt UUID=1337 /dev/disk/by-label/MON_LABEL_ICI:/keyfile luks,keyscript=/lib/cryptsetup/scripts/passdev ...
0
votes
1answer
35 views

How to write a shell script to start gedit and not showing the terminal window? [closed]

How to write a shell script to start gedit and not showing the terminal window? That means: when I click the file runme.sh, only gedit window shows, no terminal window shows. Just like I click the ...
0
votes
2answers
34 views

Problem extracting tar file

I have tried the command : tar -xjvf FileZilla_3.7.1.1_*-linux-gnu.tar.bz2 After Giving this command getting these errors : tar (child): FileZilla_3.7.1.1_*-linux-gnu.tar.bz2: Cannot open: No ...
4
votes
3answers
18k views

How do I run NetBeans from the terminal?

I have installed a JDK + NetBeans bundle from the downloaded .sh file. Now I have the NetBeans shortcut on my desktop but I can't run NetBeans from the terminal. When I run: sudo dpkg ...
0
votes
1answer
38 views

Is it possible to have a unique theme for Vim in Ubuntu Server

I recently started managing my own Ubuntu Server and I'm constantly using Vim to edit my files and I was wondering if it was possible to install a them to use overtime I login to my server? The ...
1
vote
2answers
25 views

Unable to exit TUIs due to F10 opening the File pull-down menu instead of quitting the program as meant to

I use applications such as Midnight Commander, and htop, however I have a problem when quitting, I am forced to either terminate the process, or to click on the quit button myself, if there is one, ...