Building a Perl 6 Project
What This Guide Covers
Perl 6 builds are not available on the OS X environment.
Travis CI support forPerl 6 is contributed by the community and may be removed or altered at any time. If you run into any problems, please report them in the Travis CI issue tracker and cc @paultcochrane @hoelzro @ugexe @tony-o .
Choosing Perl 6 versions to test against
Perl 6 workers on Travis CI use
rakudobrew to provide several Perl 6
versions that your projects can be tested against. To specify them, use the
perl6: key in your
.travis.yml file, for example:
language: perl6 perl6: - latest - '2017.05' - '2017.04'
Over time, new releases come out and we upgrade both rakudobrew and
Perls, aliases like
2017.05 will float and point to different exact
versions, patch levels and so on.
For precise versions pre-installed on the VM, please consult “Build system information” in the build log.
Perl 6 Stack
Default Perl 6 Version
If you leave the
perl6 key out of your
.travis.yml, Travis CI will build
Rakudo Perl 6 from the latest commit from the project’s
Default Test Script
By default, the following command will be used to run the project’s tests:
PERL6LIB=lib prove -v -r --exec=perl6 t/
There is currently no automated dependency management
At present, by default Travis CI does not automatically manage your
project’s dependencies. It is possible to manage dependencies yourself by
either downloading and installing your dependencies as part of the
step, or you could use zef (the Perl 6
module package manager) like so:
install: - rakudobrew build-zef - zef --debug --depsonly install .
this will install the latest
Further information about overriding dependency installation commands is described in the general build configuration guide.
When overriding build commands, do not use sudo
When overriding the
install: key to tweak dependency installation
commands, do not use sudo. Travis CI Environment has Perl 6 versions
installed via rakudobrew in a non-privileged user
$HOME directory. Using
sudo will result in dependencies being installed in unexpected (for the
Travis CI Perl 6 builder) locations and they won’t load.
For Perl 6 projects,
perl6 can be given as arrays to construct a
build matrix. (As yet untested).
The Perl 6 version a job is using is available via:
Build and test with the latest Rakudo
language: perl6 perl6: - latest install: - rakudobrew build-zef - zef --debug --depsonly install .
Build and test with multiple Rakudo versions
language: perl6 perl6: - '2017.05' - '2017.04' install: - rakudobrew build-zef - zef --debug --depsonly install .
Build and test with the latest Rakudo, but with non-standard lib and test dirs
src/ for the module library code, and
tests/ as the test
directory. Please note that it is standard practice to put the module
library code under
lib/ and the tests under
language: perl6 script: - PERL6LIB=src prove -v -r --exec=perl6 tests/