arthurintelligence/node-fs-filesystem

macOS: High Sierra reports Volume Free Space (not Volume Available Space)

jacargentina opened this issue · 4 comments

@philippefutureboy

I need the features this module provides, I've already sent a PR; I need to know if there are intention to keep this module going on, etc.

Beside the PR #7 I've also found that tests fail on my macOS High Sierra, because of parsing of diskutil output (it is Volumen Free Space now, when it was Volume Available Spacebefore)

Hi!

Thanks for tagging me, I wasn't receiving the notification on the repository. Sorry for the delay!

Yes, this module is actively maintained! :) I am very busy at the moment, but will do my best to help you and support this module.

Regarding the diskutil parsing, I can confirm, I get a test that fails.

screen shot 2018-05-06 at 10 26 43 am

So in terms of how to solve this problem, I see two ways:

a. If the older version of diskutil does not have the 'Volume Free Space' key, then we can simply do an OR clause on the key, and it should solve the problem.
b. If not, we would have to find a way to determine which version of diskutil is installed, and return the proper key accordingly.

While I do not have a Mac with MacOSX < 10.13.x, I see that we can run the tests on Travis CI on both the older and newer version by adding an extra OSX Version in the OS matrix (https://docs.travis-ci.com/user/reference/osx/#OS-X-Version).

I'd be happy to introduce you as a contributor to the repository.

Let me know what you think!

Have a wonderful day ☀️

Cheers,

Philippe

Philippe, thank you a lot for your response! I would like to follow your a) suggestion, the problem for my on the code is the use of the lambda thing, functional everywhere, etc...

I would love to be able to add things like #4 for example, but can't yet understand what would be the correct place to do that.

Again, thanks a lot! Same for you 👌

Haha yes, I understand the reluctance to dive in a FP program. This was my attempt at learning FP, and since then I've dialed down its use to something more obvious.

If that can help you to contribute in the future (for example #4), I can refactor some of the FP out of the codebase.

Yes Philip, that would help me a lot to go fast on the changes. Thanks!