-my @args = ( 'htpasswd' );
-push @args, '-c' if $opt_c;
-push @args, $opt_h, $user;
-system(@args) == 0 or die "htpasswd failed: $?";
+if ( $opt_h ) {
+ my @args = ( 'htpasswd' );
+ push @args, '-c' if $opt_c;
+ push @args, $opt_h, $user;
+ system(@args) == 0 or die "htpasswd failed: $?";
+}
+
+my $secretfile = $opt_s || 'secrets';