mirror of
				https://github.com/xcat2/xcat-core.git
				synced 2025-10-31 11:22:27 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			29 lines
		
	
	
		
			507 B
		
	
	
	
		
			Perl
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			29 lines
		
	
	
		
			507 B
		
	
	
	
		
			Perl
		
	
	
		
			Executable File
		
	
	
	
	
| #!/usr/bin/env perl
 | |
| 
 | |
| my $go = 1;
 | |
| 
 | |
| my $file;
 | |
| my $opts = "";
 | |
| 
 | |
| $file = pop @ARGV;
 | |
| if (!$file) {
 | |
|     print "No device given, assuming /dev/cdrom.\n";
 | |
|     $file = "/dev/cdrom";
 | |
| }
 | |
| 
 | |
| while ($go) {
 | |
|     $go = 0;
 | |
| 
 | |
|     #print "copycds $opts $file";
 | |
|     system("copycds $opts $file");
 | |
|     print "Would you like to copy another CD (y/N)? ";
 | |
|     if (<STDIN> =~ /^y/i) {
 | |
|         $go = 1;
 | |
|         system("eject");
 | |
|         print "Replace the CD and press enter.";
 | |
|         <STDIN>;
 | |
|     }
 | |
| }
 | |
| 
 | |
| # vim: set ts=2 sts=2 sw=2 et ai :
 |