Dokan Ruby 0.1.4 released
Now I released Dokan Ruby 0.1.4.
Dokan Ruby is a Ruby extension library to write a file system for Windows. This extension also has compatible API with FuseFS (Ruby extension for FUSE). You can write a file system only in 25 lines.
require 'dokanfs'
class Hello
def initialize
@msg = "hello, world"
end
def contents path
["hello.txt"]
end
def file? path
path =~ /hello.txt/
end
def directory? path
path == "/"
end
def read_file path
@msg
end
def size path
@msg.length
end
end
FuseFS.set_root(Hello.new)
FuseFS.mount_under("r")
FuseFS.run
Is your version of FuseFS compatible with the one working with FUSE?
Meaning - if there is a file system implemented in ruby over FuseFS how hard it will be to port it over to your Dokan Ruby bindings?
> Is your version of FuseFS compatible with the one working with FUSE?
DokanFS has the same API with FuseFS so your program should work both on Dokan and Fuse.
Windows Explorer always accesses non-exsinting files and reads directorys recurcively. You should consider explorer’s bad behaviors.
Hi Hiroki -
Would you allow me to include your Dokan Ruby code in the FuseFS distribution? (With full crediting, of course.) I’d like to release a version that works on all four major platforms (BSD, OS X, Linux, Windows). With Dokan, it’d basically be a copy of most of your lower level code, and higher level (editors, etc) handling hooking into either Dokan or FUSE, as appropriate.
Please let me know.
Thanks!
- Greg
Hello, Greg
Since Dokan Ruby is released under MIT license, you can freely use it. However Dokan library itself does not allow to redistribute now. In the early feature, I think it will be next week hopefully, I’ll change the license of Dokan library. Please recheck then.
Thanks
Hi Hiroki -
Thanks!
Also - I’ve just read your comment on the Dokan Library 0.2.6 release - Do you have any timeline on how long until you get the FUSE compatible API out? If it’s not too long, I can just use that?
Wow, this is really great. After having searched for a windows fuse version for quite a while this Dokan lib with ruby bindings is godlike!