From owner-freebsd-questions@FreeBSD.ORG Wed Nov 10 19:43:48 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0D31716A4CE for ; Wed, 10 Nov 2004 19:43:48 +0000 (GMT) Received: from smtp-out.hotpop.com (smtp-out.hotpop.com [38.113.3.71]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6388743D39 for ; Wed, 10 Nov 2004 19:43:47 +0000 (GMT) (envelope-from personrp@hotpop.com) Received: from hotpop.com (kubrick.hotpop.com [38.113.3.103]) by smtp-out.hotpop.com (Postfix) with SMTP id EF88911BD1A2 for ; Wed, 10 Nov 2004 19:43:31 +0000 (UTC) Received: from 110-ccbh-131.ccbh.upmc.edu (110-ccbh-131.ccbh.upmc.edu [128.147.110.131]) by smtp-3.hotpop.com (Postfix) with ESMTP id A942011C6829 for ; Wed, 10 Nov 2004 19:43:28 +0000 (UTC) From: Rod Person Organization: Open Source Beef To: freebsd-questions@freebsd.org Date: Wed, 10 Nov 2004 14:43:01 +0000 User-Agent: KMail/1.7 MIME-Version: 1.0 Message-Id: <200411101443.01977.personrp@hotpop.com> X-HotPOP: ----------------------------------------------- Sent By HotPOP.com FREE Email Get your FREE POP email at www.HotPOP.com ----------------------------------------------- Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.1 Subject: Sed Help..... X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: personrp@hotpop.com List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Nov 2004 19:43:48 -0000 I trying to write a script that will make it easier for a friend that I finally talked into trying Freebsd setup a desktop. This part of the script is suppose to change the line in the ttys file to allow kdm to start on boot. Here is the relavent code: KDMLINE="/usr/local/bin/kdm -nodaemon" REPLACELINE="/usr/X11R6/bin/xdm -nodaemon" sed -e "s/$REPLACELINE/$KDMLINE/g" /etc/test/ttys > /etc/test/new Here is the error I'm getting: sed: 1: "s//usr/X11R6/bin/xdm -n ...": bad flag in substitute command: 'X' I can't seem to figure this out and the only things I've found in searching is that sed had a problem with replacing strings over 4096 bytes, but I don't think this is the cause and all those post were years old. This is on FreeBSD 5.3. Rod