Commit | Line | Data |
cb57845a |
1 | This is the Perl distribution Try-Tiny. |
2 | |
3 | Installing Try-Tiny is straightforward. |
4 | |
5 | ## Installation with cpanm |
6 | |
7 | If you have cpanm, you only need one line: |
8 | |
9 | % cpanm Try::Tiny |
10 | |
b4b13135 |
11 | If it does not have permission to install modules to the current perl, cpanm |
12 | will automatically set up and install to a local::lib in your home directory. |
13 | See the local::lib documentation (https://metacpan.org/pod/local::lib) for |
14 | details on enabling it in your environment. |
cb57845a |
15 | |
16 | ## Installing with the CPAN shell |
17 | |
18 | Alternatively, if your CPAN shell is set up, you should just be able to do: |
19 | |
20 | % cpan Try::Tiny |
21 | |
22 | ## Manual installation |
23 | |
0a844ed9 |
24 | As a last resort, you can manually install it. If you have not already |
25 | downloaded the release tarball, you can find the download link on the module's |
26 | MetaCPAN page: https://metacpan.org/pod/Try::Tiny |
27 | |
28 | Untar the tarball, install configure prerequisites (see below), then build it: |
cb57845a |
29 | |
30 | % perl Makefile.PL |
31 | % make && make test |
32 | |
33 | Then install it: |
34 | |
35 | % make install |
36 | |
0a844ed9 |
37 | On Windows platforms, you should use `dmake` or `nmake`, instead of `make`. |
38 | |
b4b13135 |
39 | If your perl is system-managed, you can create a local::lib in your home |
40 | directory to install modules to. For details, see the local::lib documentation: |
41 | https://metacpan.org/pod/local::lib |
cb57845a |
42 | |
0a844ed9 |
43 | The prerequisites of this distribution will also have to be installed manually. The |
44 | prerequisites are listed in one of the files: `MYMETA.yml` or `MYMETA.json` generated |
45 | by running the manual build process described above. |
46 | |
47 | ## Configure Prerequisites |
48 | |
49 | This distribution requires other modules to be installed before this |
50 | distribution's installer can be run. They can be found under the |
51 | "configure_requires" key of META.yml or the |
52 | "{prereqs}{configure}{requires}" key of META.json. |
53 | |
54 | ## Other Prerequisites |
55 | |
56 | This distribution may require additional modules to be installed after running |
57 | Makefile.PL. |
58 | Look for prerequisites in the following phases: |
59 | |
60 | * to run make, PHASE = build |
61 | * to use the module code itself, PHASE = runtime |
62 | * to run tests, PHASE = test |
63 | |
64 | They can all be found in the "PHASE_requires" key of MYMETA.yml or the |
65 | "{prereqs}{PHASE}{requires}" key of MYMETA.json. |
66 | |
cb57845a |
67 | ## Documentation |
68 | |
69 | Try-Tiny documentation is available as POD. |
0a844ed9 |
70 | You can run `perldoc` from a shell to read the documentation: |
cb57845a |
71 | |
72 | % perldoc Try::Tiny |
0a844ed9 |
73 | |
74 | For more information on installing Perl modules via CPAN, please see: |
75 | https://www.cpan.org/modules/INSTALL.html |