summaryrefslogtreecommitdiffstats
path: root/common/hush.c
Commit message (Collapse)AuthorAgeFilesLines
* hush: allow fancy promptsSascha Hauer2010-03-301-4/+8
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* hush: only remove backslashes introduced from globSascha Hauer2010-03-301-2/+3
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* hush: Fix return code when calling 'exit' inside loopsSascha Hauer2010-03-301-11/+3
| | | | | | | | | | | | | | | | | | | | v2: Do not exit from all scripts but only the current one This fixes the case: barebox:/ cat /test if [ 0 = 0 ]; then exit 1 fi barebox:/ /test barebox:/ echo $? 0 barebox:/ Also, remove code to not allow exit from main shell. The for(;;) loop in common/startup.c will bring us back anyway. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* remove typedef cmd_tbl_t and replace it with struct commandSascha Hauer2010-02-011-3/+3
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* rename U-Boot-v2 project to bareboxSascha Hauer2009-12-151-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | This has been done with the following script: find -path ./.git -prune -o -type f -print0 | xargs -0 -r sed -i \ -e 's/u2boot/barebox/g' \ -e 's/U2Boot/barebox/g' \ -e 's/U-boot V2/barebox/g' \ -e 's/u-boot v2/barebox/g' \ -e 's/U-Boot V2/barebox/g' \ -e 's/U-Boot-v2/barebox/g' \ -e 's/U_BOOT/BAREBOX/g' \ -e 's/UBOOT/BAREBOX/g' \ -e 's/uboot/barebox/g' \ -e 's/u-boot/barebox/g' \ -e 's/u_boot/barebox/g' \ -e 's/U-Boot/barebox/g' \ -e 's/U-boot/barebox/g' \ -e 's/U-BOOT/barebox/g' find -path ./.git -prune -o \( -name "*u-boot*" -o -name "*uboot*" -o -name "*u_boot*" \) -print0 | \ xargs -0 -r rename 's/u[-_]?boot/barebox/' It needs some manual fixup following in the next patch Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* hush: remove include/hush.hSascha Hauer2009-10-221-1/+4
| | | | | | | Everything in include/hush.h is only used in hush.c, so remove the header file. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* commands: remove maxargsSascha Hauer2009-10-191-2/+0
| | | | | | | No need to check for maximum argument counts. The commands are safe to be called with more arguments, so lets safe some bytes. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* commands: return COMMAND_ERROR_USAGESascha Hauer2009-10-191-8/+4
| | | | | | | instead of calling u_boot_cmd_usage in each command to safe space. Signed-off-by: Sascha Hauer <sha@pengutronix.de>
* consolidate command calling in execute_commandSascha Hauer2009-10-191-17/+1
| | | | Signed-off-by: Sascha Hauer <sha@pengutronix.de>
* hush: pass return code from exit commandSascha Hauer2009-09-251-0/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* hush: Only run list if it's not emptySascha Hauer2009-09-251-1/+6
| | | | | | Running empty lists lead to the wrong return status Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* hush: Fix quotingSascha Hauer2008-11-101-1/+1
| | | | | | | | | | | | | | | This patch removes adding of an additional \ when doing echo "\"" which gives \" instead of just " I checked in latest busybox hush and this code is still present there, but it behaves correctly in busybox due to some other code pathes I didn't investigate. If this change has any unwanted side effects feel free to flame on me Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* hush: fix compiler warningSascha Hauer2008-08-261-2/+6
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Subject: [PATCH] [general] Fixed constant strings in data section issueSascha Hauer2008-04-041-4/+7
| | | | | | | | For practical reasons I changed all string literals assumed to be constant to reside in .rodata subsection at end of .text section. Signed-off-by: Carsten Schlote <schlote@vahanus.net> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* replace debug_printf with debug in hush.cSascha Hauer2008-03-091-42/+35
|
* add globbing supportSascha Hauer2008-03-091-27/+103
|
* adding various dokuJuergen Beisert2007-11-081-7/+7
|
* shell info addedJuergen Beisert2007-10-191-20/+24
|
* hush doc addedJuergen Beisert2007-10-191-36/+73
|
* hush.c: split high-density "if(x) something"; into two linesSascha Hauer2007-10-011-27/+57
|
* hush.c: get_local_var() is used only once, put it into the functionSascha Hauer2007-10-011-18/+3
| | | | where it is called
* fix indention in hush.cSascha Hauer2007-10-011-3/+3
|
* remove comment about glob in hush.c. We do not use globSascha Hauer2007-10-011-8/+0
|
* fix indention in hush.cSascha Hauer2007-10-011-64/+66
|
* fix indention in hush.cSascha Hauer2007-10-011-1/+3
|
* fix indention in hush.cSascha Hauer2007-10-011-25/+25
|
* set last_return_code to rcode and not 1 or 0Sascha Hauer2007-09-271-1/+1
|
* pass file size from read_fileSascha Hauer2007-09-271-1/+1
|
* hush.c: use xrealloc instead of realloc to save some bytesSascha Hauer2007-09-261-2/+1
|
* hush.c: use xzalloc instead of xmalloc to save some bytesSascha Hauer2007-09-261-8/+1
|
* hush.c: Remove wrong free() of ctx->pipe->progs. After breaking outSascha Hauer2007-09-261-3/+0
| | | | | of the while loop ctx->pipe is invalid, so we cannot dereference ctx->pipe->progs.
* remove extern declaration of console_bufferSascha Hauer2007-09-261-1/+0
|
* fix indentionSascha Hauer2007-09-251-2/+3
|
* remove hack from hush which did the wrong thingSascha Hauer2007-09-251-5/+0
|
* add $# handling for hushSascha Hauer2007-09-251-0/+28
|
* remove debug printfSascha Hauer2007-09-241-1/+0
|
* remove u-boot command paramter flagSascha Hauer2007-09-241-19/+6
|
* - add 'source' commandSascha Hauer2007-09-241-4/+44
| | | | - add help text for 'source' and 'sh'
* - teach hush to honour PATH variableSascha Hauer2007-09-241-27/+46
| | | | - remove common/main.c. This is now handled in the different shells.
* fix indentionSascha Hauer2007-09-231-27/+27
|
* allow arguments to be passed to scriptsSascha Hauer2007-09-231-52/+100
|
* unifdef __U_BOOT__ in hush.cSascha Hauer2007-09-221-1936/+0
|
* svn_rev_481Sascha Hauer2007-07-051-6/+7
| | | | make more char * const, fix compiler warnings
* svn_rev_424Sascha Hauer2007-07-051-1/+0
|
* svn_rev_392Sascha Hauer2007-07-051-204/+35
| | | | | | | - remove u_boot_hush_start() - remove u_boot_hush_reloc() - remove repeatable commands - do not use local variable handling anymore
* svn_rev_353Sascha Hauer2007-07-051-11/+19
|
* svn_rev_283Sascha Hauer2007-07-051-25/+2
| | | | add xfuncs
* svn_rev_270Sascha Hauer2007-07-051-1/+3
| | | | WIP FS support
* svn_rev_207Sascha Hauer2007-07-051-7/+7
| | | | move several config options to kconfig
* svn_rev_152Sascha Hauer2007-07-051-1/+9
| | | | remove global data gd_t and board info bd_t entirely for arm