1Type::Tiny::Manual::InsUtsaelrlaCtoinotnr(i3b)uted PerlTDyopceu:m:eTnitnayt:i:oMnanual::Installation(3)
2
3
4

NAME

6       Type::Tiny::Manual::Installation - how to install Type::Tiny
7

MANUAL

9       Installing Type-Tiny should be straightforward.
10
11   Installation with cpanminus
12       If you have cpanm, you only need one line:
13
14         % cpanm Type::Tiny
15
16       If you are installing into a system-wide directory, you may need to
17       pass the "-S" flag to cpanm, which uses sudo to install the module:
18
19         % cpanm -S Type::Tiny
20
21   Installation with the CPAN Shell
22       Alternatively, if your CPAN shell is set up, you should just be able to
23       do:
24
25         % cpan Type::Tiny
26
27   Manual Installation
28       As a last resort, you can manually install it. Download the tarball and
29       unpack it.
30
31       Consult the file META.json for a list of pre-requisites. Install these
32       first.
33
34       To build Type-Tiny:
35
36         % perl Makefile.PL
37         % make && make test
38
39       Then install it:
40
41         % make install
42
43       If you are installing into a system-wide directory, you may need to
44       run:
45
46         % sudo make install
47
48   Dependencies
49       Type::Tiny requires at least Perl 5.8.1, though certain Unicode-related
50       features (e.g. non-ASCII type constraint names) may work better in
51       newer versions of Perl.
52
53       Type::Tiny requires Exporter::Tiny, a module that was previously
54       bundled in this distribution, but has since been spun off as a separate
55       distribution. Don't worry - it's quick and easy to install.
56
57       At run-time, Type::Tiny also requires the following Perl modules: B,
58       B::Deparse, Carp, Data::Dumper, Scalar::Util, Text::Balanced, overload,
59       strict, and warnings.  All of these come bundled with Perl itself.
60
61       Certain features require additional modules. Stack traces on exceptions
62       require Devel::StackTrace. The Reply::Plugin::TypeTiny plugin for Reply
63       requires Reply (obviously).
64
65       Type::Tiny::XS is not required, but if available provides a speed boost
66       for some type checks. (Setting the environment variable
67       "PERL_TYPE_TINY_XS" to false, or setting "PERL_ONLY" to true will
68       suppress the use of Type::Tiny::XS, even if it is available.)
69
70       The test suite additionally requires Test::More, Test::Fatal and
71       Test::Requires. Test::More comes bundled with Perl, but if you are
72       using a version of Perl older than 5.14, you will need to upgrade to at
73       least Test::More version 0.96. Test::Requires and Test::Fatal (plus
74       Try::Tiny which Test::Fatal depends on) are bundled with Type::Tiny in
75       the "inc" directory, so you do not need to install them separately.
76
77       If using Type::Tiny in conjunction with Moo, then at least Moo 1.006000
78       is recommended. If using Type::Tiny with Moose, then at least Moose
79       2.0000 is recommended. If using Type::Tiny with Mouse, then at least
80       Mouse 1.00 is recommended. Type::Tiny is mostly untested against older
81       versions of these packages.
82
83       Type::Tiny and cperl
84
85       cperl <http://perl11.org/cperl/> is an extended version of Perl with
86       various incompatible changes from the official Perl 5 releases.
87
88       As of Type::Tiny 1.010001, cperl is a supported platform for Type::Tiny
89       with some caveats. At the time of writing, Moose will not install on
90       the latest cperl releases, so using Type::Tiny with Moose on cperl is
91       untested. Moo can be forced to install, and Type::Tiny is verified to
92       work with Moo on cperl.  cperl not only enables a new warnings category
93       called "shadow" (which is good; they're potentially useful) but
94       switches on shadow warnings by default (which is annoying). Type::Tiny
95       does not (and likely will never) attempt to work around these warnings.
96       If the warnings bother you, you should be able to catch them using
97       $SIG{__WARN__}. Certain features of Eval::TypeTiny are broken under
98       cperl, but they're not thought to have any practical effect on
99       Type::Tiny or its other bundled modules.
100

NEXT STEPS

102       Here's your next step:
103
104       •   Type::Tiny::Manual::UsingWithMoo
105
106           Basic use of Type::Tiny with Moo, including attribute type
107           constraints, parameterized type constraints, coercions, and method
108           parameter checking.
109

AUTHOR

111       Toby Inkster <tobyink@cpan.org>.
112
114       This software is copyright (c) 2013-2014, 2017-2023 by Toby Inkster.
115
116       This is free software; you can redistribute it and/or modify it under
117       the same terms as the Perl 5 programming language system itself.
118

DISCLAIMER OF WARRANTIES

120       THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED
121       WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
122       MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
123
124
125
126perl v5.36.0                      2023-01-04Type::Tiny::Manual::Installation(3)
Impressum