Changeset 16179 for trunk/Nebulous/bin/neb-cp
- Timestamp:
- Jan 22, 2008, 11:14:55 AM (18 years ago)
- File:
-
- 1 edited
-
trunk/Nebulous/bin/neb-cp (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Nebulous/bin/neb-cp
r13075 r16179 1 1 #!/usr/bin/env perl 2 2 3 # Copyright (C) 2007 Joshua Hoblitt3 # Copyright (C) 2007-2008 Joshua Hoblitt 4 4 # 5 # $Id: neb-cp,v 1. 3 2007-04-28 01:24:26jhoblitt Exp $5 # $Id: neb-cp,v 1.4 2008-01-22 21:14:55 jhoblitt Exp $ 6 6 7 7 use strict; … … 16 16 use Pod::Usage qw( pod2usage ); 17 17 18 my ($ node, $server);18 my ($volume, $server); 19 19 20 20 $server = $ENV{'NEB_SERVER'} unless $server; 21 21 22 22 GetOptions( 23 ' node|n=s' => \$node,23 'volume|v=s' => \$volume, 24 24 'server|s=s' => \$server, 25 25 ) || pod2usage( 2 ); … … 41 41 42 42 my $status; 43 if ($ node) {44 $status = $neb->copy( $src, $dst, $ node);43 if ($volume) { 44 $status = $neb->copy( $src, $dst, $volume); 45 45 } else { 46 46 $status = $neb->copy( $src, $dst); … … 59 59 =head1 SYNOPSIS 60 60 61 neb-cp [--server <URL>] [-- node <dst volume>] <src key> <dst key>61 neb-cp [--server <URL>] [--volume <dst volume name>] <src key> <dst key> 62 62 63 63 =head1 DESCRIPTION 64 64 65 This program list Nebulous keys matched by C<<pattern>>. Call it with no 66 arguments is equivalanet to searching with the pattern C<.*>. Where 67 C<<pattern>> is a POSIX 1003.2 compatable regular repression. 65 Copy a Nebulous storage key 68 66 69 67 =head1 OPTIONS … … 76 74 77 75 Optional if the appropriate environment variable is set. 76 77 =item * -volume|-v <volume name> 78 79 The volume to place the new key's first storage instance on. 80 81 Optional. 78 82 79 83 =back … … 107 111 =head1 COPYRIGHT 108 112 109 Copyright (C) 2007 Joshua Hoblitt. All rights reserved.113 Copyright (C) 2007-2008 Joshua Hoblitt. All rights reserved. 110 114 111 115 This program is free software; you can redistribute it and/or modify it under
Note:
See TracChangeset
for help on using the changeset viewer.
