1# hptutil
2[![Build Status](https://travis-ci.org/huskyproject/hptutil.svg?branch=master)](https://travis-ci.org/huskyproject/hptutil)
3[![Build status](https://ci.appveyor.com/api/projects/status/5g8658gfok478bnw/branch/master?svg=true)](https://ci.appveyor.com/project/dukelsky/hptutil/branch/master)
4[![Codacy Badge](https://api.codacy.com/project/badge/Grade/5c962f9826284b0c9a437e0a673435ce)](https://www.codacy.com/app/huskyproject/hptutil?utm_source=github.com&utm_medium=referral&utm_content=huskyproject/hptutil&utm_campaign=Badge_Grade)
5
6## What this program can do
7
8**hptutil purge** - checked all keywords from fidoconfig (maybe I've forgoten
9something, but I tried). From fidoconfig - keepUnread, killRead, purge, max.
10No packing, messages only "marked" as deleted. Reply chains not killed.
11
12**hptutil pack** - packing msgbase, used function of renaming files, thats why
13Golded can't stay in reading areas, in this case may be problems (1st warning!).
14Squish packing didn't set umsgid=1 on first letter. No lastread changeing, but
15if umsgid = FFFFFFFF - this is will be wrong - not checked (2nd warning!). In
16Jam base first letter also non 1, no lastread changing, but if BaseMsgNum will
17be FFFFFFFF and then 0 lastread's will be damaged - not checked (3rd warning!).
18Reply chains not killed.
19
20**hptutil sort** - if an importlog file exist, sorting only areas in this file,
21sorting all areas if importlog not exist. File importlog not deleted. Sorting
22started from lastread, condition - date of the message. Reply chains is killed.
23
24**hptutil link** - if exist importlog file, linking only areas in this file,
25linking all areas if importlog not exist. The deletion of importlog subscribed
26in fidoconfig (and no deleted at all, if you use non documented option -k).
27Linking all active messages in area.
28
29**hptutil** can do one function at a time, for example
30
31**hptutil purge**
32
33**hptutil pack** (attention! bugz!)
34
35or you may use several command line options, for example
36
37**hptutil sort link**
38
39If you set several command line options, work will be not in the order you have put it,
40but first will be purge, then pack, sort, link.
41
42MSG bases are not supported yet, but this is not difficult to implement.
43
44This is like a "fish" - template which needs to be checked, better solutions in
45algorythm, etc.
46
47## Warning
48Before running this tool, change sources to work with one
49area, and make a backup of your message base. The program was tested in OS/2 only (watcom 11b).
50
51With best regards Fedor Lizunkov, 2:5020/960
52