After a break of several months, I rebuild Rakudo on the server, a few days ago, and regenerated the Perl 6 Maven pages. This promptly broke the site. The fix was easy, and as expected the bug was mine.
Today I decided to try Rakudo on my Windows machine as well, but I went for the easy route and installed the pre-built msi file.
You can download the latest version of Rakudo * from their site. At the time of this writing the latest source code version of Rakudo * was 2013.02, but only the previous release had pre-compiled version, so I installed the MSI file of the 2013.01 version. (These are monthly releases.)
If you do the same, a few things you should know:
You can install by clicking on a few buttons, but as I recall it did not say it has finished. It just did.
It will install into c:\rakudo. Currently you don't have a choice.
It will add a menu item called Rakudo Perl 6. Clicking on the item will run Perl 6 and you'll find yourself inside the Perl 6 REPL. You can go ahead and type "hello".say just to make sure you are in the right place. Then you can go ahead and start playing with Perl 6 inside the REPL. You can close the REPL by typing exit.
If you write a Perl 6 program, for example creating the hello.pl file, open a command window (Start/Run/cmd) but unfortunately the installation did not put the perl6.exe in the PATH. You can configure the PATH environment variable in the Control Panel. This will take effect for all the cmd windows you launched after the setting. So you probably need to exit from all the cmd windows and open a new one.
You can also configure it for the specific cmd window you opened by typing:
After doing it manually, perl6 -v worked from the command line.
Typing perl6 will get you in the same REPL mentioned earlier.
You can run your scripts typing perl6 hello.pl
Even after configuring PATH environment variable, you still cannot use the p6doc command. If you create a file called c:\rakudo\bin\p6doc.bat with the following content:
@%~dp0perl6.exe %~dp0p6doc %*
you will be able to type p6doc Str.
After a bit of searching I found that the c:\rakudo\lib\parrot\4.10.0\languages\perl6\lib is the location where the Perl 6 modules coming with Rakudo * are installed. I have not found any easy way to list them. Well, except of running dir.
You can type p6doc URI to read the documentation of the URI module. (It had some Unicode issues on my computer.)
Just as with p6doc, you cannot use panda out-of-the-box either. You need to create a file called c:\rakudo\bin\panda.bat with the following content:
@%~dp0perl6.exe %~dp0panda %*
Then you can use panda to install additional modules.
On the first use panda will fetch the list of modules available for Perl 6 and will put it in c:\rakudo\lib\parrot\4.10.0\languages\perl6\site\panda\projects.json You can see the list by typing panda list.
If you'd like to use HTML::Template you can install it by typing panda install --notests HTML::Template.
We need to skip testing for now, as panda has a bug that requires the presence of the prove commnad from Perl 5, and even if it is there, panda will blow up in a nasty way if one of the tests fail. Unfortunately the tests of HTML::Template currently fail.
An explanation for the bat file, in case you are wondering:
So there were a few issues that need to be fixed, but in general the experience was not bad. (For example the bat files will be already included in the next release of Rakudo * and I think panda has been fixed since then.)
Once you have done this, you can start writing Perl 6 code.