From 589b92e430fd0769ab4d871221f7e23f44dff3f7 Mon Sep 17 00:00:00 2001 From: Timothy Sample Date: Thu, 16 May 2019 22:33:06 -0400 Subject: [PATCH] Remove unneeded files. * HACKING, TODO, bin/builtin.in, sh.bnf, todo/*: Delete files. --- HACKING | 17 --- TODO | 14 --- bin/builtin.in | 24 ---- sh.bnf | 205 ----------------------------------- todo/case | 4 - todo/for.sh | 1 - todo/ifthen.sh | 1 - todo/ifthenelse.sh | 1 - todo/iohere | 3 - todo/process-substitution-in | 1 - todo/test | 1 - todo/test.sh | 3 - 12 files changed, 275 deletions(-) delete mode 100644 HACKING delete mode 100644 TODO delete mode 100644 bin/builtin.in delete mode 100644 sh.bnf delete mode 100644 todo/case delete mode 100644 todo/for.sh delete mode 100644 todo/ifthen.sh delete mode 100644 todo/ifthenelse.sh delete mode 100644 todo/iohere delete mode 100644 todo/process-substitution-in delete mode 100644 todo/test delete mode 100644 todo/test.sh diff --git a/HACKING b/HACKING deleted file mode 100644 index adf459e..0000000 --- a/HACKING +++ /dev/null @@ -1,17 +0,0 @@ -Working up to a 0.1 release. - -TODO: - * Fix word/delim/substitute - * Implement export - * Pass all tests - * Add missing tests, repeat :-) - -Try - - make check-bash - make check-gash - -or - - bash -e test/42-sh-export.sh - ./pre-inst-env gash -e test/42-sh-export.sh diff --git a/TODO b/TODO deleted file mode 100644 index 9211b2f..0000000 --- a/TODO +++ /dev/null @@ -1,14 +0,0 @@ -* setup test driven development: done -* execute tests using gash: done -* parsing posix shell: nested "'""'": done -* globbing: done -* job control: done -* substitution: done -* readline: prompt2: in progress -* pipe: in progress: mix built-in with process -* compound: case, while, until -* expansion: done -* alias: -* iohere: -* redirection: -* posix compliance: diff --git a/bin/builtin.in b/bin/builtin.in deleted file mode 100644 index d0eff5f..0000000 --- a/bin/builtin.in +++ /dev/null @@ -1,24 +0,0 @@ -#! @GUILE@ \ ---no-auto-compile -e main -L @guile_site_dir@ -C @guile_site_ccache_dir@ -L . -C . -s -!# -;;; Gash --- Guile As SHell -;;; Copyright © 2016,2017,2018 R.E.W. van Beusekom -;;; Copyright © 2018 Jan (janneke) Nieuwenhuizen -;;; -;;; This file is part of Gash. -;;; -;;; Gash is free software; you can redistribute it and/or modify it -;;; under the terms of the GNU General Public License as published by -;;; the Free Software Foundation; either version 3 of the License, or (at -;;; your option) any later version. -;;; -;;; Gash is distributed in the hope that it will be useful, but -;;; WITHOUT ANY WARRANTY; without even the implied warranty of -;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;;; GNU General Public License for more details. -;;; -;;; You should have received a copy of the GNU General Public License -;;; along with Gash. If not, see . - -(define (main args) - (apply (@@ (gash commands @builtin@) main) args)) diff --git a/sh.bnf b/sh.bnf deleted file mode 100644 index b69a5e1..0000000 --- a/sh.bnf +++ /dev/null @@ -1,205 +0,0 @@ -/* ------------------------------------------------------- - The grammar symbols - ------------------------------------------------------- */ -%token WORD -%token ASSIGNMENT_WORD -%token NAME -%token NEWLINE -%token IO_NUMBER - - -/* The following are the operators mentioned above. */ - - -%token AND_IF OR_IF DSEMI -/* '&&' '||' ';;' */ - - -%token DLESS DGREAT LESSAND GREATAND LESSGREAT DLESSDASH -/* '<<' '>>' '<&' '>&' '<>' '<<-' */ - - -%token CLOBBER -/* '>|' */ - - -/* The following are the reserved words. */ - - -%token If Then Else Elif Fi Do Done -/* 'if' 'then' 'else' 'elif' 'fi' 'do' 'done' */ - - -%token Case Esac While Until For -/* 'case' 'esac' 'while' 'until' 'for' */ - - -/* These are reserved words, not operator tokens, and are - recognized when reserved words are recognized. */ - - -%token Lbrace Rbrace Bang -/* '{' '}' '!' */ - - -%token In -/* 'in' */ - -/* ------------------------------------------------------- - The Grammar - ------------------------------------------------------- */ -%start complete_command -%% -complete_command : list separator - | list - ; -list : list separator_op and_or - | and_or - ; -and_or : pipeline - | and_or AND_IF linebreak pipeline - | and_or OR_IF linebreak pipeline - ; -pipeline : pipe_sequence - | Bang pipe_sequence - ; -pipe_sequence : command - | pipe_sequence '|' linebreak command - ; -command : simple_command - | compound_command - | compound_command redirect_list - | function_definition - ; -compound_command : brace_group - | subshell - | for_clause - | case_clause - | if_clause - | while_clause - | until_clause - ; -subshell : '(' compound_list ')' - ; -compound_list : term - | newline_list term - | term separator - | newline_list term separator - ; -term : term separator and_or - | and_or - ; -for_clause : For name linebreak do_group - | For name linebreak in sequential_sep do_group - | For name linebreak in wordlist sequential_sep do_group - ; -name : NAME /* Apply rule 5 */ - ; -in : In /* Apply rule 6 */ - ; -wordlist : wordlist WORD - | WORD - ; -case_clause : Case WORD linebreak in linebreak case_list Esac - | Case WORD linebreak in linebreak case_list_ns Esac - | Case WORD linebreak in linebreak Esac - ; -case_list_ns : case_list case_item_ns - | case_item_ns - ; -case_list : case_list case_item - | case_item - ; -case_item_ns : pattern ')' linebreak - | pattern ')' compound_list linebreak - | '(' pattern ')' linebreak - | '(' pattern ')' compound_list linebreak - ; -case_item : pattern ')' linebreak DSEMI linebreak - | pattern ')' compound_list DSEMI linebreak - | '(' pattern ')' linebreak DSEMI linebreak - | '(' pattern ')' compound_list DSEMI linebreak - ; -pattern : WORD /* Apply rule 4 */ - | pattern '|' WORD /* Do not apply rule 4 */ - ; -if_clause : If compound_list Then compound_list else_part Fi - | If compound_list Then compound_list Fi - ; -else_part : Elif compound_list Then compound_list - | Elif compound_list Then compound_list else_part - | Else compound_list - ; -while_clause : While compound_list do_group - ; -until_clause : Until compound_list do_group - ; -function_definition : fname '(' ')' linebreak function_body - ; -function_body : compound_command /* Apply rule 9 */ - | compound_command redirect_list /* Apply rule 9 */ - ; -fname : NAME /* Apply rule 8 */ - ; -brace_group : Lbrace compound_list Rbrace - ; -do_group : Do compound_list Done /* Apply rule 6 */ - ; -simple_command : cmd_prefix cmd_word cmd_suffix - | cmd_prefix cmd_word - | cmd_prefix - | cmd_name cmd_suffix - | cmd_name - ; -cmd_name : WORD /* Apply rule 7a */ - ; -cmd_word : WORD /* Apply rule 7b */ - ; -cmd_prefix : io_redirect - | cmd_prefix io_redirect - | ASSIGNMENT_WORD - | cmd_prefix ASSIGNMENT_WORD - ; -cmd_suffix : io_redirect - | cmd_suffix io_redirect - | WORD - | cmd_suffix WORD - ; -redirect_list : io_redirect - | redirect_list io_redirect - ; -io_redirect : io_file - | IO_NUMBER io_file - | io_here - | IO_NUMBER io_here - ; -io_file : '<' filename - | LESSAND filename - | '>' filename - | GREATAND filename - | DGREAT filename - | LESSGREAT filename - | CLOBBER filename - ; -filename : WORD /* Apply rule 2 */ - ; -io_here : DLESS here_end - | DLESSDASH here_end - ; -here_end : WORD /* Apply rule 3 */ - ; -newline_list : NEWLINE - | newline_list NEWLINE - ; -linebreak : newline_list - | /* empty */ - ; -separator_op : '&' - | ';' - ; -separator : separator_op linebreak - | newline_list - ; -sequential_sep : ';' linebreak - | newline_list - ; diff --git a/todo/case b/todo/case deleted file mode 100644 index 0cfeb5a..0000000 --- a/todo/case +++ /dev/null @@ -1,4 +0,0 @@ -case "$1" in - 1) echo foo;; - *) echo bar;; -esac diff --git a/todo/for.sh b/todo/for.sh deleted file mode 100644 index 5789d8d..0000000 --- a/todo/for.sh +++ /dev/null @@ -1 +0,0 @@ -for f in test/*.sh; do echo "$f:" | grep '.sh' ; done diff --git a/todo/ifthen.sh b/todo/ifthen.sh deleted file mode 100644 index b70af03..0000000 --- a/todo/ifthen.sh +++ /dev/null @@ -1 +0,0 @@ -if test -e TODO; then echo exists; echo I think; fi diff --git a/todo/ifthenelse.sh b/todo/ifthenelse.sh deleted file mode 100644 index 38e5a8c..0000000 --- a/todo/ifthenelse.sh +++ /dev/null @@ -1 +0,0 @@ -if test -e TOD; then echo exists; else echo "nope it don't"; fi diff --git a/todo/iohere b/todo/iohere deleted file mode 100644 index 15ff922..0000000 --- a/todo/iohere +++ /dev/null @@ -1,3 +0,0 @@ -cat <