LinuxSystem minishell (리눅스 미니쉘)
닫기
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
해당 자료는 10페이지 까지만 미리보기를 제공합니다.
10페이지 이후부터 다운로드 후 확인할 수 있습니다.

소개글

LinuxSystem minishell (리눅스 미니쉘)에 대한 보고서 자료입니다.

목차

[minishell] 37.9KB
a.c
a.o
MakeFile.txt
minishell.c
minishell.exe
minishell.h
minishell.o
parse_Path.c
parse_Path.o
pipe.c
pipe.o
prt_Prompt.c
prt_Prompt.o


linux_minishell.hwp
■ 실습환경
■ Source Codes

본문내용

linux_minishell.hwp


■ 실습환경
  ♢ OS / 기종
    Microsoft Windows XP (정품)
    AMD Semptron Processor 3000 + 512MB RAM (사무용 PC)
  ♢ PC 환경 Capture

■ Source Codes

♢ minishell - main - source codes
/***************************************************
*                         *
* Filename : minishell.c              *
* Developer :                   *
* Student # :                   *
* Grade : 학년                  *
* Programming purpose : minishell implementation  *
***************************************************/
// minishell.h 파일을 include 함
#include "minishell.h"

// 경로를 파싱(해석)한다
extern int parse_Path(char *dirs[]); // parsing Path
// Shell의 prompt를 출력하는 함수
extern void prt_Prompt();
// 전체 CommandLine을 읽는 함수
char readCommand(char *, char *);
// 읽어들인 CommandLine을 파싱하는 함수
int parseCommand(char *cLine, struct command_t *cmd);
// 환경변수에서 경로를 읽어들여 명령어가 있는지 찾는 함수
char *lookupPath(char **argv, char **dir);
// 명령어2개를 인자로 받아들여서 파이프로 처리하는 함수
extern int pipes(struct command_t *cmd, struct command_t *cmd1);



▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒


minishell.c




// minishell.h 파일을 include 함
#include "minishell.h"

// 경로를 파싱(해석)한다
extern int parse_Path(char *dirs[]); // parsing Path
// Shell의 prompt를 출력하는 함수
extern void prt_Prompt();
// 전체 CommandLine을 읽는 함수
char readCommand(char *, char *);
// 읽어들인 CommandLine을 파싱하는 함수
int parseCommand(char *cLine, struct command_t *cmd);
// 환경변수에서 경로를 읽어들여 명령어가 있는지 찾는 함수
char *lookupPath(char **argv, char **dir);
// 명령어2개를 인자로 받아들여서 파이프로 처리하는 함수
extern int pipes(struct command_t *cmd, struct command_t *cmd1);

int main()
{
 // shell의 초기화인 initialization
 struct command_t command;
 struct command_t command1;
 char *pathv[MAX_ARGS];
 char *commandLine,d;
 char *commandLine1;
 int pid,numChildren = 0;
 int i, status;

 /* CommandLine에 메모리를 할당 */
 commandLine=(char*)malloc(LINE_LEN);
 commandLine1=(char*)malloc(LINE_LEN);

 /* Start Shell */
 printf("***********************************************************\n");
 printf("* 학번             LINUX MINISHELL PROJECT *\n");
 printf("* IF YOU WANT TO QUIT, TYPE QUIT AND ENTER        *\n");
 printf("***********************************************************\n");

 /* 경로를 파싱함 */
 parse_Path(pathv);

키워드

  • 가격3,300
  • 페이지수30페이지
  • 등록일2012.07.23
  • 저작시기2007.1
  • 파일형식압축파일(zip)
  • 자료번호#759364
본 자료는 최근 2주간 다운받은 회원이 없습니다.
청소해
다운로드 장바구니