NAME ^

lib/Parrot/BuildUtil.pm - Utilities for building Parrot

DESCRIPTION ^

This package holds two subroutines: parrot_version() and <slurp_file>. Neither subroutine is exported and so each must be requested with a fully qualified path.

SUBROUTINES ^

parrot_version()

Determines the current version number for Parrot from the VERSION file and returns it in a context-appropriate manner.

    $parrot_version = Parrot::BuildUtil::parrot_version();
    # $parrot_version is '0.4.11'

    @parrot_version = Parrot::BuildUtil::parrot_version();
    # @parrot_version is (0, 4, 11)
slurp_file($filename)

Slurps up the filename and returns the content as one string. While doing so, it converts all DOS-style line endings to newlines.

AUTHOR ^

Gregor N. Purdy. Revised by James E Keenan.


parrot