Linked Questions

35
votes
4answers
492k views

How to write the path of a folder with space in its name? [duplicate]

I can't figure out how to write the path of a folder that includes spaces in its name (in Terminal). I tried: cd /path/path/path/"A Folder"/file cd /path/path/path/'A Folder/file cd /path/path/...
34
votes
5answers
37k views

How can I convert audio from ogg to mp3?

I'm looking for a well working audio converter which is able to convert audio files (ogg) to mp3 formate. I tried it with the "sound converter" from software center but it stopped converting after 6 ...
30
votes
2answers
172k views

How do I navigate to folders with spaces in their names? I get “no such file or directory” when I try [duplicate]

I'm completely new and lost in Ubuntu 12.04, I'm having trouble navigating to my Sublime folder which I know is in my /opt folder. Yet I've tried to no avail to navigate into it via Terminal window. ...
21
votes
2answers
40k views

How can I protect parentheses passed to a cd command? [duplicate]

I asked here how to make cd protect spaces. Tab completion is great, but sometimes you paste the path from the clipboard so this is useful. The solution breaks with parentheses however. No matter how ...
19
votes
9answers
3k views

Open a doc from terminal, but not by its name

Is it possible to open a file from the terminal not by its name but by its (number) position in the folder? Or any other option? Because the name is too long.
14
votes
0answers
3k views

How do I enter a file or directory name containing spaces or special characters in the terminal? [duplicate]

I have a collection of files and directories with strange names, they contain spaces and the special characters \, *, ), ( and ?. All of them cause problems when I try to use them in the command line ...
12
votes
5answers
2k views

Using cd command to navigate directories in Ubuntu which have special characters [duplicate]

When I want to navigate into directories having special characters in their names I get an error message. For example: aman@desktop:~/Aman$ cd !)e$!gn&(reate bash: !: event not found aman@...
9
votes
2answers
761 views

using '&' in a directory name [duplicate]

i have a directory name with ISO&Emulator having some Important Files. and this directory is in different partition, and partition not showing in my FileManager(Nautilus). so i mount my partition ...
9
votes
2answers
55k views

How to access files/directories with spaces in the name? [duplicate]

Through terminal I can't access files or directories with a spaces in their names. The cd command says no such file or directory. Is there any way to do it or should I rename all files with spaces?
8
votes
4answers
3k views

Is there a way to create a script and make it executable in less code than this?

My code to create an executable script touch script.sh && echo "echo 'Hello World'" > script.sh && sudo chmod +x script.sh
6
votes
6answers
2k views

How to move files from subdirectories that have the same directory name to its relative upper/parent directory?

So, I have a directory structure like this: parent/ ├── sub1 │   └── source │   └── file1 │ └── file2 ├── sub2 │   └── sub2.1 │   └── source │   └── something1 │ └── ...
5
votes
2answers
361 views

Dealing with space in file links using bash [duplicate]

I got a problem. Here is my bash script to merge videos with subs: #!/bin/bash cd /media/ptrknvk/'TOSHIBA EXT'/Shows/My/'Doctor Who'/ url0='DW s11e0' url1='DW\ s11e' for(( i=1; i<11; i++ )) do ...
5
votes
2answers
451 views

How to rename (unhide) all files and subdirectories within a directory?

I want to make a script to "unhide" all files and directories inside a certain directory in one go, e.g. ./unhide test. test/ ├── sub1 │   └── .hiddenfile1 └── sub2 └── .hiddendir ├── ....
3
votes
1answer
85 views

Trying to create a folder with date and time with a space

I am trying to create the folder using: mkdir $(date +%Y-%m-%d %H%M) So you see a space between the two and I know this is not best practice but I would like to get it to work. I have tried to ...
3
votes
3answers
640 views

Replace String “Development” with “Staging” or “Production” using SED

I am trying to replace the string : 'development' with : 'production' using sed. I tried a few options including: sed -i "s|: \'development\'|: \'staging\'|g" index.php but without any luck. ...

15 30 50 per page