Skip to main content
areohbee
Legend
November 25, 2013
Answered

Free Disk Space - how to tell how much there is.

  • November 25, 2013
  • 2 replies
  • 1651 views

I'm guessing it would be by way of an external app, but does anybody have any specific ideas?

Windows? Mac?

This topic has been closed for replies.
Correct answer johnrellis

Duh, I forgot about this:

2 replies

DawMatt
Inspiring
November 27, 2013

Hi,

I see John has already answered the question.

A couple of things to remember, depending upon your use case:

  • if you do try to use df file , you probably want to use df -k file to get the size in kb rather than blocks
  • if you are trying to get the size of a removable volume under OS/X, you need to test the particular volume has been mounted first otherwise LrFileUtils.volumeAttributes() will return the volume size for the root directory rather than for the specific volume. I've been caught out by that before. I normally use LrFileUtils.exists() to test an expected file is present before testing the volume attributes.

Matt

areohbee
areohbeeAuthor
Legend
November 27, 2013

Thanks Matt .

~R.

johnrellis
Legend
November 25, 2013

On Windows:

On Mac:

johnrellis
Legend
November 25, 2013

Re "df", you can do:

df file

to see the information about the filesystem containing file. E.g.

johnrellis
johnrellisCorrect answer
Legend
November 25, 2013

Duh, I forgot about this: