From owner-freebsd-questions Fri Mar 15 0: 9:10 2002 Delivered-To: freebsd-questions@freebsd.org Received: from swan.prod.itd.earthlink.net (swan.mail.pas.earthlink.net [207.217.120.123]) by hub.freebsd.org (Postfix) with ESMTP id C635537B402 for ; Fri, 15 Mar 2002 00:09:07 -0800 (PST) Received: from sdn-ar-008dcwashp038.dialsprint.net ([63.178.91.150] helo=moo.holy.cow) by swan.prod.itd.earthlink.net with esmtp (Exim 3.33 #1) id 16lmln-00043L-00 for freebsd-questions@freebsd.org; Fri, 15 Mar 2002 00:09:07 -0800 Received: by moo.holy.cow (Postfix, from userid 1001) id 0A60250B81; Fri, 15 Mar 2002 03:08:39 -0500 (EST) Date: Fri, 15 Mar 2002 03:08:39 -0500 From: parv To: f-q Subject: /usr/bin/printf & printing escaped characters Message-ID: <20020315080839.GA18963@moo.holy.cow> Mail-Followup-To: f-q Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG i was trying to print escaped characters (\n & \t), but couldn't... # /usr/bin/printf %s "\tpolka dot\n" \tpolka dot\n ...despite having listed in the man page... Character escape sequences are in backslash notation as defined in the ANSI X3.159-1989 (``ANSI C''). The characters and their meanings are as follows: \a Write a character. \b Write a character. \f Write a character. \n Write a character. \r Write a character. \t Write a character. \v Write a character. \' Write a character. \\ Write a backslash character. \num Write an 8-bit character whose ASCII value is the 1-, 2-, or 3-digit octal number num. ...i didn't see anything else in there. what am i missing? and using awk for this is just plain sick & twisted. - parv -- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message