Exchange files and update issues with your colleagues via an S3 bucket or rsync.
Configure and run an exchanger:
use Data::Exchange; my $x = Data::Exchange::new(); $x->user = q(phil); $x->bucket = q(com.appaapps.exchange); $x->exchange = q(/home/phil/exchange); $x->start;
Files that end in .txt no matter where they are located below the exchange folder:
$x->exchange
will be merged with files of the same name from your colleagues whose files show up in other folders under the exchange folder, allowing you to share files and update issues with your colleagues.
Issue files that start with a plus sign + in column one of line one are assumed to be work in progress and will be ignored until the initial plus sign is removed.
Lines which start with defined keywords in column one have special meanings if the occur in the first section of an issues file:
to: user
The name of the user to which this issue is addressed otherwise all users will see copies of this issue.
files and update issues with your colleagues via an S3 bucket or rsync.
The following sections describe the methods in each functional area of this module. For an alphabetic listing of all methods by name see Index.
Create a new exchanger for a specified user allowing them to exchange files and issues with their colleagues via an S3 bucket or rsync - see: Data::Exchange Definition for the attributes that can be set by this constructor.
Parameter Description 1 @parms Optional parameters
Example:
my $x = Data::Exchange::𝗻𝗲𝘄();
Start a new exchanger as a service via atq.
$x->start;
Exchanger attributes.
boldFilesWithChanges - Bold file names with changed contents
bucket - The meeting point expressed as bucket/optionalPrefix for S3 transport
exchange - Folder containing files locally
ext - Extension of issue files
interval - Interval between exchanges
nexus - The meeting point expressed as a target for rsync transport
quiet - Quiet S3/rsync if true
rsyncOptions - Rsync options
s3Parms - Additional S3 parms
start - Time this exchanger was started
transport - Default file transfer
user - User who owns this instance
Match files that have the same file name.
Parameter Description 1 $x Exchanger
Replace the write line in a file
Parameter Description 1 $file File 2 $line New line
Cut a single file into time sections.
Parameter Description 1 $file File
Find all the files that are issues
Check whether a file is a work in progress depending on whether it has a plus sign in column 1 of line 1 or not.
Find all the files that are in progress.
Assemble the time sections in multiple files into one file.
Parameter Description 1 $x Exchanger 2 @files Files
List user files
Create a bold file name
Parameter Description 1 $file File name
Remove bolding from file name
Make all issue files non bold.
The local folder containing the users own files.
Add a time stamp to files that are no longer in progress
Send one set of files.
Receive one set of files.
Exchange one set of files.
Run until forcibly stopped.
1 boldFileName - Create a bold file name
2 cutByTime - Cut a single file into time sections.
3 Data::Exchange::Details::assemble - Assemble the time sections in multiple files into one file.
4 Data::Exchange::Details::exchangeDown - Receive one set of files.
5 Data::Exchange::Details::exchangeOneSet - Exchange one set of files.
6 Data::Exchange::Details::exchangeUp - Send one set of files.
7 Data::Exchange::Details::findInProgressFiles - Find all the files that are in progress.
8 Data::Exchange::Details::findIssueFiles - Find all the files that are issues
9 Data::Exchange::Details::go - Run until forcibly stopped.
10 Data::Exchange::Details::listFiles - List user files
11 Data::Exchange::Details::localFolder - The local folder containing the users own files.
12 Data::Exchange::Details::matchFiles - Match files that have the same file name.
13 Data::Exchange::Details::stamp - Match files that have the same file name.
14 Data::Exchange::Details::stampUnstampedFiles - Add a time stamp to files that are no longer in progress
15 Data::Exchange::Details::start - Start a new exchanger as a service via atq.
16 Data::Exchange::Details::unBoldFiles - Make all issue files non bold.
17 inProgressFile - Check whether a file is a work in progress depending on whether it has a plus sign in column 1 of line 1 or not.
18 new - Create a new exchanger for a specified user allowing them to exchange files and issues with their colleagues via an S3 bucket or rsync - see: Data::Exchange Definition for the attributes that can be set by this constructor.
19 replaceWriteLine - Replace the write line in a file
20 unBoldFileName - Remove bolding from file name
This module is written in 100% Pure Perl and, thus, it is easy to read, comprehend, use, modify and install via cpan:
sudo cpan install Data::Exchange
philiprbrenan@gmail.com
http://www.appaapps.com
Copyright (c) 2016-2018 Philip R Brenan.
This module is free software. It may be used, redistributed and/or modified under the same terms as Perl itself.
To install Data::Exchange, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Data::Exchange
CPAN shell
perl -MCPAN -e shell install Data::Exchange
For more information on module installation, please visit the detailed CPAN module installation guide.