编辑
Windows下的一款命令行小工具,用于在单个文件或多个文件中查找并替换字符串。
本文访问次数:0

下载地址见官方网站
使用方法很简单

Usage: FART [options] [--] <wildcard>[,...] [find_string] [replace_string]

Options:
 -h --help          Show this help message (ignores other options)
 -q --quiet         Suppress output to stdio / stderr
 -V --verbose       Show more information
 -r --recursive     Process sub-folders recursively
 -c --count         Only show filenames, match counts and totals
 -i --ignore-case   Case insensitive text comparison
 -v --invert        Print lines NOT containing the find string
 -n --line-number   Print line number before each line (1-based)
 -w --word          Match whole word (uses C syntax, like grep)
 -f --filename      Find (and replace) filename instead of contents
 -B --binary        Also search (and replace) in binary files (CAUTION)
 -C --c-style       Allow C-style extended characters (\xFF\0\t\n\r\\ etc.)
    --cvs           Skip cvs dirs; execute "cvs edit" before changing files
 -a --adapt         Adapt the case of replace_string to found string
 -b --backup        Make a backup of each changed file
 -p --preview       Do not change the files but print the changes

例如把文件a.bat中的字符串atom替换成stun

fart.exe a.bat atom stun

需要输入验证码才能留言

没有任何评论