what does "~/." mean in terms of OS X folders/directories?

31,386

Solution 1

The tilde symbol (~) in OS X command-line terminology refers to your home directory, e.g /Users/Joe.

As JonathanMueller pointed out, anything with a dot (.) in front, is considered hidden. Thus, what your program needs you to do is to:

  1. Fire up Terminal
  2. cd ~ (goes to your home directory)
  3. mkdir .spring (creates a hidden spring directory)

You will not be able to see this folder in Finder, as it is hidden, but going to Terminal and using ls -a while in Terminal will show up the hidden folders.

Solution 2

~ is a reference to the home directory. A dot directory is a "hidden" directory in UNIX.

Share:
31,386

Related videos on Youtube

ganesh
Author by

ganesh

Updated on September 17, 2022

Comments

  • ganesh
    ganesh over 1 year

    I'm installing a program on my MacBook that has to be unzipped to the ~/.spring directory; now, I know what Spring is, it's the name of the thing I'm installing. I'd be very happy to create a .spring folder if I knew what ~/. meant.

    • Admin
      Admin almost 14 years
      Note: ~/. by itself means something different than when it is a prefix of something longer. On its own, it is a longer way of writing ~, both of which indicate the home directory. As a prefix (e.g ~/.spring) it indicates a “hidden” entry in the home directory.
  • caliban
    caliban almost 14 years
    anything with a dot append in front is hidden in Unix, but in this case, a singular dot refers to the current directory, which is Home.
  • coneslayer
    coneslayer almost 14 years
    @caliban You sure about that? If the dot in ~/.spring refers to the current directory, OS X strayed a lot farther from its Unix origins than I had imagined.
  • JonathanMueller
    JonathanMueller almost 14 years
    @caliban, a single dot refers to the current directory and two dots refer to the parent directory, but this question was about .spring, which would be a hidden directory. Thanks for pointing out the possible confusion.
  • HikeMike
    HikeMike about 11 years
    Or -A to not display the . and .. entries.
  • Georgi Peev
    Georgi Peev almost 4 years
    Why sometimes this is going to /root?