# NAME

File::Find::utf8 - Fully UTF-8 aware File::Find

# VERSION

version 0.003

# SYNOPSIS

    # Use the utf-8 versions of find and finddepth
    use File::Find::utf8;
    find(\&wanted, @directories_to_search);

    # Revert back to non-utf-8 versions
    no File::Find::utf8;
    finddepth(\&wanted, @directories_to_search);

    # Export only the find function
    use File::Find::utf8 qw(find);
    find(\&wanted, @directories_to_search);

    # Export no functions
    use File::Find::utf8 qw(:none); # NOT "use File::Find::utf8 qw();"!
    File::Find::find(\&wanted, @directories_to_search);

# DESCRIPTION

While the original [File::Find](https://metacpan.org/pod/File::Find) functions are capable of handling
UTF-8 quite well, they expect and return all data as bytes, not as
characters.

This module replaces the [File::Find](https://metacpan.org/pod/File::Find) functions with fully UTF-8
aware versions, both expecting and returning characters.

**Note:** Replacement of functions is not done on DOS and OS/2
as these systems do not have full UTF-8 file system support.

## Behaviour

The module behaves as a pragma so you can use both `use
File::Find::utf8` and `no File::Find::utf8` to turn utf-8 support on
or off.

By default, both find() and finddepth() are exported (as with the original
[File::Find](https://metacpan.org/pod/File::Find)), if you want to prevent this, use `use File::Find::utf8
qw(:none)`. (As all the magic happens in the module's import function,
you can not simply use `use File::Find::utf8 qw()`)

[File::Find](https://metacpan.org/pod/File::Find) warning levels are properly propagated. Note though that
for propagation of fatal [File::Find](https://metacpan.org/pod/File::Find) warnings, Perl 5.12 or higher
is required (or the appropriate version of [warnings](https://metacpan.org/pod/warnings)).

# SEE ALSO

- [File::Find](https://metacpan.org/pod/File::Find)
- [Cwd::utf8](https://metacpan.org/pod/Cwd::utf8)
- [utf8::all](https://metacpan.org/pod/utf8::all)

# AUTHOR

Hayo Baan <info@hayobaan.nl>

# COPYRIGHT AND LICENSE

This software is copyright (c) 2014 by Hayo Baan.

This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.
