Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

replace filename space with underscore bash

for file in *; do mv "$file" `echo $file | tr ' ' '_'` ; done
Comment

linux replace spaces with underscore from all files in directory

find . -type f -name "* *" -exec bash -c 'mv "$0" "${0// /_}"' {} ;
Comment

replace space with underscore in linux

for file in *; do mv "$file" $(echo $file | tr ' ' '_') ; done
Comment

replace space with underscore command line in file name

@echo off
Setlocal enabledelayedexpansion

Set "Pattern= "
Set "Replace=_"

For %%a in (*.exe) Do (
    Set "File=%%~a"
    Ren "%%a" "!File:%Pattern%=%Replace%!"
)

Pause&Exit
Comment

PREVIOUS NEXT
Code Example
Shell :: git remoev .DS_Store 
Shell :: debian kill open port 
Shell :: fail2ban apt 
Shell :: kubectl delete pods 
Shell :: wsl folder linux windows access 
Shell :: pull readme in local repository 
Shell :: find command also return directory names? 
Shell :: npm install -g angular cli 
Shell :: history-search-backward zsh mac 
Shell :: ubuntu remove except file 
Shell :: change ownership of a directory in ubuntu 
Shell :: change fc editor 
Shell :: cara uninstall di centos 7 
Shell :: restart tomcat 9 ubuntu 
Shell :: how to know namespace is present or not in kubernetes shell script 
Shell :: dexie nuxt 
Shell :: alpine linux /bin/sh: node: not found 
Shell :: bind failed address already in use mac 
Shell :: powershell execution policy bypass 
Shell :: install miniconda on mac 
Shell :: bash generate random number between 
Shell :: npm Error: EACCES: permission denied, scandir 
Shell :: install github desktop on arch linux 
Shell :: docker remove none tag images 
Shell :: install chrome in ubuntu 16.04 using terminal 
Shell :: find user shell 
Shell :: django gitignore 
Shell :: how to view all the history of all your commands in linux 
Shell :: xclip does not work 
Shell :: ubuntu 20.04 how to stop apache2 from starting on startup 
ADD CONTENT
Topic
Content
Source link
Name
9+4 =