Test::S...::Syncer(3)
π Test::S...::Syncer β bestie edition π
okay so this is Test::Smoke::Syncer, straight out of the User Contributed Perl Documentation corner of the manual-verse. she's a factory for syncer objects β like, a little machine that spits out the right kind of source-tree-syncing object for you. no cap. π
β¨ NAME β¨
Test::Smoke::Syncer β factory for syncer objects. that's it, that's the whole vibe. she makes syncers. periodt. π
πΈ SYNOPSIS πΈ
here's how you pull up:
use Test::Smoke::Syncer;
my $type = 'rsync'; # or 'snapshot' or 'copy'
my $syncer = Test::Smoke::Syncer->new( $type => \%sync_config );
my $patch_level = $syncer->sync;
so you pick your $type, you hand her a \%sync_config, and she hands you back a whole object. then you call ->sync on it and get your $patch_level. iconic behaviour honestly. π¦
π«Ά DESCRIPTION π«Ά
as of right now, we support three basic types of syncing the perl source-tree. (yes i said three and then there are four listed. don't look at me, i just work here. forest is built on top of the other ones, that's the tea. π)
π rsync
this one runs the rsync program with the --delete option to get your perl source-tree all the way up to date. classic. reliable. ate.
π snapshot
this one uses Net::FTP or the LWP module to grab the latest snapshot. and here's the detail bestie: when the server attribute starts with http://, the fetching gets done by LWP::Simple::mirror(). β¨
to emulate that "rsync --delete" effect, the current source-tree gets removed. like, gone. just so you know.
the snapshot tarball is handled by either tar/gzip or Archive::Tar/Compress::Zlib.
π copy
this one uses the File::Copy module to copy an existing source-tree from somewhere else on the system β perfect for when rsync just isn't working out (it happens to the best of us π). heads up tho: this also removes the current source-tree first. no take-backs.
π forest
this one syncs the source-tree using one of the above basic methods. then, after that, it creates an intermediate copy of the master directory as hardlinks and runs the regen_headers.pl script. that should yield an up-to-date source-tree, bestie. the intermediate directory is then copied as hardlinks to its final directory ({ddir}). π
this can be used to change the way make distclean is run from mktest.pl β it removes all files that are not in the intermediate directory, which may prove faster than the traditional make distclean. highkey a speed hack. π
π METHODS π
π§ Test::Smoke::Syncer->new( $type, \%sync_config )
[ Constructor | Public ]
initialise a new object and check all the relevant arguments. she returns an object of the appropriate Test::Smoke::Syncer::* class β like, the right subclass for whatever $type you asked for. it's giving matchmaker. π«Ά
π§ Test::Smoke::Syncer->config( $key[, $value] )
[ Accessor | Public ]
config() is an interface to the package lexical %CONFIG, which holds all the default values for the new() arguments. so it's the settings drawer. the vibe vault. π
and here's a lil easter egg: with the special key all_defaults this returns a reference to a hash holding all the default values. all of them. the whole collection. β
π SEE ALSO π
go check out her friends, fr fr:
rsyncgziptarArchive::TarCompress::ZlibFile::CopyTest::Smoke::SourceTree
π COPYRIGHT π
(c) 2002-2013, All rights reserved.
- Abe Timmerman
<abeltje@cpan.org>
this library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. slay.
see:
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. so like, she's trying her best but she promises nothing. π
okay that's the whole page bestie, you're all caught up π this one was served to you by perl v5.42.0, dated 2025-07-25, from the User Contributed Perl Documentation. love that for us. go sync something. β¨πΈπ
π¦ where this page comes from
- fedora 43: perl-Test-Smoke 1.84-2.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