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

learn more… | top users | synonyms (5)

2
votes
2answers
20 views

apt-file regex: escaping a dot

I want to find all packages which provide a shared object containing "ssl" in the file name. The apt-file manpage says: --regexp | -x Treat pattern as a (perl) regular expression. ...
2
votes
4answers
54 views

Remove whitespace from all array elements

I have a array called arrayvar, which is being defined as arrayvar=( $(awk '/'"$vovar"'/,/}/ {gsub("'"$vovar"'"," "); gsub("}"," "); gsub("{"," ");gsub(","," ");print}' temp1 | tr -d '\n' | sed ...
0
votes
3answers
114 views

How to Keep Text Consistent in A Shell Script

Good Day! I am creating a Shell Script so I can then use it to do X (Won't tell) This is my Current Script clear echo Ahmad A Kazi echo IDNO: BD_3456 echo echo Data Clear Program echo c 2015 Ahmad ...
2
votes
1answer
17 views

Extracting subfolders into a specific folder

I have a bunch of sub-folders with respective rar and 7z files. How do I extract all of these and tell the pipe to output to a specific folder?
0
votes
0answers
8 views

Please help me with my extension

I am creating a small gnome shell extension.For that I need to access the file tree of my shell,but it has to be done using Javascript.Can you please tell me the name of the module in Javascript for ...
2
votes
5answers
62 views

Add particular strings to an array sed/awk/grep

I have this ciscoFlashCopyStatus OBJECT-TYPE SYNTAX INTEGER { copyOperationPending(0), copyInProgress(1), ...
3
votes
0answers
17 views

Xfce 4 Terminal how to wrap text

I used to use the default gnome-terminal as my default Terminal, but because I want it to be see-through I have switched to the xfce4-terminal. But there is one problem, the text does not wrap, and I ...
3
votes
3answers
1k views

What is a easy way to view texi files?

I am reading some files for a library I plan on using and the files are of extension '.texi' and although I can open the files in gedit, all the syntax and markups make it difficult to read. Also, I ...
19
votes
2answers
411 views

When run cat says: “Hello, nothing to see here! Move along!”

PLEASE NOTE: To view the comments on this and the extended discussion on this, which includes all that has been tried, please look at this chat room. Today when I ran the cat command, instead of ...
-1
votes
1answer
25 views

Use of quotes when running commands on a remote machine using ssh

I have a command that I know works correctly when I remote into a machine and run it. The command is below: grep "SearchTerm $1" file.txt | sed 's/^.*SearchTerm $1,//g' | sort | uniq -c | ...
5
votes
2answers
12k views

How to rebuild fstab automatically

I accidentally removed all the entries from the fstab files while doing a backup (Yeah, I know ;)). I would like to know if there is a way to rebuild it with the current mount options, since I did ...
1
vote
5answers
42 views

Ubuntu 14.04: New user created from command line has missing features

I am trying to create a new user in Ubuntu 14.04 LTS from the bash command line. I use the following commands: sudo useradd -c "Samwise the Brave" sam sudo passwd sam Enter new UNIX password: ...
63
votes
10answers
87k views
3
votes
6answers
1k views

Find files with a specific 2-line pattern using awk

I have a few hundreds of files that has this pattern @<TRIPOS>ATOM 2 H18 65.2220 Du 1 RES1 0.0000 @<TRIPOS>BOND 1 3 5 ar @<TRIPOS>SUBSTRUCTURE among them, some of the files ...
0
votes
2answers
59 views

Text Editor Scratch

I am trying to install a text editor named Scratch,which is the default text editor in Elementary OS. I've done the following commands. sudo add-apt-repository ppa:elementary-os/daily sudo apt-get ...
1
vote
2answers
45 views

I just ran cat /dev/zero and now cat is hanging

I ran cat /dev/zero and it now just hangs whenever I run a cat command. I pressed Ctrl+C to stop that command. Have I broken something, and how can I fix it?
0
votes
0answers
15 views

How can I make the bash pager recognise the terminal window width setting?

I checked that/bin/less is the default pager inside the bash shell. Try for instance: $ man man | egrep regex It does not automatically recognize the terminal window's width setting I have set to ...
11
votes
3answers
2k views

what does -x mean in if conditional statement?

What does -x mean here: if [ -x /etc/rc.local ] then How could I find out this manual page for if?
1
vote
1answer
32 views

BASH->Python (2.6) piping

I need to translate this line of Bash into Python: sample1=($(/bin/cat /proc/meminfo | egrep 'MemTotal|MemFree|Cached|SwapTotal|SwapFree|AnonPages|Dirty|Writeback|PageTables|HugePages_' | awk ' { ...
0
votes
0answers
11 views

How can i install and launch xmonad on ubuntu server?

I have started from a clean install. I have installed xorg and openbox, then xmonad via sudo apt-get install xorg sudo apt-get install openbox sudo apt-get install xmonad but i can't get it to work. ...
0
votes
0answers
13 views

How do I enable desktop notifications, including audio, of when terminator is finished executing commands?

I know that on Fedora you get popups and audio notifications that appear whenever a command has finished running in GNOME Terminal. I was wondering if something similar was possible on Ubuntu in ...
1
vote
2answers
83 views

How to run xrandr commands at startup in Ubuntu

How can I run the following xrandrcommand on startup? xrandr cvt 1368 768 xrandr --newmode "1368x768_60.00" 85.25 1368 1440 1576 1784 768 771 781 798 -hsync +vsync xrandr --addmode VGA1 ...
1
vote
2answers
29 views

How can I convert mp4 and mkv to 3gp?

I've a directory with 28 mp4's and 2 mkv's. I want to convert them all to 3gp using avconv. How do I do that?
2
votes
7answers
477 views

Remove duplicated dots from file name

I have a dir with tons of files inside which have been named in malformed such as file..txt ,file2..txt ,etc... So how to easily remove this second . from file names? Any applicable method is ...
0
votes
2answers
64 views

Shell script options with parsing arguments

I have the shell script CONTROLLER_IP="" if [ "$#" -eq 1 ] then CONTROLLER_IP=$1 else echo "Usage : create_endpoint.sh --controller-ip <Controller IP>" exit 1 fi but its executing ...
0
votes
0answers
20 views

How to restore the default factory name of my device?

I had change my device name, and I would like to get back to default name that comes when I buy it. I know how to change the name by command-line, but is there a command to restore the device name to ...
1
vote
1answer
411 views

Xubuntu Terminal Cursor

I am running Xubuntu 14.04 and the default Terminal Emulator (xfterm I think). The terminal itself is fine but I want to change the cursor to a blinking underline rather than a solid block. How do I ...
1
vote
1answer
14 views

Problem with Comodo Installation

After installing Comodo, though logged in as adminstrator, tried to run /opt/COMODO/post_setup.sh and it says Please run this script with adminstrative priviledges even though I am logged in as ...
0
votes
0answers
49 views

Copy directory on destination machine during .deb installation in Ubuntu 14.04, 64 bit

I just want to copy directory (which contains some files) on destination machine during .deb installation at path /opt/myProjectName in Ubuntu 14.04, 64 bit. Right now I am successfully able to ...
0
votes
1answer
30 views

how to write c program code to display directories in linux terminl [on hold]

i want a c program to get all the directories from bash terminal.also i need to color different types of files in different colors. eg:-executable files should b displayed in green color, ...
1
vote
0answers
25 views

.desktop launches app with custom icon. why not shell?

I have a .desktop file that launches an app, and it uses the .desktop icon: [Desktop Entry] Name=My Ro Type=Application Comment=Web Application Exec=/path/to/myapp -test Icon=/opt/giteye/icon.xpm ...
0
votes
3answers
53 views

Use of the Rename Command

I have a two part question. I have a series of files with the names "file.pdb.#", where # is an integer. 1.) How can I script to rename all the "file.pdb.#" to "file_#.pdb", where the integer is ...
4
votes
2answers
2k views

Why doesn't “whereis” locate a file?

I was looking for a specific file using whereis from the command line. I got a rather useless result, but I then found the exact file I was looking for by manually searching. I did not make a ...
58
votes
5answers
65k views

Coolest looking terminal IRC client [closed]

I am looking for a IRC client for the terminal that has colors, user list and just generally looks awesome ;) Any recommendations? There are loads of IRC clients in the repositories and I don't want ...
14
votes
2answers
4k views

Why there is no nsenter in util-linux?

I frequently using nsenter command for my purposes in my main system under Arch Linux. Now I have to work on Ubuntu to test my apps on it, but there isn't nsenter in util-linux. Maybe it's a separate ...
0
votes
2answers
39 views

Is it possible to highlight a text and to use a keyboard shortcut?

In order to install something usually have to run some commands. In order to make it quicker, could I highlight some command text on the internet I want to run in terminal, then press a keyboard ...
-1
votes
2answers
610 views

install 'Line" in ubuntu 14.04 64 bit using wine

im using ubuntu 14.04 with the 64-bit version. i have a problem when i tried to install "LINE" using wine. in the article i have read, it says that i have to download a package file, so i download ...
0
votes
1answer
46 views

How to execute the tar file without any error? [on hold]

tar (child): ushare-11a-netou.tar.bz2: Cannot open: No such file or directory tar (child): Error is not recoverable: exiting now tar: Child returned status 2 tar: Error is not recoverable: exiting now ...
3
votes
1answer
50 views

Keyboards writes “bad” space characters in gnome terminal

It looks like at random times my keyboard inserts a character that is displayed as a space character but isn't one, preventing the shell from interpreting it correctly. For example before "sort" below ...
1
vote
1answer
17 views

Execution error with .so file

When running a server and trying to connect to a web socket I have an execution error: ./cameraserver: symbol lookup error: ...
1
vote
0answers
32 views

Accessing root files on Ubuntu Phone from my eOS based on Ubuntu. [duplicate]

I'm wondering if its possible to access the root files on my Ubuntu Phone E5 from my computer. I know I can access them from the terminal on the phone but its not ideal using that touchscreen to ...
4
votes
1answer
39 views

Recursive directory renaming

I need to recursively append the same suffix to all sub-directory names in a directory. What is a simple and safe way to do this?
0
votes
0answers
34 views

Script for Opening Two Terminals and Execute Three Consecutive Commands [duplicate]

I intent to open two terminals and execute three consecutive commands in bash script. Basically, the first terminal will execute first command, second terminal will execute second command, and back ...
0
votes
1answer
5k views

when building u-boot /bin/bash: arm-none-linux-gnueabi-gcc: command not found

I am currently running Ubuntu 12.0.4 on a 64 bit machine. I have an AM335X development board. Along with the kit came the compressed kernel (linux 3,2), rootfs, u-boot, and ARM cross compiler ...
11
votes
2answers
443 views

Non-sudo alternative to /usr/local/bin for common scripts

I'm used to putting common scripts in /usr/local/bin so that I can execute them from anywhere with the terminal. For example, I make a shell script named 1, make it executable with chmod +x 1 and put ...
0
votes
1answer
3k views

What actually yum does? [closed]

I've seen yum used as a command for Cento OS Red Hat Linux platform. But, I tried with sudo too and it works. I want to know then what yum actually does. I am just curious to know.
2
votes
1answer
33 views

How can I be sure “apt-get install” successfully finished its work?

I have Ubuntu 14.04 and I intend to download Skyrim. So I put the command into the terminal sudo apt-get install playonlinux. Everything was loading fine and it seemed to be working, however before ...
1
vote
2answers
26 views

Missing argument to -exec

This is the command I'm entering. find /home/things/backups -mtime +0 -exec echo "{}" >> /home/things/logs/backup.log \; -exec echo "Hourly rotate successful: $(date). {} was deleted." ...
-2
votes
0answers
30 views

what is aptd, apt, apt-get and what are 2758,2936 and 3673 as shown below [on hold]

2758 ? 00:00:05 aptd 2936 ? 00:00:00 apt 3673 ? 00:00:00 apt-get This is what is being shown when i type ps -e | grep -e apt -e adept | grep -v grep I am very new to ...
0
votes
0answers
34 views

What is wrong with my code so far? [on hold]

I'm attempting to make a DNA translation script in bash that will take an input file, iterate through the file, and convert every three characters into the proper protein code it corresponds to. Thus ...