Pod::Strip(3pm)

πŸ“¦
version 1.100 Β· 6 versions
, in ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– Pod::Strip β€” bestie edition πŸ’–

okay so this is the Pod::Strip page from the User Contributed Perl Documentation section (the 3pm one, iykyk), and literally all you need to know is: it takes your Perl code and yeets the POD out of it. that's the whole vibe. πŸ¦‹


✨ NAME ✨

Pod::Strip β€” the little module whose entire personality is "Remove POD from Perl code". no notes. iconic. πŸ‘‘


🌸 VERSION 🌸

this is version 1.100, bestie. that's the one we're talking about. πŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

kay so here's the whole flow, copy it exactly:

use Pod::Strip;

my $p=Pod::Strip->new;              # create parser
my $podless;                        # set output string
$p->output_string(\$podless);       # see Pod::Simple
$p->parse_string_document($code);   # or some other parsing method
                                    #    from Pod::Simple
# $podless will now contain code without any POD

so you make a parser with Pod::Strip->new, you point output_string at a scalar ref (check Pod::Simple for the deets on that one, it's the parent), you run one of the parsing methods β€” like parse_string_document($code) here, or literally any other parsing method that comes from Pod::Simple β€” and boom. $podless is now holding your code with zero POD in it. slay. ✨


πŸ¦‹ DESCRIPTION πŸ¦‹

Pod::Strip is a subclass of Pod::Simple that strips all POD from Perl Code. that's it. that's the job. it does one thing and it ate. πŸ’–


🌈 METHODS 🌈

heads up bestie: every method besides the ones listed right here is inherited from Pod::Simple. so go read that one for the rest, we're only claiming these.

⭐ new

Generate a new parser object. fresh parser, fresh start, main character energy. 🫢

πŸŽ€ replace_with_comments

Call this method with a true argument to replace POD with comments (they look like "# stripped POD") instead of stripping it.

this is highkey the move when you want your line numbers to still get reported correctly in error messages and etc. so like β€” instead of the POD just vanishing and everything shifting, you get little placeholder comments, and the line math stays honest. 😌


πŸ‘‘ AUTHOR πŸ‘‘

Thomas Klausner <domm@plix.at>. give them their flowers. 🌸


This software is copyright (c) 2004 - 2021 by Thomas Klausner.

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


and that's the whole page fr fr πŸ’… β€” this doc came from perl v5.36.0 and it's dated 2022-10-13, so if your Pod::Strip(3pm) looks different, you're on a different version, no cap. bye bestie, go strip some POD 🧚✨

πŸ“¦ where this page comes from