All Questions
71
questions
3
votes
1
answer
4k
views
Adding more than one image as album art to mp3 via command line
I want to add two images (front and back cover) to my converted mp3s. At this time I convert all my WAVs with lame, then I convert the ID3 tag version from 2.3 to 2.4 via eyeD3 and then I will add two ...
2
votes
1
answer
4k
views
mac how to run a command in a different tab/window of a terminal
In Windows, I can run any program from the command prompt by typing
c:> start startup.sh
and windows will run the startup.sh in a different command prompt(terminal) window.
How can I do the same ...
28
votes
7
answers
111k
views
What is the terminal command other than ctrl + c to exit a running Node.js program in a macOS?
In Linux terminal if I run a command like:
$ node httserver.js
The command runs and by doing ctrl + c the program is terminated and new line comes in terminal for us to enter a command.
I felt ctrl ...
0
votes
1
answer
2k
views
Direct errors in find to /dev/null by default
On my OSX command line, find directs errors to STDOUT. I find this very inconvenient, and I also find it annoying to add 2>/dev/null to the end of the command every time. This brings up several ...
1
vote
1
answer
345
views
Unclear on making sense of all the command-line-interfaces (CLI)s out there, and when/why to use them
Some background, I am making the mental effort to start using command line interface for all my work, on Windows, Mac OSX, and LINUX systems. It is true that we have a lot more flexibility in the ...
0
votes
1
answer
428
views
Set ENV variable for all commands in current directory in mac os
Is there a way to run all commands in current directory with some ENV variables predefined?
Example of what I need:
I put some file, say .env in my directory, with:
export SECRET='abcd123'
Then I ...
0
votes
1
answer
38
views
Is there a way to determine the IP address from which a uri was served from a mac/linux box?
I have a few servers behind a load balancer and I want to know which one is servicing a particular request.
$ ping website.com only tells me the ip address of the load balancer. Is there a way I can ...
0
votes
0
answers
88
views
list all the information of a process under commandline in osx or linux
Is there any command to list all the information associated with a process, include all parameters in PS command, open files and ports and so on?
Thanks!
7
votes
1
answer
2k
views
OS X terminal - put flags/options at end of command?
Is there a way on OS X to put flags at the end of a command instead of at the beginning? On my Ubuntu box, either of these will work, but OS X treats -la as a directory argument in the second example:
...
59
votes
3
answers
141k
views
What is the equivalent of the Linux command "sudo fdisk -l" in MacOS?
In Linux, the command sudo fdisk -l produces an output that lists all the disks and partitions in the computer. Here is an example:
If I try to use sudo fdisk -l in MacOS X 10.7.5, the output is the ...
3
votes
0
answers
1k
views
Gnome 3 copy/paste with a Mac keyboard
I want to use a Mac keyboard in Linux with Gnome 3. What I essentially want is to have Cmd/Ctrl keys behave like in Mac: do all copy/cut/paste, window switch and etc. using Cmd key but in Terminal ...
1
vote
1
answer
3k
views
Map `php` at the command line to point to `/usr/bin/php`?
For some reason using php at the command line references /usr/local/bin/php instead of /usr/bin/php. How can I make $ php script.php the equivalent of running $ /usr/bin/php script.php?
Current ...
1
vote
3
answers
4k
views
Rename recursively files, while keeping the extension
I have a bunch of directories that each hold one *.txt file in it (and other non *.txt files).
I'd like to rename those files recursively from the command line, basically *.txt to info.txt.
So all *....
8
votes
6
answers
3k
views
In Bash (Mac/Linux terminal shell), can the up and down arrow keys be made to function as they do in text editors?
In text editors, if I press the up and down arrow keys, it moves the cursor between lines of text.
In Bash, if I’m typing a long command that spans multiple lines and I press the up and down arrow ...
4
votes
1
answer
4k
views
OSX / Unix: move odd or even numbered files
I have a folder with a range of numbered files (camera images) and I'd like to move every other image into a different folder, so either all the odd numbered images, or all the even ones. How can I do ...