Sponsored Content
Top Forums Shell Programming and Scripting sed error in UNIX but not Linux Post 302891759 by Perderabo on Friday 7th of March 2014 06:51:53 PM
Old 03-07-2014
I think you're missing a semi-colon. Try this:
Code:
sed -n "$line_number { n; p; q;}" en.pep

This User Gave Thanks to Perderabo For This Post:
 

10 More Discussions You Might Find Interesting

1. Answers to Frequently Asked Questions

What is unix and is linux a unix system

Unix is the name of an operating system. And unix is a registered trademark. This is what makes things murky. One of my favorite books is The Design and Implementation of the 4.3BSD UNIX Operating System. That book is out of print, but a newer book is available: The Design and Implementation... (0 Replies)
Discussion started by: Perderabo
0 Replies

2. Shell Programming and Scripting

sed error : Syntax error: redirection unexpected

My script is throwing the error 'Syntax error: redirection unexpected' My line of code.. cat nsstatustest.html | sed s/<tr><td align="left">/<tr><td align="left" bgcolor="#000000"><font color="white">/ > ztmp.Ps23zp2s.2-Fpps3-wmmm0dss3 HTML tags are getting in the way but they're needed to... (3 Replies)
Discussion started by: phpfreak
3 Replies

3. Shell Programming and Scripting

sed works on Linux and Unix does not work

Hi, I use this command in Linux but if I run the same command does not work in freebsd. Follow the below command: Linux works: sed -e '1731a\' -e '####' squid.conf > squid2.conf ; sed -e '1731a\' -e 'acl TESTE_ip src 192.168.1.1/255.255.255.255' squid2.conf > squid.conf ; sed -e... (7 Replies)
Discussion started by: andreirp
7 Replies

4. Shell Programming and Scripting

sed returns error "sed: -e expression #1, char 18: unterminated `s' command"

Hello All, I have something like below LDC100/rel/prod/libinactrl.a LAA2000/rel/prod/libinactrl.a I want to remove till first forward slash that is outputshould be as below rel/prod/libinactrl.a rel/prod/libinactrl.a How can I do that ??? (8 Replies)
Discussion started by: anand.shah
8 Replies

5. Shell Programming and Scripting

sed and awk giving error ./sample.sh: line 13: sed: command not found

Hi, I am running a script sample.sh in bash environment .In the script i am using sed and awk commands which when executed individually from terminal they are getting executed normally but when i give these sed and awk commands in the script it is giving the below errors :- ./sample.sh: line... (12 Replies)
Discussion started by: satishmallidi
12 Replies

6. Fedora

Which is the better platform to learn UNIX/Linux (Kali Linux Vs. Red Hat or other)?

I just started a new semester and I started my UNIX class yesterday. I've already decided to use python along with my learning process but what I really want to use with it is Kali as my UNIX/Linux platform to learn off of since I already wanted to learn Cyber Sec. anyways. I just wanted to know if... (12 Replies)
Discussion started by: ApacheOmega
12 Replies

7. UNIX for Beginners Questions & Answers

Simple sed command not working; could be a Mac/Linux vs. PC/Linux issue

Hello, I am on a Mac and trying to clean up some monthly files with a very simple SED: sed '3,10d;/<ACROSS>/,$d' input.txt > output.txt (from the input, delete lines 3 - 10; then delete from the line containing <ACROSS> to the end of the file) then output to output.txt Even when I try... (2 Replies)
Discussion started by: verbatim
2 Replies

8. Post Here to Contact Site Administrators and Moderators

VIP Membership - The UNIX and Linux Forums - Get Your UNIX.COM Email Address Here

We work hard to make The UNIX and Linux Forums one of the best UNIX and Linux knowledge sources on the net. The site is certainly one of the top UNIX and Linux Q&A sites on the web. In order to provide certain members the best quality account services, you can now get some great extra features by... (2 Replies)
Discussion started by: Neo
2 Replies

9. What is on Your Mind?

YouTube: Forum Moderation @UNIX.com | The UNIX and Linux Forums

Forum Moderation @UNIX.com | The UNIX and Linux Forums https://youtu.be/WGwgibE4Rq0 Also note: In the video I mentioned removing legacy menu items in the ModCP which are unused. I have already "CSS'ed out" the unused menu items: ... (0 Replies)
Discussion started by: Neo
0 Replies

10. UNIX for Beginners Questions & Answers

sed with regexp in Linux

OFF 00280456 - 2014|1|2020_STATUS|GROUP_NAME|SUBGROUP_NAME|CLASS_NAME|GROUP_ID|SUBGROUP_ID I have above header in file. I need to replace 2020_STATUS with STATUS. 2020_STATUS is not always same but the column name will have STATUS all of the time. For instance column name might be 2019_STATUS... (1 Reply)
Discussion started by: jmadhams
1 Replies
DwtColorMixSetNewColor(3Dwt)											      DwtColorMixSetNewColor(3Dwt)

Name
       DwtColorMixSetNewColor - Sets the new red, green, and blue color values in the color mixing widget.

Syntax
       void DwtColorMixSetNewColor(cmw, red, green, blue)
	    Widget cmw;
	    unsigned short red;
	    unsigned short green;
	    unsigned short blue;

Arguments
       cmw	 Specifies the widget ID of the color mixing widget.

       red	 Specifies the new color red value.  You can express the value in percentages or by the X color values (0 to 65535).

       green	 Specifies the new color green value.  You can express the value in percentages or by the X color values (0 to 65535).

       blue	 Specifies the new color blue value.  You can express the value in percentages or by the X color values (0 to 65535).

		 See  the  section on colormap functions in the Guide to the Xlib Library: C Language Binding for more information on X color val-
		 ues.

Description
       The DwtColorMixSetNewColor function allows the user-supplied color mixer subwidget to pass the current color values  to	the  color  mixing
       widget.	Using DwtColorMixSetNewColor is more efficient than using XtSetValues.

See Also
       DwtColorMixGetNewColor(3Dwt), DwtColorMixCreate(3Dwt)
       Guide to the XUI Toolkit: C Language Binding
       Guide to the XUI Toolkit Intrinsics: C Language Binding

														      DwtColorMixSetNewColor(3Dwt)
All times are GMT -4. The time now is 10:21 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy