How to search case insensitive even with accent characters on the command line with the Swiss File Knife for Windows.
case insensitive search and file selection:
since version 1.9.0 SFK for Windows supports
case insensitive search within the codepage ofyour Windows system. for example,
- computers with german or french locale with codepage
1252 may search german and french text, ignoring case
for accent and umlaut characters.
- computers with russian locale with codepage 1251
may search cyrillic text, case insensitive.
but you may not search french text on a russian
locale case insensitive, as codepage 1251 does
not contain the required accent characters.
this means to use case insensitive search you are
limited to search your own language, plus english.
to see what codepage your system uses, type:
to force codepage 1252 (ISO 8859-1) internally in SFK,
no matter what the actual system codepage is,
use global option -isochars directly after sfk,
or set the environment like:
this is recommended when creating script packackes
for distribution that must behave the same on any
computer, regardless of the local codepage.
to see in detail how characters are mapped during
case insensitive search, use global option -tracecase:
sfk -tracecase filter in.txt -+myword
use -tracecase2 to also show chars which are not mapped
because they are lowercase already, or not a letter.
for the full list of SFK character mappings see:
sfk listcodescase search options:-case search case sensitive, a != A
-nocase search case insensitive (default),
a == A and a_accent == A_accent
depending on your codepage
-nocasemin search case insensitive but only
latin characters a-z (ASCII low codes)
-deacc use accent insensitive text search
and filename selection, i.e.
a == A == a_accent == A_accent.
cannot be combined with -case.
can also be set by environment like:
SET SFK_CONFIG=deaccsee alsosfk help chars about codepages
SFK for Linux can only search latin base characters
from A to Z case insensitive, without any accents.