Subversion Repositories HelenOS

Rev

Rev 3397 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3397 Rev 3492
Line 142... Line 142...
142
 
142
 
143
    return RM_BOGUS;
143
    return RM_BOGUS;
144
}
144
}
145
 
145
 
146
/* Dispays help for rm in various levels */
146
/* Dispays help for rm in various levels */
147
void * help_cmd_rm(unsigned int level)
147
void help_cmd_rm(unsigned int level)
148
{
148
{
149
    if (level == HELP_SHORT) {
149
    if (level == HELP_SHORT) {
150
        printf("`%s' removes files and directories.\n", cmdname);
150
        printf("`%s' removes files and directories.\n", cmdname);
151
    } else {
151
    } else {
152
        help_cmd_rm(HELP_SHORT);
152
        help_cmd_rm(HELP_SHORT);
Line 159... Line 159...
159
        "  -f, --force      Do not prompt prior to removing files\n"
159
        "  -f, --force      Do not prompt prior to removing files\n"
160
        "  -s, --safe       Stop if directories change during removal\n\n"
160
        "  -s, --safe       Stop if directories change during removal\n\n"
161
        "Currently, %s is under development, some options don't work.\n",
161
        "Currently, %s is under development, some options don't work.\n",
162
        cmdname, cmdname);
162
        cmdname, cmdname);
163
    }
163
    }
164
    return CMD_VOID;
164
    return;
165
}
165
}
166
 
166
 
167
/* Main entry point for rm, accepts an array of arguments */
167
/* Main entry point for rm, accepts an array of arguments */
168
int * cmd_rm(char **argv)
168
int cmd_rm(char **argv)
169
{
169
{
170
    unsigned int argc;
170
    unsigned int argc;
171
    unsigned int i, scope, ret = 0;
171
    unsigned int i, scope, ret = 0;
172
    int c, opt_ind;
172
    int c, opt_ind;
173
    size_t len;
173
    size_t len;