Understanding directories

4 respostas [Última entrada]
Lola
Desconectado
Joined: 10/10/2015

Hi all,

Topic
https://trisquel.info/en/forum/set-tor-default-browser#comment-82155
was solved by 3n3r6yD using the directory $HOME/bin.

I do not have that directory, why?

I tried to follow the solution using the bin directories I have, but it did not work. One is /bin and the other one is /usr/bin.

Then I also tried by creating /home/bin, I also tried by creating home/lola/bin, but they both failed at step 4 of the mentioned topic.

Why don't I have that $HOME/bin directory?
How should I follow the mentioned topic?

Does anyone know why Nautilus calls my /home/lola directory "Home"?
I find it confusing. Despite the daughter has a different name, Nautilus uses the mother's name to call the daughter!

And the last one, why was the mentioned topic locked?

Thank you!

loldier
Desconectado
Joined: 02/17/2016

...why was the mentioned topic locked?

Threads that are idle get locked after a certain time. Guess it's to combat spam.

onpon4
Desconectado
Joined: 05/30/2012

> I do not have that directory, why?

Because "$HOME/bin" is not a normal directory to have. The user in that topic added it himself, and it has no special meaning. I guess he just found that to be a convenient place to put local scripts.

> Does anyone know why Nautilus calls my /home/lola directory "Home"?

Because /home/lola is your personal "home" directory, the one stored in the $HOME environment variable.

Magic Banana

I am a member!

I am a translator!

Desconectado
Joined: 07/24/2010

Some explanations:

When you type a word in a terminal, the shell (i.e., the command-line interpreter) searches for a program that bears this name and execute it. It searches in directories that are listed in a shell variable named PATH. On my system:
$ echo $PATH
/home/banana/Travail/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games

The first directory, "/home/banana/Travail/bin", is not standard. I created that directory and put there programs (usually small scripts) I write for my own needs. I added the directory to the PATH variable by writing this line in ~/.bashrc (which is executed whenever a shell starts):
PATH="$HOME/Travail/bin:$PATH"

Because "/home/banana/Travail/bin" is in the PATH variable, I only need to write the name of a program in it (not the path to it) to execute it. Auto-completion works too.

Lola
Desconectado
Joined: 10/10/2015

Wow! Nice explanations! Thank you.

Now I can go back to my Tor-as-default-browser mission.