# include <clientapi.h> # include <mapapi.h> # include <options.h> # include "joincheck.h" int main( int argc, char** argv ) { ClientApi client; Error e; JoinCheck check( &client, &e ); Options opts; argc--; argv++; ErrorId usage = { E_FAILED, "Usage: joincheck [ -b branch -c client -u user -v ]" }; opts.Parse( argc, argv, "u:b:c:v", OPT_NONE, usage, &e ); client.SetProtocol( "tag", "" ); client.Init( &e ); if ( e.Test() ) { check.Message( &e ); return 1; } check.LoadProtect( opts['u'] ); check.LoadBranch( opts['b'] ); check.LoadClient( opts['c'] ); client.Final( &e ); if ( e.Test() ) { check.Message( &e ); return 1; } check.DoJoins(); MapApi *j = check.FullJoin(); printf( "Joined map size: %d lines\n", j->Count() ); printf( "Most wild line: %d wildcards\n", check.MaxWild( j ) ); if ( opts['v'] ) { printf( "\nJoined map:\n" ); check.DumpView( j ); } return 0; }
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#5 | 7787 | Sam Stafford |
Integrated Stephen's change over. Tidied it up some. |
||
#4 | 7730 | Sam Stafford | Raise joinmax tunables, and update the build. | ||
#3 | 7729 | Sam Stafford | Whoops, forgot to update the usage string. | ||
#2 | 7728 | Sam Stafford |
Add an option for a file path, and another join of the protect table after the branch map. |
||
#1 | 7727 | Sam Stafford |
MapApi-based tool for displaying joins of protects, client, and optionally a branch view. |