#!/usr/bin/perl use strict; # https://perlmonks.org/?node_id=11151867 use warnings; use Path::Tiny; my $configlist = path('config.file')->slurp; path("$_.config")->spew( $configlist =~ s/floppy0=\K/$_/r ) for path('gamelist.txt')->lines({chomp => 1});