Pluvo

Pluvo is a nascent experimental scripting language with an easy to use syntax, built in test facilities, and modern datatypes. High level and data structured, it makes things easier for the programmer by incorporating idioms from a wide range of languages in a consistent manner.

What's Inside?

Pluvo is a functional and imperative programming language intended to be highly practical for scripting and CGIs, interpreted using a just-in-time compiler. Its hybrid dynamic and strict typing is flexible enough to allow duck typing. Its functions are, more specifically, closures, and it allows object orientation using prototypes.

Apart from Strings, Numbers, URIs, Regexps, and other such atoms, its most important datatype is the Table, which is an array and hashtable hybrid à la Javascript and Lua (from which it gets its name). All of a program's code is stored in Tables that may then be manipulated by the program itself. Being a data-structured language it allows self-modification à la Smalltalk and Lisp.

Download and Install

See below for installation instructions. Pluvo comes as a single package with all tests and documentation included. The just-in-time compiler is not by any means optimised, though should Pluvo emerge from its rapid prototype development phase then targeting IMCC may be a future option when Parrot is mature enough.

Status: Most of the structure and essential functions are implemented, but the standard library is very sparse so it'll be difficult to implement non-trivial programs in it. The language is mainly a features playground; further development will depend on the viability of the approaches. Please feel free to help out by using the language, reporting bugs, and submitting patches!

Installation: Full instructions are given in the README.txt file in the package, but basically it's the normal ./configure, make, and make install (with privileges) dance. You only need to do the latter step if you want to install pluvo into /usr/local/bin; otherwise you can use the pluvo.py script to test the language without installing. Try running pluvo hello.pvo to check the installation quickly.

Hello World

The best way to get a feel for a programming language is to look at examples. Hello world in Pluvo is just a one liner, say "Hello, world!", so here's a more illustrative script:

#!/usr/bin/env pluvo

% grep.pvo - Search Files for Pattern
Author: Sean B. Palmer, inamidst.com

usage
   "grep.pvo [options] pattern filenames+"
   -h/--help "Display a help message"
   -t/--test "Perform builtin code tests"

grep = (filenames pattern)
   %% Grep through filenames for pattern
   example
      grep ("tag:pluvo.org,2006:words") "ria"
      => "20. Thesmophoriazousae"

   for line {@lines filenames}
      /$pattern/ line { out line }

main = (argv)
   --help or {not args} { help }
   --test { check grep; quit }
   grep {args.filenames} {args.pattern}

script main

Check out the Guide to Pluvo for a quick walkthrough of the language, written mainly for people who already have a fair amount of programming experience. There isn't really a good introduction to Pluvo yet for anyone who is starting out programming, and Pluvo isn't yet recommended for those types of people (I suggest Python, Lisp, Ruby, or Perl). There's also a guide to Pluvo's basic functions, which contains a few helpful examples.

Another way to get a feel for a language is to be told what it's derived from, but it's hard to say what Pluvo is most like. The author is a Python addict, but the feel of the language isn't really all that Pythonic, even though it might look like that on the surface. For example, the whitespace indenting is really just bracket optionality, so it owes more to Haskell on that front. Its object orientedness is like Javascript and Self. Its syntax owes much to Bash, and its structure owes a lot to Lisp. The datatypes are much like you would find in any programming language, but Tables are from Javascript and Lua. A couple of the function names are from Perl6. There's also a lot of novel stuff in there.

Feedback

There is a Pluvo Mailing List that you can subscribe to and ask questions etc. on, with a mail-archive.com mirror of the messages available. Or you can send email direct to the author using the following form:

Your email address:

Frequently Asked Questions

Q: Where did the name "Pluvo" come from?
A: Pluvo is Esperanto for "rain". No particuar reason why it was chosen, other than that it fulfilled the usual naming criteria of being fairly rare, easy to say, and so on.

Q: Does Pluvo work on Windows?
A: Yes. It was developed on Windows, in fact. You'll need to install Cygwin, the Linux-like environment for Windows, of which there are many lightweight variants (try searching for more information). It's very easy to install and use.

Q: What license is Pluvo released under?
A: At the moment none, so full copyright is retained, but the plan is to use an Open Source or Free Software license. The problem is deciding which one, or which ones, to use! If you can make a case for a particular license, please do so on the Pluvo mailing list. Before a license is chosen, you're still free to use it: "Once you've legally downloaded a program, you can compile it. You can run it. You can modify it. You can distribute your patches for other people to use." And once a suitable license is chosen you'll be able to do much more.

Q: What justifies Yet Another Programming Language?
A: I wanted to develop a language to fill a gap in my scripting needs, calquing features from the languages I know since whenever I go to use them I always dream of a hybrid. In fact I ended up taking from more languages than I use. Languages are consensus driven, so there's no harm in there being another one; if people think it's good they'll use it, and if they don't then it'll be out there but unspoken of. Either way there have already been benefits for me: making a language is fun, and there's a lot to learn by doing.

Q: Is Pluvo stable and suitable for use yet?
A: It's not stable. It's suitable for use as long as you understand that it may undergo large backwards incompatible changes whilst it's in its alpha phase. Once it's out of alpha, pains will be taken to ensure that backwards incompatible changes don't happen.

Q: Is Pluvo being worked on?
A: Yes, but sporadically. It's mainly an experiment and a playground, though it does seem to be a very good one. But whilst it may be a highly viable approach to structuring a programming language, actually implementing a programming language is not a weekend job, especially for a programming team of one. If you want to see it be furthered, feel free to write code in it, give feedback, and contribute.

Q: Where is the source repository?
A: You can use the inamidst directory browser to view the source, and the updates and changes service to view the differences between versions as GNU unified diff files.

Acknowledgements

Thanks to Cody Woodard for designing the logo and helping with the site, and Javier Candeira for sundry helpful feedback. Thanks to Aaron Swartz and Christopher Schmidt for hosting inamidst.com. If anybody else wants to help out and be credited, there are quite a few things that can be done. Feel free to ask via the feedback methods above.

Sean B. Palmer, inamidst.com