Version 1.9

The Swiss File Knife Book

Version 1.9.9

Copyright (c) 2023 by StahlWorks Technologies



Only for personal use on devices of the PDF file purchaser.

Printing is allowed for up to three copies per purchased PDF file.

contents

The Swiss File Knife Book

index

2 / 377

Table of contents

Touch any number to jump to that page.

In every page, touch on contents to jump back here.

Introduction

How to do things the same way on all computers

How to get the SFK tool running instantly

The different editions of SFK: OSE, Base, XE

Tutorial

File handling

List all files of a folder, and all sub folders

List only selected files in selected sub folders

List files using wildcards

List the latest or biggest files

Find a file quickly in the current directory tree

List different files between two folders

Run a command on all files of a folder

Rename files quickly using patterns

List the size of directory tree contents

Copy a folder, or parts of it, or only updates

Delete or clean up specific files in a folder

How to use index files for fast filename lookup

Tell where in the PATH a command is run from

Create checksums of files

Find duplicate files

Find and replace within files

Find words in text and binary files

Replace words in text and binary files

Flexible filter and replace in a single text file

Search in files using wildcards and Expressions

9

10

13

14

14

15

16

16

17

18

19

21

23

24

26

27

29

30

31

32

33

34

35

contents

The Swiss File Knife Book

index

File conversion and processing

Convert plain text files between Windows/Linux format

Remove TAB characters from text

Split large files

Collect many text files into one large text

Sort text lines alphabetically

Send files via network

How to send a file from one computer to another

How to transfer many files, or just changed ones

Further useful functions

Read or write the clipboard under Windows

Convert CSV data to tab separated text

Count text lines

Write long commands into a script

Search environment variables for words

Backup and transfer of folders

A script to backup files to an USB drive

Sync holiday snapshot name changes to USB drive

Copy a project folder to a new version

Upload project files to a build server

Optimizing file uploads by modification date

Xed detailed examples

reformat comma separated data

convert fixed column data to CSV

convert CSV data to XML data

convert XML data to CSV data

cleaning up a translation file

extract two letter words from text

3 / 377

36

37

38

39

40

42

44

46

48

41

50

51

52

59

60

61

63

64

65

67

72

66

69

71

contents

The Swiss File Knife Book

Large script examples

Wiki markup text to HTML conversion

using sfk script and xed

index

4 / 377

73

HTTP Scripting and Test Automation

using sfk script, call, web, perline, xex

78

Filling an XML file with program meta data

using sfk script, xex, version, list, calc,

filter, setvar, getvar, xed

A detailed perline example

Script creation and debugging tips

83

90

93

contents

The Swiss File Knife Book

index

5 / 377

Command Reference

General infos

95

Windows/Linux/Mac syntax differences

97

file system

sfk list

- list directory tree contents.

98

list latest, oldest or biggest files.

list directory differences.

list zip jar tar gz bz2 contents.

sfk filefind

- find files by filename

263

sfk treesize

- show directory size statistics

sfk copy

- copy directory trees additively

222

sfk sync

- mirror tree content with deletion

sfk rename

- flexible multi file rename

226

sfk partcopy

- copy part from a file into another one

sfk mkdir

- create directory tree

sfk delete

- delete files and folders

117

sfk deltree

- delete whole directory tree

sfk deblank

- remove blanks in filenames

sfk space [-h] - tell total and free size of volume

218

sfk filetime

- tell times of a file

sfk touch

- change times of a file

sfk index

- create index file(s) for fast lookup 104

sfk name

- lookup file names using index files

sfk fixfile

- change bad filenames and file times

sfk setbytes

- set bytes at offset within a file

350

120

222

207

232

117

170

220

255

106

292

compression

sfk zip

sfk zipto

sfk unzip

sfk checkzip

-

create zip file from folder

zip selected file list

list or extract zip file

verify zip file content

conversion

sfk oload

sfk lf-to-crlf

sfk crlf-to-lf

sfk detab

sfk entab

-

load office file content as text

252

convert from LF to CRLF line endings

118

convert from CRLF to LF line endings

120

convert TAB characters to spaces

115

convert groups of spaces to TAB chars

116

354

362

358

359

................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download