summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rw-r--r--bin/sh/Makefile5
-rw-r--r--bin/sh/builtins.def2
-rw-r--r--bin/sh/sh.16
3 files changed, 9 insertions, 4 deletions
diff --git a/bin/sh/Makefile b/bin/sh/Makefile
index 1b0738b..a606c9b 100644
--- a/bin/sh/Makefile
+++ b/bin/sh/Makefile
@@ -5,7 +5,7 @@ PROG= sh
INSTALLFLAGS= -S
SHSRCS= alias.c arith.y arith_lex.l cd.c echo.c error.c eval.c exec.c expand.c \
histedit.c input.c jobs.c mail.c main.c memalloc.c miscbltin.c \
- mystring.c options.c output.c parser.c redir.c show.c \
+ mystring.c options.c output.c parser.c printf.c redir.c show.c \
test.c trap.c var.c
GENSRCS= builtins.c init.c nodes.c syntax.c
GENHDRS= builtins.h nodes.h syntax.h token.h
@@ -26,7 +26,8 @@ WARNS?= 2
WFORMAT=0
.PATH: ${.CURDIR}/bltin \
- ${.CURDIR}/../test
+ ${.CURDIR}/../test \
+ ${.CURDIR}/../../usr.bin/printf
CLEANFILES+= mkinit mkinit.o mknodes mknodes.o \
mksyntax mksyntax.o
diff --git a/bin/sh/builtins.def b/bin/sh/builtins.def
index 75f83b5..b72f887 100644
--- a/bin/sh/builtins.def
+++ b/bin/sh/builtins.def
@@ -71,7 +71,7 @@ histcmd -h fc
jobidcmd jobid
jobscmd jobs
localcmd local
-#printfcmd printf
+printfcmd printf
pwdcmd pwd
readcmd read
returncmd -s return
diff --git a/bin/sh/sh.1 b/bin/sh/sh.1
index 7b1eb61..ba06a0c 100644
--- a/bin/sh/sh.1
+++ b/bin/sh/sh.1
@@ -32,7 +32,7 @@
.\" from: @(#)sh.1 8.6 (Berkeley) 5/4/95
.\" $FreeBSD$
.\"
-.Dd November 12, 2010
+.Dd November 19, 2010
.Dt SH 1
.Os
.Sh NAME
@@ -2049,6 +2049,9 @@ line.
See the
.Sx Functions
subsection.
+.It Ic printf
+A built-in equivalent of
+.Xr printf 1 .
.It Ic pwd Op Fl L | P
Print the path of the current directory.
The built-in command may
@@ -2470,6 +2473,7 @@ will return the argument.
.Xr echo 1 ,
.Xr ed 1 ,
.Xr emacs 1 ,
+.Xr printf 1 ,
.Xr pwd 1 ,
.Xr test 1 ,
.Xr vi 1 ,
OpenPOWER on IntegriCloud