CPAN::Changes(3)

πŸ’– CPAN::Changes πŸ’–

okay bestie, so this is the manual for CPAN::Changes β€” a Perl module that parses CPAN-style change logs. it's literally your new fave. πŸŽ€


✨ SYNOPSIS ✨

use CPAN::Changes;
my $changes = CPAN::Changes->load('Changes');
$changes->release('0.01');

🌸 DESCRIPTION 🌸

so like, it's standard practice to include a Changes file in your distribution. the whole point of that Changes file? helping a user figure out what's changed since the last release. periodt. πŸ’…

people have devised many ways to write the Changes file. a preliminary specification has been created (CPAN::Changes::Spec) to encourage module authors to write clear and concise Changes. iconic behavior, honestly.

this module will help users programmatically read and write Changes files that conform to the specification. yes bestie, read and write. πŸ¦‹


πŸ”₯ METHODS πŸ”₯

new ( %args )

Creates a CPAN::Changes object. slay.

%args

  • preamble β€” the preamble section of the changelog.
  • releases β€” an arrayref of CPAN::Changes::Release objects.

load ( $filename, %args )

Creates a new CPAN::Changes object by parsing the given file via CPAN::Changes::Parser. 🧚

load_string ( $filename, %args )

Creates a new CPAN::Changes object by parsing the given string via CPAN::Changes::Parser.

preamble ( [ $preamble ] )

Gets or sets the preamble section. lowkey the easiest one here. πŸ’œ

releases ( [ @releases ] )

Gets or sets the list of releases as CPAN::Changes::Release objects.

add_release ( @releases )

Adds the given releases to the change log. If a release of the same version exists, it will be overwritten. no cap, it'll just replace it. πŸ’€

delete_release ( @versions )

Removes the given versions from change log.

find_release ( $version )

Finds a release with the given version. go little detective go πŸ•΅οΈ β€” well, actually it's just find_release, but you get the vibe.

reversed

Returns a new CPAN::Changes object with the releases in the opposite order. it's giving ✨mirror✨.

clone ( %attrs )

Returns a new CPAN::Changes object with the given attributes changed.

serialize ( %options )

Returns the change log as a string suitable for saving as a Changes file. main character energy fr fr.

  • width β€” the width to wrap lines at. by default, lines will be wrapped at 75 characters.
  • styles β€” an array reference of styles to use when outputting the entries, one for each level of change. the first entry is used for the release entry itself. the styles can be either a single character to prefix change lines or two characters to use as a prefix and suffix.
  • indents β€” an array reference of indent strings to use when outputting the entries.
  • reverse (legacy) β€” if true, releases will be output in reversed order.
  • group_sort (legacy) β€” a code reference used to sort the groups in the releases.

🫢 LEGACY METHODS 🫢

delete_empty_groups

Removes empty groups. bye bye empties πŸ’¨

release

An alias for find_release.


πŸ‘‘ AUTHOR πŸ‘‘

haarg - Graham Knop (cpan:HAARG) <haarg@haarg.org>

🌈 CONTRIBUTORS 🌈

Brian Cassidy <bricas@cpan.org>

Copyright (c) 2011-2015 the CPAN::Changes "AUTHOR" and "CONTRIBUTORS" as listed above.

πŸ’œ LICENSE πŸ’œ

This library is free software and may be distributed under the same terms as perl itself. See <http://dev.perl.org/licenses/>.


ngl bestie, that's the whole page πŸ’… no gatekeeping here.

okay so that's a wrap! this was CPAN::Changes(3) from perl v5.42.0, dated 2025-07-25 β€” screenshot it, save it, tattoo it on your arm, whatever you gotta do πŸ«Άβœ¨πŸŽ€

πŸ“¦ where this page comes from