File: README

package info (click to toggle)
libfile-policy-perl 1.005-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 156 kB
  • sloc: perl: 226; makefile: 2
file content (40 lines) | stat: -rw-r--r-- 1,384 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
File::Policy v1.005

(c) BBC 2004. This program is free software; you can redistribute it and/or modify it under the GNU GPL.

See the file COPYING in this distribution, or http://www.gnu.org/licenses/gpl.txt 

QUICK START:

Install File::Policy by unpacking the tarball and running the following
commands in the source directory:

	perl Makefile.PL
	make
	make test
	make install
	Then delete the source directory tree since it's no longer needed.

	By using File::Policy (or File::Slurp::WithinPolicy) in your code you get File::Policy::Default by, erm, default.  
	This imposes no restrictions on filepaths, but does provide reasonable default temp and log dirs for you.  
	See the POD for File::Policy::Default to see how these paths are determined.

	To implement your own custom policy
	  cp File/Policy/Default.pm File/Policy/YourPolicy.pm
	and modify YourPolicy accordingly.
	
	Then, create a file File/Policy/Config.pm with:
	
	  use constant IMPLEMENTATION => 'YourPolicy';

	run 'perldoc File::Policy' to read the full documentation.

SAMPLE:

See samples/lib/File/Policy/Simple.pm for an example of a custom policy.

DEPENDENCIES:

Pod::Test and Pod::Test::Coverage are used by two of the unit tests if present 
- otherwise these 2 tests should skip gracefully.  Tests require Test::Assertions and Log::Trace
which is why these are listed in the PREREQ_PM in Makefile.PL.