The command-line is the interactive interface to your shell.

learn more… | top users | synonyms (1)

2
votes
2answers
80 views

Parsing of command line options

For I school project, I have to implement a shell/terminal app. But I am wondering how are command line options parsed, because it appears abit weird to be. For example for the command paste (and I ...
1
vote
1answer
162 views

How to format a CF card by a terminal command?

I want to know the command for formatting a compact flash card from the terminal.
4
votes
2answers
207 views

Dump process's stdin and stdout

I have two processes, let's say Parent and Child. Parent launches the Child and communicates with it through child's stdin and stdout. Parent <-> Child These processes use text protocol and I ...
1
vote
1answer
179 views

How to alter stored procedure in a MySQL database using the Linux command prompt?

I want to alter the stored procedure in my server machine. I'm uploading the codes via SSH Linux command prompt, I need to alter an existing stored procedure in my server. I don't have c-panel or ...
2
votes
2answers
2k views

Example xfreerdp usage with clipboard plugin

FreeRDP 1.0.2 has an updated their parameter syntax for "better interoperability with Windows." I had a problem using the old syntax where the clipboard plugin only worked the first time I pasted, ...
2
votes
2answers
132 views

rsync on a very large directory

I'm trying to rsync a partial clone of mavencentral using rsync. The problem is, due to ridiculous network policies, I can only have the copy running during business hours. The process will be cut ...
3
votes
7answers
450 views

Batch renaming of files [duplicate]

I have a directory full of images: DSCN4749.JPG DSCN4750.JPG DSCN4892.JPG ... And I would like a one-liner to rename them to (say). dscn4749.jpg dscn4750.jpg dscn4892.jpg ... How do I do this? ...
1
vote
0answers
29 views

Multi-file simultaneous downloader with live statistics for all files

(I recently asked the question "Console download accelerator that downloads *multiple* files simultaneously" and learned about lftp, an excellent program which can download multiple files ...
2
votes
2answers
161 views

Create an ASCII art table from tabular data

Given perhaps comma- or tab-delimited input, I'd like to present a series of appropriately padded columns to stdout, so I can easily scan columnar information which would otherwise present rather ...
0
votes
0answers
227 views

change the panel font color of the numix theme

So I loved numix and I installed it in lubuntu 13.10 and now, when I apply it, it does into show the name of the minimized app. it does not even have option to edit.
1
vote
1answer
132 views

Tips for debugging WiFi on the command line?

I am running Ubuntu 13.10 on a Thnkpad X1 Carbon. My Wifi card is Centrino Advanced-N 6205 [Taylor Peak] I normally connect to open WiFi networks using the commands sudo iw dev wlan0 connect ...
0
votes
1answer
195 views

Uniq won't remove duplicate

I was using the following command curl -silent http://api.openstreetmap.org/api/0.6/relation/2919627 http://api.openstreetmap.org/api/0.6/relation/2919628 | grep node | awk '{print $3}' | uniq ...
0
votes
3answers
54 views

Get contact information of system administrator from the terminal

Do any of the common Unix/Linux platforms provide a way to query the system administrator contact information from the command line. Obviously a system admin might not include this information when ...
1
vote
2answers
68 views

Why the duplications in the command line output

Entering the following command prints duplicates as shown below. Not all lines print twice but some do. What gives? XXXX:~ XXXX$ man -k pid pid(ntcl) - Retrieve process identifiers ...
2
votes
3answers
56 views

How to get a list of applications associated with a file using command line

File associations usually are made in the desktop environment, but how to get a list of applications associated with a file using command line? Something like: $ getassoc foo.pdf <CR> $ ...
1
vote
1answer
203 views

configure gsm connection using nmcli

I have a system without X display and I want to use nmcli to configure my cell modem to connect to a certain apn. I can get it going with this modem just fine on Ubuntu (with X) and I would like to ...
2
votes
4answers
150 views

Incrementing a variable each time the system boots up

The idea is to initialize a variable and set it to 0. Then create a script that executes on boot and increments that variable by 1 each time the system boots up again. Sounds simple enough right?
5
votes
1answer
163 views

How to access the Evolution calendar data from the command line?

I want to be able to access the Evolution calendar from the command line. Specifically, I'd like to be able to: List calendar events (the one-line summary, date and time is enough) Upcoming events ...
2
votes
1answer
85 views

Getting the value of the clipboard

Is there a command to output the current value of the clipboard? Example (this command doesn't exists, it's just an example of what I'm looking for: cat clipboard > Hello world! Also, if the ...
0
votes
2answers
266 views

How can I concatenate all files in a directory together in one command line operation? [duplicate]

I have 1000 csv files in a directory. I would like to concatenate them all together in order. They are named img_size_1.csv to approx img_size_1000.csv This answer is close but assumes a list file. ...
3
votes
2answers
86 views

Repeated commands in a bash pipeline

Sometimes commands repeat in pipeline command. For example (just to illustrate): $ grep -lF 'pattern' ./foo/**/*.bar | xargs dirname | xargs dirname Is there a way to shorten chaining command? For ...
1
vote
1answer
99 views

Is there a graphical shell or scripting environment for Linux?

I would like to draw my scripts and connect commands like blocks of functions (something similar to Yahoo Pipes). Does such an environment exist or do I have to develop it myself?
3
votes
3answers
1k views

Copy files without encryption (ssh) in local network

scp works well in all cases, but the Raspberry Pi is to weak to copy files efficiently in a secure environment (lan). The theoretically possible 6,75 MB/s via 54 Mbit wireless lan shrink down to about ...
19
votes
2answers
607 views

Is there a reason why ls does not have a --zero or -0 option

This question was prompted by questions about ls' -1 option and the recurring tendency of people to ask question and answers that includes processing the output of ls. This reuse of the output ls ...
0
votes
1answer
175 views

Bring up shutdown menu of Cinnamon via command line

How can I bring up the shutdown menu of Cinnamon via command line? Note: I don't want the user menu. This menu for switching or logging out a user is brought up via Ctrl+Alt+Del.
3
votes
2answers
1k views

Get list of subdirectories which contain a file matching a string

How can I get a list of the subdirectories which contain a file matching a particular string? More specifically, I am looking for directories which contain a file with the letter 'f' somewhere ...
0
votes
3answers
422 views

Awk/grep/sed get comma separated list of numbers from lines of text

I have a log file that has lines that look like this: blah blah blah Photo for (702049679 - blah blah blah Now I know I could get all the lines like that from the file by doing: grep "Photo for" ...
2
votes
1answer
168 views

Byobu - send command to byobu tmux session from commandline (or bash/sh)

I run a script which I would like to print the status to a byobu tmux session. So for example print backup finished \n. Is it possible to do this with the name of the byobu tmux window, which you can ...
2
votes
3answers
38 views

setting up script in a linux machine for scientific computation [closed]

I'd like to setup machine for test some computation in my old laptop, before replicate the tests on the server. The computation will be image-processing and machine learning, run some program, load ...
0
votes
1answer
80 views

What is the different bash per terminal session for Konsole?

I am using Konsole in Kubuntu. I was wondering what is the difference between a profile in Konsole and the profiles in our bash? I am reading that we can create different profiles per Konsole session ...
2
votes
1answer
135 views

cat file to multicast

I have a text file (test.txt) which represents captured network data. The actual protocol is text-based, with NULL line endings, so this isn't a problem. I need to run this test captured data ...
2
votes
2answers
158 views

How do I share stdout between multiple processes?

I want to receive live TCP stream, and make it readable by another processes at the same time, without saving it. For example, 111.222.233.244:1234 streams actual time. Server supports only one ...
0
votes
2answers
111 views

Simplest wget example Scientific Linux

I'm on Sci Linux and know nothing about commands. How can I use the wget command? Can someone provide a simple example where it actually downloads something? How do you specify where the download ...
1
vote
2answers
171 views

Using notify-send with a non-interactive ssh connection

I want to be able to use notify-send to send popup messages from one server to be displayed on another. I'm sure this is possible with SSH, but how can I automate it to a one-line command that ...
1
vote
3answers
105 views

Convert a date format

I have one problem with my date format. I want to change from one format to the other and vice verse. My date formats are: Format1 : 1/24/2014 Format2 : Jan 24 How can I do this?
6
votes
5answers
816 views

How does one find out how many bits a file has in one command?

I know I can use ls -lat to find out how many bytes has a file and then multiply by 8 to find out how many bits. But is this possible in only one command line?
3
votes
2answers
117 views

Edit tree to output in custom format?

I'd like to get a custom output from the tree command, but unlike this question, I don't have a fixed format. I'd like to be able to give the command the format in an argument (for instance perhaps ...
2
votes
3answers
68 views

Sed - string substitution with groupings

I have a largish directory with filenames formatted like Some_Folder-(FOL001)-clean what I'm trying to do is display the pattern between the brackets at the start like FOL001 ...
0
votes
2answers
105 views

Where are netstat's -t and -u flags documented?

I use the following command to find open ports on my servers: $ netstat -ntulp I've probably found that on some random website over the years. However, I cannot find where -t or -u are documented. ...
0
votes
2answers
122 views

How do I prepare Windows NTFS drives on Linux

I'm upgrading my windows desktop hardware and doing a clean OS install. I'm using SystemRescueCD to prepare my old drives for the upgrade. Long story short, a bit of an emergency, I coudln't do this ...
0
votes
1answer
65 views

Why date +3 equals 3?

Yes, this is a minor issue, but I wonder why date +3 outputs 3 Other options like: date -3 raise an error.
0
votes
0answers
21 views

how to invoke fonts dir in ghostscript

I am trying to create a PDF out of a text file with Courier as font and trying to use gswin32c.exe on Windows, but unnable to pass parameters correctly, I think. The gswin32c.exe is the Windows exe of ...
1
vote
1answer
923 views

can't wget rpm oracle on centos linux

Forgotten how I did this last time. Tried the following 2 methods that I thought had worked for me in the past: method #1 $ wget \ ...
4
votes
2answers
313 views

What does `du - hb` do?

With du -bh I think I get the apparent size in human readable format: # du -bh 295K ./test However, I would expect the same from du -hb, but I get something else: # du -hb 301926 ./test I ...
1
vote
1answer
71 views

Why doesn't setuid on /sbin/dhclient work as intended?

I am the only user on my machine, and prefer not to type sudo every time I use dhclient. Therefore, I tried sudo chmod u+s /sbin/dhclient. However, when I subsequently run dhclient wlan0 from a ...
-1
votes
4answers
93 views

Need a command sequence that will move files from one directory to another based on a particular year? [duplicate]

I'm looking for a sequence of commands (one liner would be ideal) which will identify all the files created in particular year, and move the resulting files to another directory.
3
votes
1answer
105 views

Expanding comma-separated list into separate lines

I have a file with some data in this form: Prefix text: First Name, Second Name, Third-- The prefix differs by line. The number of names varies from one to several. The suffix (-- in the example) ...
2
votes
2answers
69 views

Copying recursively files with spaces

At the moment I have a set of files of the form of: /dir one/a picture.jpg /dir two/some picture.jpg What I want to do is copy and change the end to -fanart.jpg to the filename to: /dir one/a ...
1
vote
4answers
202 views

How to start line with command from output of another command

Sometimes the output of some command include other commands. And I'd like to start that command from output without using a mouse. For example, when command is not installed there is a message with ...
2
votes
3answers
54 views

How to start first command from the list printed by command 'history | grep something'

For example, I have the following output from command: loom@loom:$ history | grep MAKE 219 ../build.sh -DCMAKE_BUILD_TYPE=Debug .. 909 history | grep MAKE How to write a command, that start ...