|
|
DataMuseum.dkPresents historical artifacts from the history of: DKUUG/EUUG Conference tapes |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about DKUUG/EUUG Conference tapes Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - downloadIndex: T d
Length: 5230 (0x146e)
Types: TextFile
Names: »dishhelp.c«
└─⟦2d1937cfd⟧ Bits:30007241 EUUGD22: P.P 5.0
└─⟦35176feda⟧ »EurOpenD22/isode/isode-6.tar.Z«
└─⟦de7628f85⟧
└─⟦this⟧ »isode-6.0/quipu/dish/dishhelp.c«
/* dishhelp.c - */
#ifndef lint
static char *rcsid = "$Header: /f/osi/quipu/dish/RCS/dishhelp.c,v 7.1 90/01/11 18:37:37 mrose Exp $";
#endif
/*
* $Header: /f/osi/quipu/dish/RCS/dishhelp.c,v 7.1 90/01/11 18:37:37 mrose Exp $
*
*
* $Log: dishhelp.c,v $
* Revision 7.1 90/01/11 18:37:37 mrose
* real-sync
*
* Revision 7.0 89/11/23 22:20:03 mrose
* Release 6.0
*
*/
/*
* NOTICE
*
* Acquisition, use, and distribution of this module and related
* materials are subject to the restrictions of a license agreement.
* Consult the Preface in the User's Manual for the full terms of
* this agreement.
*
*/
#include "quipu/util.h"
#include "quipu/name.h"
#define OPT (!frompipe || rps -> ps_byteno == 0 ? opt : rps)
#define RPS (!frompipe || opt -> ps_byteno == 0 ? rps : opt)
extern char frompipe;
extern PS opt, rps;
struct {
char *command;
char *args;
char serv;
char other;
char *use;
} help_info[] = {
"dish", "[-pipe] [-noconnect] [-user <name>]\n[-password <password>] [-call <dsa name>] [-fast]\n[-simple] [-protected] [-strong] [-noauthentication]", FALSE, FALSE,
"Directory Shell,",
"showentry", "[-[no]cache] [-[no]name] [-[no]move]", TRUE,TRUE,
"show an entry, read it if not cached,",
"list", "[-nocache] [-noshow] [-[no]move]", TRUE,FALSE,
"list children of the current node",
"search", "[-baseobject] [-singlelevel] [-subtree]\n[-filter <filter>]\n[-[no]relative] [-[no]searchalias] [-[no]partial] [-hitone]", TRUE, TRUE,
"search the tree for an object,",
"moveto", "[-[no]pwd] [-[no]check] [-sequence <name>] [-nosequence] <position>", FALSE, FALSE,
"move to position in the DIT",
"modify", "[-draft <draft> [-noedit]] [-newdraft] ", TRUE, FALSE,
"modify an existing node,",
"showname", "[-[no]compact] [-[no]cache]", TRUE,TRUE,
"show the name of an entry,",
"compare", "-attribute <attributeType '=' attributeValue>\n[-[no]print]", TRUE,FALSE,
"compare attribute with the supplied value,",
"add", "[-draft <draft> [-noedit]] [-template <draft>] [-newdraft]\n [-objectclass <objectclass>]", TRUE,FALSE,
"add a new node,",
"delete", "", TRUE,FALSE,
"delete an object,",
"modifyrdn", "-name <attributeType '=' attributeValue> [-[no]delete]", TRUE, FALSE,
"modify the name of a node,",
"squid", "[-sequence <name>] [-alias <position>] [-version]",FALSE, FALSE,
"status of dish,",
"bind", "[-noconnect] [[-user] <name>]\n[-password <password>] [-[no]refer]\n[-call <dsa name>]\n[-simple] [-protected] [-strong] [-noauthentication]", FALSE, FALSE,
"connect to the directory,",
"unbind", "[-noquit]", FALSE, FALSE,
"disconnect from the directory,",
"fred", "[-dm2dn <domain>]", FALSE, FALSE,
"back-end to FrED",
"dsacontrol", "[-[un]lock <entry>] [-dump <directory>]\n[-tailor <string>] [-abort] [-restart] [-info]\n[-refresh <entry>] [-resync <entry>] [-slave [<entry>]]", FALSE, FALSE,
"control the operation of the DSA (managers only),",
"quit", "", FALSE, FALSE, "Quit the program.",
NULL
};
Usage (rtn)
char *rtn;
{
extern DN dn,
savename;
int i;
dn_free (dn);
dn = savename;
savename = NULLDN;
if (print_arg_error (OPT) == OK)
return;
for (i = 0; help_info[i].command != 0; i++)
if (strcmp (help_info[i].command, rtn) == 0) {
if (help_info[i].serv) {
ps_printf (OPT, "Usage %s [-help] [<object>] %s \n", rtn, help_info[i].args);
print_other(OPT, help_info[i].other);
ps_printf (OPT, "\n[<service controls>]\n");
} else
ps_printf (OPT, "Usage %s [-help] %s\n", rtn, help_info[i].args);
return;
}
ps_print (OPT, "Usage...\n");
}
help_arg (rtn)
char *rtn;
{
int i;
for (i = 0; help_info[i].command != 0; i++)
if (strcmp (help_info[i].command, rtn) == 0) {
if (help_info[i].serv) {
ps_printf (RPS, "%-10s - %s\n[<object>] %s ", rtn, help_info[i].use,help_info[i].args);
print_other(RPS,help_info[i].other);
ps_print (RPS,"\n");
print_service();
} else
ps_printf (RPS, "%-10s - %s\n%s\n", rtn, help_info[i].use,help_info[i].args);
return;
}
ps_print (OPT,"Sorry - No help available\n");
}
print_other (aps,x)
PS aps;
char x;
{
if (x == FALSE)
return;
ps_print (aps,"\n[-[no]types <attribute-type> *] [-[no]all]\n[-[no]value] [-[no]show] \n[-[no]key] [-edb]\n[-proc <syntax> <process>]");
}
print_service ()
{
ps_print (RPS,"[-sequence <name>] [-nosequence]\n");
ps_print (RPS,"[-[no]preferchain] [-[no]chaining]\n");
ps_print (RPS,"[-[dont]usecopy] [-[dont]dereferencealias]\n");
ps_print (RPS,"[-low] [-medium] [-high]\n");
ps_print (RPS,"[-timelimit n] [-notimelimit]\n");
ps_print (RPS,"[-sizelimit n] [-nosizelimit]\n");
ps_print (RPS,"[-strong] [-[no]refer]\n");
ps_print (RPS,"[-[no]localscope] [-help]\n");
}
call_help ()
{
int i;
ps_print (RPS, "The following commands are recognised...\n\n");
for (i = 0; help_info[i].command != 0; i++)
ps_printf (RPS, "%-10s - %s\n", help_info[i].command, help_info[i].use);
ps_print (RPS,"\nEnter <command> -help for help on that command\n");
ps_print (RPS, "See the DISH manual for full details\n\n");
}