Added 'dry-run' mode for testing