Ottawa PC Users' Group (OPCUG)


   Copyright and Usage

   Privacy Policy

   Contact Us


Swiss File Knife

by Chris Taylor

When it comes to searching for and manipulating files, there are a lot of utilities out there. I recently came across an interesting free program called Swiss File Knife (SFK). This utility has an incredible array of capabilities built into a single, compact, command-line program. There are versions for Windows, Linux and MacOS. While there is probably not a lot about SFK that is unique, it might be able to replace a couple of dozen or more separate programs.

SFK is a portable program. You don’t have to install it. Just open a CMD prompt, and run the small program (under 2 MB) with the appropriate command line option to have it perform the function you want. If you run it with no parameters, it will provide help information. The small size and portable nature of the program makes it ideal to have on a flash drive you carry with you. Then you have it available when working on any computer.

SFK can do a lot!

In basic searching, it can find files that contain specific text strings, report on the size of folders or folders with files or a certain age, count the lines in text files, and find files over a given size. There is a duplicate file finder. You can compare two folders to find different or added files. Head and Tail functions list the starting or ending lines of a text file. SFK can create and verify MD5 checksums, which is a way of uniquely identifying files and often used to verify that a file has not been modified in any way.

SFK can also manipulate the contents of files: replace tabs with spaces, eliminate duplicate lines, sort files, insert text at the beginning or end of files, replace a given string with other text, and split large files into smaller chunks.

There are some more esoteric functions built into SFK. You can it have remove spaces from file and folder names. This can be useful when you are doing batch processing of files where spaces in file and folder names can cause problems. It can grab text from the Windows clipboard or put text onto the clipboard. You can search for text strings in environment variables. The pathfind parameter allows you to see where a program on your path actually loads from.

One of the odder functions is phonetic spelling; a way of speaking a word or phrase when you have to make sure the receiver gets the exact correct spelling. SFK spell packet will return Peter Alpha Charlie King Echo Tango. If you prefer NATO phonetic spelling, SFK spell -nato packet will return Papa Alpha Charlie Kilo Echo Tango. Say either to someone and they will understand you mean packet, as opposed to what they might think if you say Phishing Aisle Cue Knot Eye Tsar.

SFK can even create an FTP or Web server on your computer. They are not particularly full-featured, and the security (or lack thereof) is such that intranet-only use is recommended. But if you need a quick and dirty way to transfer some files, SFK can do the job.

The functions in SFK have a myriad of option switches to modify the way they operate. The functions I have mentioned just scratch the surface of what SFK can accomplish. For full details, see the web site.

The built-in help may be sufficient for many. If you want all the built-in help in a single text file, SFK dumphelp > sfk-help.txt will produce a 320K file called sfk-help.txt. If you want more, you can buy a $5, 260-page PDF file with complete details, including 60 pages of tutorials.

Bottom Line:

Swiss File Knife (Freeware)
Version 1.8.2 (2016-11-15)

Originally published: June, 2017

top of page



Archived Reviews





The opinions expressed in these reviews
do not necessarily represent the views of the
Ottawa PC Users' Group or its members.