App::CELL::Util(3pm)
β¨ NAME β¨
App::CELL::Util β bestie, it's a grab-bag of generalized, reuseable functions π«Ά the little Swiss Army knife of a Perl module, no cap π
πΈ SYNOPSIS πΈ
okay so here's the vibe check on how you actually use it π
use App::CELL::Util qw( utc_timestamp is_directory_viable );
# utc_timestamp
print "UTC time is " . utc_timestamp() . "\n";
# is_directory_viable
my $status = is_directory_viable( $dir_foo );
print "$dir_foo is a viable directory" if $status->ok;
if ( $status->not_ok ) {
my $problem = $status->payload;
print "$dir_foo is not viable because $problem\n";
}
like, you pull in the two functions you want, you ask for the UTC timestamp, you check if a directory is viable and you check ->ok / ->not_ok on the status object π and if it's not_ok, the ->payload tells you why. chef's kiss π
π¦ EXPORTS π¦
This module provides the following public functions β these are the ones you can actually ask for, bestie:
is_directory_viablestringify_argsutc_timestamp
periodt. that's the whole roster π
π PACKAGE VARIABLES π
(yeah, this section exists. it's giving mysterious. moving on π)
π₯ FUNCTIONS π₯
π is_directory_viable
Run viability checks on a directory. Takes: full path to directory. Returns: true (directory viable) or false (directory not viable). If the directory is not viable, it sets the package variable $App::CELL::Util::not_viable_reason.
so basically you hand it a full path, it does its little checks, and you get a true/false back π«Ά and when the answer is no, it drops the tea into that package variable $App::CELL::Util::not_viable_reason so you know exactly what went wrong. lowkey the most useful thing ever for error reporting π
π stringify_args
Convert args (or any data structure) into a string β useful for error reporting.
literally: hand it args, or honestly any data structure, and it hands you back a string π perfect for when you're throwing an error and you need to show what the heck got passed in. main character debugging energy β¨
π§ utc_timestamp
bestie, the docs give us the name and... that's it. no description. iconic minimalism, we love a mystery π
and that's the whole page!! this one's from App::CELL::Util(3pm), living under perl v5.34.0, dated 2022-07-17 β user contributed Perl documentation, as a lil treat πΈ thanks for reading, mwah, go be viable πβ¨π
π¦ where this page comes from
- debian bookworm: libapp-cell-perl 0.231-1 Β· BSD-3-Clause
- debian trixie: libapp-cell-perl 0.231-1 Β· BSD-3-Clause
- ubuntu noble: libapp-cell-perl 0.231-1 Β· BSD-3-Clause
- ubuntu resolute: libapp-cell-perl 0.231-1 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms