0

I have a folder that contains no items, but du -hs ~/dev/random-assets says it has 3.7G.

Get info says "3.96GB" for 1 item.

I do have git initialized on this directory.

How do I clear out the directory so it accurately reflects the files inside of it?

enter image description here enter image description here

2 Answers 2

3
ls -al ~/dev/random-assets

will probably tell you that you still have a .git subdirectory. If you truly wish to delete it all,

cd ~/dev/random-assets
rm -Rf .git

If you would like to be able to see dotfiles in your Finder windows instead of having them hidden, issue

defaults write com.apple.finder AppleShowAllFiles TRUE
killall Finder
2
  • I showed hidden files, then noticed inside the .git folder it had an objects folder containing the 4gb. I deleted that. Will that cause any harm?
    – evan
    Sep 18, 2016 at 16:32
  • @evan, the .git folder (together with all its subfolders) contains your git repository. This does no harm if you are no longer interested in that repository. Sep 18, 2016 at 19:08
1

There must be some files or folders hidden in this folder and are beginning with a dot, so that's why they are hidden. If you remove the folder and recreate it you should be fine.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .