⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 x_help.c,v

📁 关于SHELL方面的
💻 C,V
字号:
head	1.1;access;symbols;locks	dls:1.1; strict;comment	@ * @;1.1date	97.09.21.19.29.03;	author dls;	state Dist;branches;next	;desc@@1.1log@pre-3e code@text@/* x_help.c - x_help */#include <conf.h>#include <kernel.h>#include <shell.h>#include <cmd.h>#define	COLUMNS	4			/* number of columns to print	*//*------------------------------------------------------------------------ *  x_help  -  (command help) print possible command names for user *------------------------------------------------------------------------ */COMMAND	x_help(stdin, stdout, stderr, nargs, args)int	stdin, stdout, stderr, nargs;char	*args[];{	int	inc;			/* command names per column	*/	int	i;			/* move through printed rows	*/	int	j;			/* move across printed columns	*/	if ( (inc=(Shl.shncmds+COLUMNS-1)/COLUMNS) <= 0)		inc = 1;	fprintf(stdout, "Commands are:\n");	for(i=0 ; i<inc && i<Shl.shncmds ; i++) {		fprintf(stdout, "  ");		for (j=i ; j<Shl.shncmds ; j+=inc)			fprintf(stdout, "%-16s", cmds[j].cmdnam);		fprintf(stdout, "\n");	}	return(OK);}@

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -