[ANN] Wuby - Ruby for MS Windows!

D

Daniel Berger

Hi all,

I'm happy to announce the first beta release of Wuby (pronounced
"woo-bee"). This is a Windows-only fork of Ruby. And yes, the name is
meant to be slightly comical. :)

What's the difference between Ruby and Wuby?

First, much of the underlying code base has been replaced with native
Windows C API functions. Many of the Unix-isms currently part of Ruby
have been removed, such as File.sticky?, since they don't make sense on
MS Windows. Instead, in order to mimic the Windows API more closely, the
API has been changed to match it.

For example, I have added a File.attributes method that lists the
attributes associated with the file, such as 'hidden' or 'archive'. The
File::Stat class has been modified to return attribute information.
There's also a File::Security class for dealing with Windows ACL style
of file security.

Second, some of the existing methods that don't work on Windows have
been updated or fixed. For example, the File.chardev? class method now
works properly. UNC path handling is now done properly.

Third, Unicode support! Thanks to the magic of MultiByteToWideString(),
you can now pass an encoding as an optional second argument to
String.new, e.g. str = String.new("Ελλάσ", String::UTF8). There have
been some changes in the String API as a result. For example, the
String#size returns the size in bytes (10), while String#length returns
the length in chars (5). The encoding will default to your system's
encoding, so you won't have to use the longhand notation if you don't
want to.

The regular expression engine has been altered to work with the new
string modifications as well, so you can do "if str =~ /λ/u" and it will
Just Work.

Fourth, I've updated a bunch of the core methods to work with Windows
Vista where possible. For example, Vista now supports symlinks, so the
File.symlink and File.symlink? methods now work.

Fifth, there was a major overhaul in the socket code. Most of this will
be invisible to you, however. The most significant change is that
select() no longer blocks!

Sixth, the interpreter is now thread safe! That means it has native
thread support. This is in addition to Ruby's green threads, so you
still have those, too. Thus, there's now Thread.new (green) and
NThread.new (native). The NThread API is somewhat different than Ruby's
Thread API in order to more closely match the Windows API thread functions.

Seventh, and this one is pretty significant, is that I've completely
reorganized the standard library. Some packages I felt just weren't
worthy of being included in the standard library, some are broken IMO
and some are too specialized and/or were Unix specific. Thus, the
following libraries have been removed:

* Abbrev
* CSV
* Curses
* DBM
* DL
* Etc
* Expect
* Ftools
* GDBM
* GetoptLong
* Jcode
* NKF
* Pty
* SDBM
* Syslog

The following libraries have been modified and/or tailored for MS Windows:

* Fcntl
* FileUtils
* Find
* Forwardable
* Net::HTTP
* Open3
* Pathname
* Win32API
* Win32OLE

The following libraries have been added:

* FasterCSV (renamed to just "CSV")
* Getopt
* KirbyBase

Lastly, there were some fixes made for 64 bit Windows.

I'm sorry I've had to keep this under wraps for so long. After RubyConf
2006 I connected with Ani Babaian (remember Ani?) and we talked about
how Ruby fit into Microsoft's future. It was decided that, while John
Lam's CLR work would be the better long term solution, an interim
solution would be best in the short term. Besides, John could then base
his interface on Wuby instead of Ruby, so it would be a smooth transition.

So, with that decision made I began to work, part time and with some
funding from Microsoft, on Wuby in my spare time. There were also a
couple of programmers from Microsoft who were invaluable, especially
Dave Lee, who wrote most of the revamped code for socket.c, and Raymond
Chen himself was largely responsible for making the interpreter thread safe.

Licensing is undoubtedly on your mind. Not to worry! Wuby is licensed
under the same terms as Ruby itself. MS had no desire to try to make
this closed source (I would have refused if they had). MS wants to play
nice with the open source community, and figures it can make its money
back on support contracts (which it will eventually offer) and third
party tools, such as IDE's, etc.

Well, that's it for now. If you're an MS Windows user, or just curious
about Wuby in general, you can find more information at the following
links (temporary links until the real web pages are setup soon):

Wuby home page: http://tinyurl.com/ywm85w
Wuby spec: http://tinyurl.com/jmw44

Enjoy!

Dan
 
J

Joel VanderWerf

Daniel said:
Hi all,

I'm happy to announce the first beta release of Wuby (pronounced
"woo-bee"). This is a Windows-only fork of Ruby. And yes, the name is
meant to be slightly comical. :)

Welease Wuby!
 
M

M. Edward (Ed) Borasky

Daniel said:
I'm sorry I've had to keep this under wraps for so long. After
RubyConf 2006 I connected with Ani Babaian (remember Ani?) and we
talked about how Ruby fit into Microsoft's future.
How is Ani, anyhow? We haven't heard much from her since RubyConf -- er
-- WubyConf.
 
M

M. Edward (Ed) Borasky

Joel said:
Welease Wuby!
There's no such project as Wuby -- it's all Microsoft FUDD!

Ed ("I'm having wabbit for Easter dinner") Borasky
 
R

Ryan Leavengood

I'm happy to announce the first beta release of Wuby (pronounced
"woo-bee"). This is a Windows-only fork of Ruby. And yes, the name is
meant to be slightly comical. :)

LOL. You know this might actually be pretty cool!

I was sort of hoping this was one of those clever "looks like an April
Fool's joke but it really isn't" jokes.

Remember that Parrot started as an April Fool's joke. :)

Of course I'm personally working on leaving the Windows world behind
as soon as I can, so maybe it doesn't matter.

Ryan
 
D

Daniel Berger

LOL. You know this might actually be pretty cool!

I was sort of hoping this was one of those clever "looks like an April
Fool's joke but it really isn't" jokes.

cvs -d :pserver:[email protected]:/var/cvs/shards login
cvs -d :pserver:[email protected]:/var/cvs/shards checkout wuby

Probably not even 5% of what I discussed is actually done, but there
you go. :)

Dan
 
S

Sasa Ebach

Dan,

this would be just fantastic news, if it were true ;) I must confess,
coming from you and if I hadn't read the replies before doing so myself, I
would have almost fallen for it.

But, just like the German computer magazine c't does a April fool's joke
every year. Often they do become (somewhat) reality in the next couple of
year. So the question is: What you are supposing sounds really great. Would
this be useful to Windows devs?

Also, what about calling it WRuby. More ompf.

-se
 
R

Rick DeNatale

Hi all,

I'm happy to announce the first beta release of Wuby (pronounced
"woo-bee"). This is a Windows-only fork of Ruby. And yes, the name is
meant to be slightly comical. :)

What's the difference between Ruby and Wuby?

And what are the differences between Wuby and R#?
 
R

Robert Dober

And what are the differences between Wuby and R#?
That is a great pun Rick and I guess I can only copy about the potential danger.
Did we all forget what *almost* has happened to Java?

Cheers
Robert
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,982
Messages
2,570,186
Members
46,739
Latest member
Clint8040

Latest Threads

Top