App::G...hanges(3pm)
β¨ App::G...hanges(3pm) π
okay so bestie, you're looking at the App::GitHooks::StagedChanges manual page β it's a User Contributed Perl Documentation page (that's the 3pm part, iykyk), and it's literally all about staged changes in git. let's get into it π«Ά
πΈ NAME πΈ
App::GitHooks::StagedChanged β staged changes in git. that's the vibe. periodt.
π VERSION π
Version 1.9.0 β¨
π METHODS π
the main character section. every single one of these is a method you can call, so let's go π¦
π new()
makes you a brand new App::GitHooks::StagedChanges object. fresh out the box, no cap.
my $staged_changes = App::GitHooks::StagedChanges->new(
app => $app,
);
Arguments:
app(mandatory) β anApp::GitHookinstance. you have to pass this one, it's not optional bestie, no skipping π
π get_app()
gives you back the parent App::GitHooks object. like, "who's your parent?" and it answers.
my $app = $staged_changes->get_app();
π verify()
verifies the changes that are being committed. the vibe check of the whole operation honestly.
this method returns an array made up of:
- a boolean telling you whether the checks passed or failed.
- a boolean telling you whether any warnings got displayed.
( $allow_commit, $has_warnings ) = $staged_changes->verify();
π check_changed_files()
verifies that the files that changed pass all the various rules. multiple files, multiple rules, so much going on.
this method returns an array made up of:
- a boolean telling you whether the files passed the checks.
- a boolean telling you whether any warnings got displayed.
my ( $all_files_pass, $has_warnings ) = check_changed_files();
π check_file()
verifies that that one specific file passes all the verification rules. very "let's focus on you, babe" energy.
this method returns an array made up of:
- a boolean telling you whether the file passed all the checks.
- a boolean telling you whether any warnings got displayed.
my ( $file_passes, $has_warnings ) = check_file(
count => $count,
file => $file,
git_action => $git_action,
total => $total,
);
Arguments:
count(mandatory) β the number of the file in the list of files to check.file(mandatory) β the path of the file to check.git_action(mandatory) β the action git performed on the file (add,delete, etc).total(mandatory) β the total number of files to check as part of this git hooks instance.
π run_parallelized_checks()
runs the checks for a given file in parallel. multitasking queen behavior, we love to see it π₯
run_parallelized_checks(
tests => $tests,
file => $file,
git_action => $git_action,
);
Arguments:
testsβ an arrayref of tests to run.fileβ the path of the file being checked.git_actionβ the type of action recorded by git on the file (deletion,addition, etc).
π format_check_output()
formats the output of a check against a file into a printable string. it's giving glow-up for data β¨
format_check_output(
app => $app,
data =>
{
name => $name,
return_value => $return_value,
error_message => $error_message,
}
);
π analyze_changes()
analyzes the state of the repository to detect whether the changes correspond to a merge or a revert operation. detective mode π
$staged_changes->analyze_changes();
π is_revert()
returns true if the changes correspond to a git revert operation, false otherwise.
my $is_revert = $staged_changes->is_revert();
π is_merge()
returns true if the changes correspond to a git revert operation, false otherwise.
my $is_merge = $staged_changes->is_merge();
not me side-eyeing the copy-paste in the original docs π but bestie, i'm just the messenger β that's literally what it says, so that's what you get. i don't make the rules π
π BUGS π
please report any bugs or feature requests through the web interface at <https://github.com/guillaumeaubert/App-GitHooks/issues/new>. the author will be notified, and then you'll automatically be notified of progress on your bug as changes get made. so you're looped in, bestie, always π«Ά
π SUPPORT π
you can find documentation for this module with the perldoc command.
perldoc App::GitHooks::StagedChanges
you can also look for information at:
- GitHub's request tracker β
<https://github.com/guillaumeaubert/App-GitHooks/issues> - AnnoCPAN: Annotated CPAN documentation β
<http://annocpan.org/dist/app-githooks> - CPAN Ratings β
<http://cpanratings.perl.org/d/app-githooks> - MetaCPAN β
<https://metacpan.org/release/App-GitHooks>
π AUTHOR π
Guillaume Aubert <https://metacpan.org/author/AUBERTG>, "<aubertg at cpan.org>". iconic, honestly π
π COPYRIGHT & LICENSE π
Copyright 2013-2017 Guillaume Aubert.
This code is free software; you can redistribute it and/or modify it under the same terms as Perl 5 itself.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the LICENSE file for more details. (yes that's the loud part, keep it loud π’)
okay that's the whole page, you made it, I'm so proud π₯Ή this was App::G...hanges(3pm) from perl v5.42.0, dated 2025-07-25. go forth and commit responsibly, bestie πππ¦
π¦ where this page comes from
- fedora 43: perl-App-GitHooks 1.9.0-27.fc43 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms