HuntnGather – Diff between revs 30 and 31
?pathlinks?
Rev 30 | Rev 31 | |||
---|---|---|---|---|
1 | Short: File indexing and search utilities. |
1 | Short: File indexing and search utilities. |
|
2 | Author: Wizardry and Steamworks |
2 | Author: Wizardry and Steamworks |
|
3 | Uploader: "Wizardry and Steamworks" <office@grimore.org> |
3 | Uploader: "Wizardry and Steamworks" <office@grimore.org> |
|
4 | Type: util/dir |
4 | Type: util/dir |
|
5 | Replaces: util/dir/HuntnGather.lha |
5 | Replaces: util/dir/HuntnGather.lha |
|
6 | Version: 1.7.3 |
6 | Version: 1.7.3 |
|
7 | Architecture: m68k-amigaos |
7 | Architecture: m68k-amigaos |
|
8 | |
8 | |
|
9 | Hunt & Gather - File search and indexing utilities. |
9 | Hunt & Gather - File search and indexing utilities. |
|
10 | (or Hunt'n'Gather bro, ghetto style) |
10 | (or Hunt'n'Gather bro, ghetto style) |
|
11 | |
11 | |
|
12 | © Copyright 2021 by Wizardry and Steamworks |
12 | © Copyright 2021 by Wizardry and Steamworks |
|
13 | |
13 | |
|
14 | Released under the MIT License, all rights reserved. |
14 | Released under the MIT License, all rights reserved. |
|
15 | |
15 | |
|
16 | -=:[ Changes ]:=- |
16 | -=:[ Changes ]:=- |
|
17 | |
17 | |
|
18 | TBA: |
18 | TBA: |
|
- | 19 | * Testing with MuForce. |
||
19 | * Tested using large entire drives and eliminated some bugs. |
20 | * Tested using large entire drives and eliminated some bugs. |
|
20 | * Use locale for string comparisons. |
21 | * Use locale for string comparisons. |
|
21 | * Gather now requires either of -a (add), -r (remove), -c (create). |
22 | * Gather now requires either of -a (add), -r (remove), -c (create). |
|
22 | * Allow specifying multiple paths when gathering. |
23 | * Allow specifying multiple paths when gathering. |
|
23 | |
24 | |
|
24 | -=:[ Introduction ]:=- |
25 | -=:[ Introduction ]:=- |
|
25 | |
26 | |
|
26 | |
27 | |
|
27 | Hunt and Gather are two utiltities for indexing and then searching |
28 | Hunt and Gather are two utiltities for indexing and then searching |
|
28 | fileswithin a drive or directory designed to speed up searching files. |
29 | fileswithin a drive or directory designed to speed up searching files. |
|
29 | |
30 | |
|
30 | The Gather utility is meant to index any path and generate a search |
31 | The Gather utility is meant to index any path and generate a search |
|
31 | database. The Hunt utility will then open the database generated by |
32 | database. The Hunt utility will then open the database generated by |
|
32 | Gather and look for files matching the string provided to Hunt as |
33 | Gather and look for files matching the string provided to Hunt as |
|
33 | parameter. |
34 | parameter. |
|
34 | |
35 | |
|
35 | The utility was designed to check large collections of icons but the |
36 | The utility was designed to check large collections of icons but the |
|
36 | indexing and the fast search results proved indispensable enough for a |
37 | indexing and the fast search results proved indispensable enough for a |
|
37 | self-standing program. |
38 | self-standing program. |
|
38 | |
39 | |
|
39 | -=:[ Design ]:=- |
40 | -=:[ Design ]:=- |
|
40 | |
41 | |
|
41 | Hunt and Gather are designed with constant memory usage in order to be |
42 | Hunt and Gather are designed with constant memory usage in order to be |
|
42 | suitable for all Amiga models. Namely, the Gather utility will search |
43 | suitable for all Amiga models. Namely, the Gather utility will search |
|
43 | all files in a given path, sort the files in ascending order by using |
44 | all files in a given path, sort the files in ascending order by using |
|
44 | an external merge sort (tailored down to a 256KiB memory limit). |
45 | an external merge sort (tailored down to a 256KiB memory limit). |
|
45 | |
46 | |
|
46 | Conversely, Hunt uses brute force to search for files but by reading |
47 | Conversely, Hunt uses brute force to search for files but by reading |
|
47 | lines from the database without loading the entire database in RAM. |
48 | lines from the database without loading the entire database in RAM. |
|
48 | Perhaps ulterior versions of Hunt might partition the database file |
49 | Perhaps ulterior versions of Hunt might partition the database file |
|
49 | just like Gather does and then build Tries in oder to speed up finding |
50 | just like Gather does and then build Tries in oder to speed up finding |
|
50 | files on the filesystem. |
51 | files on the filesystem. |
|
51 | |
52 | |
|
52 | The project adheres to the ANSI C standard and Amiga-centric semantics |
53 | The project adheres to the ANSI C standard and Amiga-centric semantics |
|
53 | are compiled conditionally (in case the "___AmigaOS__" macro is |
54 | are compiled conditionally (in case the "___AmigaOS__" macro is |
|
54 | defined at compile time).Otherwise, Hunt & Gather should run under any |
55 | defined at compile time).Otherwise, Hunt & Gather should run under any |
|
55 | platform that benefits from an ANSI C compiler. |
56 | platform that benefits from an ANSI C compiler. |
|
56 | |
57 | |
|
57 | -=:[ Usage ]:=- |
58 | -=:[ Usage ]:=- |
|
58 | |
59 | |
|
59 | First the Gather utility is used to index a path: |
60 | First the Gather utility is used to index a path: |
|
60 | |
61 | |
|
61 | |
62 | |
|
62 | Gather RAM: |
63 | Gather RAM: |
|
63 | |
64 | |
|
64 | |
65 | |
|
65 | which will create a file in the S: directory named "gahter.db". While |
66 | which will create a file in the S: directory named "gahter.db". While |
|
66 | Gather is running, the utility will display the number of indexed |
67 | Gather is running, the utility will display the number of indexed |
|
67 | directories and files on the command line. |
68 | directories and files on the command line. |
|
68 | |
69 | |
|
69 | In order to look for a file, the Hunt utility is invoked with an |
70 | In order to look for a file, the Hunt utility is invoked with an |
|
70 | Amiga search pattern: |
71 | Amiga search pattern: |
|
71 | |
72 | |
|
72 | |
73 | |
|
73 | Hunt #?test#? |
74 | Hunt #?test#? |
|
74 | |
75 | |
|
75 | |
76 | |
|
76 | in this case, "#?test#?", that will be compared to all the files |
77 | in this case, "#?test#?", that will be compared to all the files |
|
77 | indexed previously by Gather. In case any of the files previously |
78 | indexed previously by Gather. In case any of the files previously |
|
78 | indexed by Gather contain the term "test", then the Hunt utility will |
79 | indexed by Gather contain the term "test", then the Hunt utility will |
|
79 | display the path to the file. |
80 | display the path to the file. |
|
80 | |
81 | |
|
81 | -=:[ Gather ]:=- |
82 | -=:[ Gather ]:=- |
|
82 | |
83 | |
|
83 | The Gather utility takes one single parameter representing the path |
84 | The Gather utility takes one single parameter representing the path |
|
84 | to be indexed; for example, all the following paths are valid: |
85 | to be indexed; for example, all the following paths are valid: |
|
85 | |
86 | |
|
86 | |
87 | |
|
87 | RAM: |
88 | RAM: |
|
88 | DH0:System/ |
89 | DH0:System/ |
|
89 | |
90 | |
|
90 | |
91 | |
|
91 | When Gather runs, a database is created at "S:gather.db" by |
92 | When Gather runs, a database is created at "S:gather.db" by |
|
92 | overwriting the previous database. For best results, Gather should |
93 | overwriting the previous database. For best results, Gather should |
|
93 | run periodically and should scan a path that is most frequently |
94 | run periodically and should scan a path that is most frequently |
|
94 | searched for files. |
95 | searched for files. |
|
95 | |
96 | |
|
96 | -=:[ Hunt ]:=- |
97 | -=:[ Hunt ]:=- |
|
97 | |
98 | |
|
98 | Hunt is the counterpart to Gather and will search the database at |
99 | Hunt is the counterpart to Gather and will search the database at |
|
99 | "S:gather.db" for files matching the terms passed to Hunt on the |
100 | "S:gather.db" for files matching the terms passed to Hunt on the |
|
100 | command line. |
101 | command line. |
|
101 | |
102 | |
|
102 | For instance: |
103 | For instance: |
|
103 | |
104 | |
|
104 | Hunt #?test#? |
105 | Hunt #?test#? |
|
105 | |
106 | |
|
106 | will search all files in the Gather database "S:gather.db" for the |
107 | will search all files in the Gather database "S:gather.db" for the |
|
107 | term "test". If any file within the database partially matches the |
108 | term "test". If any file within the database partially matches the |
|
108 | term "test", then Hunt will display the path on the command line. |
109 | term "test", then Hunt will display the path on the command line. |
|
109 | |
110 | |
|
110 | Hunt uses Amiga-style pattern for matching the file names. |
111 | Hunt uses Amiga-style pattern for matching the file names. |
|
111 | |
112 | |
|
112 | -=:[ Source ]:=- |
113 | -=:[ Source ]:=- |
|
113 | |
114 | |
|
114 | The project is open sourced and licensed under MIT. The source code |
115 | The project is open sourced and licensed under MIT. The source code |
|
115 | is included in the AmiNET release or can be checked out via subversion |
116 | is included in the AmiNET release or can be checked out via subversion |
|
116 | from the Wizardry and Steamworks repository: |
117 | from the Wizardry and Steamworks repository: |
|
117 | |
118 | |
|
118 | svn co http://svn.grimore.org/HuntnGather |
119 | svn co http://svn.grimore.org/HuntnGather |
|
119 | |
120 | |
|
120 | -=:[ Mentions ]:=- |
121 | -=:[ Mentions ]:=- |
|
121 | |
122 | |
|
122 | The code includes a shim for "getopt" in order to process command line |
123 | The code includes a shim for "getopt" in order to process command line |
|
123 | parameters on Amiga without changing the semantics. The shim is |
124 | parameters on Amiga without changing the semantics. The shim is |
|
124 | created by Daniel J. Barrett, barrett@cs.umass.edu and is available on |
125 | created by Daniel J. Barrett, barrett@cs.umass.edu and is available on |
|
125 | AmiNET: |
126 | AmiNET: |
|
126 | |
127 | |
|
127 | http://aminet.net/package/dev/misc/GetOpt-1.3 |
128 | http://aminet.net/package/dev/misc/GetOpt-1.3 |
|
128 | |
129 | |
|
129 | -=:[ Contact ]:=- |
130 | -=:[ Contact ]:=- |
|
130 | |
131 | |
|
131 | E-Mail(tor): |
132 | E-Mail(tor): |
|
132 | |
133 | |
|
133 | office@3wymlmcsvxiaqzmbepsdawqpk6o2qsk65jhms72qqjulk5u4bgmvs3qd.onion |
134 | office@3wymlmcsvxiaqzmbepsdawqpk6o2qsk65jhms72qqjulk5u4bgmvs3qd.onion |
|
134 | |
135 | |
|
135 | Website: https://grimore.org/amiga/hunt_and_gather |
136 | Website: https://grimore.org/amiga/hunt_and_gather |
|
136 | Website(tor): |
137 | Website(tor): |
|
137 | |
138 | |
|
138 | http://3wymlmcsvxiaqzmbepsdawqpk6o2qsk65jhms72qqjulk5u4bgmvs3qd.onion/ |
139 | http://3wymlmcsvxiaqzmbepsdawqpk6o2qsk65jhms72qqjulk5u4bgmvs3qd.onion/ |
|
139 | |
140 | |
|
140 | Discord: https://discord.gg/k9kyDsa |
141 | Discord: https://discord.gg/k9kyDsa |
|
141 | |
142 | |
|
142 | |
143 | |