This is not correct. If no content has been written, you should still create the file because the user might want to create a custom file using a command like touch
.
Use os.MkdirAll
here instead so that it creates parent directories, and handle the error (just return it).
Sorry it's taken me a while to respond. I wanted to test this PR but my PineTime wasn't booting. Now that I've gotten it to boot, I'll test this and get back to you.
The err
can be several different kinds of errors, and FSError
is just one of them. It's actually a type I made. You can see it here: https://gitea.arsenm.dev/Arsen6331/infinitime/src/commit/512…
These should be debug logs rather than info logs. Also, the message should be a bit more specific, something like "FUSE getattr". Same for all the similar logs.
This error needs to be handled, you can just return it in this case and update the code that calls this function to do the actual handling
These variables should go above BuildRootNode
because it's using them and it would be more readable that way. Also, Go doesn't require semicolons, you can remove those.
This function should be called startFUSE
instead to adhere to Go naming conventions
Thanks for your PR. There are some changes I'd like, mostly readability improvements.
I've had a closer look at your fork. It looks good. The only thing I'd say should be changed is that the fuse.go
file should only contain the startFuse
function (which should be called…
Assuming the fuse library you're using doesn't link libfuse
, I think this is a great idea. I don't think it does, but it doesn't explicitly state that anywhere. The easiest way to check is to…