Sponsored Content
Top Forums Shell Programming and Scripting String starting with blank space Post 302506564 by fpmurphy on Monday 21st of March 2011 08:18:40 AM
Old 03-21-2011
This works correctly for me
Code:
$ awk '/^[[:blank:]]/' file
 _1bbb  yes
 c-ccc  yes
 eeeee  yes
 ff  yes

Perhaps you need to use nawk or gawk.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

append blank space

Hi, I would like to add blank space for fixed length(50) if length of string <30. Scenario: File Size AAA.CSV 123 BB.CSV 134 Expected: File Size AAA.CSV 123 BB.CSV 134 I want append blank space until 30 character. Thanks and Regards, HAA (1 Reply)
Discussion started by: HAA
1 Replies

2. Shell Programming and Scripting

Replace a blank space with string "\\ "

Hi, I have a requirement to replace a every blank space with char "\\ ". Like string "God Love" to "God\\ Love" and "God Love" as "God\\ \\ Love". and only in the sed. We have already a script but it is replaceing all continuous blank space with one "\\ ". which is as DIR=`sudo echo... (7 Replies)
Discussion started by: Akshay4u
7 Replies

3. UNIX for Dummies Questions & Answers

Matching exact string with blank space using grep

hi! i'm trying to get grep to do an exact match for the following pattern but..it's not quite working. I'm not too sure where did I get it wrong. any input is appreciated. echo "$VAR" | grep -q '^test:]name' if ; then printf "test name is not found \n" fi on... (4 Replies)
Discussion started by: jazzaddict
4 Replies

4. Shell Programming and Scripting

awk or sed command to print specific string between word and blank space

My source is on each line 98.194.245.255 - - "GET /disp0201.php?poc=4060&roc=1&ps=R&ooc=13&mjv=6&mov=5&rel=5&bod=155&oxi=2&omj=5&ozn=1&dav=20&cd=&daz=&drc=&mo=&sid=&lang=EN&loc=JPN HTTP/1.1" 302 - "-" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.0.3705; .NET CLR... (5 Replies)
Discussion started by: elamurugu
5 Replies

5. Shell Programming and Scripting

Cut last blank space

Hello, I am using this to get only directories : ls -l | grep '^d'and here is the result : drwx------ 13 so_nic sonic 13 Nov 4 13:03 GLARY drwx------ 3 so_nic sonic 3 May 6 2010 PSY2R drwx------ 15 so_nic sonic 15 Oct 14 08:47 PSYR1 But I only need to keep this... (7 Replies)
Discussion started by: Aswex
7 Replies

6. Shell Programming and Scripting

substitute the starting dollar sign in command with blank

Hi,, Let example cmd: $$config/all Here I want to replace or subsitute blank space and also with any other character in place of "$" sign...and also want to replace backslash (/) with forward (\)......in expect script please could any one help on this.....thank you (2 Replies)
Discussion started by: swethakast
2 Replies

7. UNIX for Dummies Questions & Answers

blank space

hi everyone, i have a problem in unix script , i need to remove line that has blank , not blank line . example: mahm,,jdggkhsd,ghskj,,fshjkl can anyone help? (4 Replies)
Discussion started by: Reham.Donia
4 Replies

8. Shell Programming and Scripting

Not delete space blank

Hi everyone, i need to "grep" a file with a string with space blanks, like this: grep "XXXX XX" file.txt The problem, i need put the "XXXX XX" in a string variable. When the script executes the grep, do: gresp XXXX XX file.txt How can i solve this problem? The... (5 Replies)
Discussion started by: Xedrox
5 Replies

9. Shell Programming and Scripting

Removing blank space using VI

Hi, How to remove blank spaces using vi (I am using AIX)? #cat siva.txt AAA BBB CCC DDD EEE FFF Need to remove space between 2 columns. Regards, Siva (7 Replies)
Discussion started by: ksgnathan
7 Replies

10. Shell Programming and Scripting

Grep a string and count following lines starting with another string

I have a large dataset with following structure; C 0001 Carbon D SAR001 methane D SAR002 ethane D SAR003 propane D SAR004 butane D SAR005 pentane C 0002 Hydrogen C 0003 Nitrogen C 0004 Oxygen D SAR011 ozone D SAR012 super oxide C 0005 Sulphur D SAR013... (3 Replies)
Discussion started by: Syeda Sumayya
3 Replies
html2textrc(5)							File Formats Manual						    html2textrc(5)

NAME
html2textrc - formatting properties file for html2text(1) SYNOPSIS
Key [ = | : ] Value DESCRIPTION
The html2textrc(5) file defines a set of formatting properties used by the html2text(1) utility, that overrides the program's built-in for- matting defaults. Each line of the html2textrc(5) file is either a formatting property or a comment. Lines with a leading "#" or "!" (i.e. the first non-space character is a "#" or a "!") and blank lines (i.e. a line consisting only of white-space characters), are considered comments and ignored. Everything else is literary interpreted by the parser as a formatting prop- erty, where a string-type property value may also be empty (unsets default value). Both, the property key and the property value, may con- tain C-style escape sequences to mask meta characters. A property definition line consists of: (1) Optional leading space, (2) the property key (a sequence of non-space characters except "=" and ":") as described below, (3) an optional space, (4) an optional "=" or ":", (5) optional space, (6) the property value as described below. Everything up to the next newline is interpreted literary as the value of the specified element. Literary meant leading white-space must be quoted with backslashes (i.e. " "). Be aware not to include unwanted trailing white-space characters. OPTIONS
The following is the list of valid formatting properties, together with their default values. If the -style command line option of html2text(1) is used, different default values apply. Curly braces indicate alternatives, e.g. {A B}C stands for AC or BC. DOCUMENT.{vspace.{before after} indent.{left right}} = 0 Specifies how many blank lines are inserted before and after, and how many blank columns are inserted to the left and to the right of the formatted document. (Numeric.) BODY.{vspace.{before after} indent.{left right}} = 0 Same for the document body. (Since the document body is currently the only document part that is rendered, it is virtually the same whether you specifiy DOCUMENT or BODY). (Numeric.) {OL UL DIR MENU DL}.vspace.{before between after} = 0 Specifies how many blank lines are inserted before a list, between the individual list items, and after the list. (Numeric.) {OL UL DIR MENU}.indents = 6 Specifies by how deep list items are indented. If an item bullet would not fit into the space created by the indentation, then the indentation is automatically increased such that the bullet fits in (relevant for relatively wide bullets, e.g. roman numbers). If N blank-separated integers are specified instead of one, then the first N-1 integers specify indentation for the first N-1 list nesting levels, while the last integer specifies the indentation for nesting levels N and higher. (Numeric.) {UL DIR}.default_types = DISC CIRCLE SQUARE Specifies the default list type (i.e. the bullet style), if the HTML list tag does not specify an explicit type. Legal values are NO_BULLET, DISC, SQUARE, CIRCLE, CUSTOM1, CUSTOM2 and CUSTOM3. If more than one value is specified, then the values apply for the respective list nesting levels (see indents). (Option.) MENU.default_types = NO_BULLET Same for <MENU>, but here the default is NO_BULLET. (Option.) LI.{disc square circle custom1 custom2 custom3}_bullet = {* # o + - ~} Specifies the strings used as list item bullets. (String.) {DT DD}.{vspace.{before after} indent.{left right}} = 0 Specifies how many blank lines are inserted before and after, and how many blank columns are inserted to the left and to the right of each <DT> or <DD> element. (Numeric.) HR.marker = = Specifies the character to use for horizontal rules. (String.) HR.{vspace.{before after} indent.{left right}} = 0 Specifies how many blank lines are inserted before and after, and how many blank columns are inserted to the left and to the right of the horizontal rule. (Numeric.) {H1 H2 H3 H4 H5 H6}.prefix = {****** ***** **** *** ** *} Specifies how headings are decorated with a prefix. (The default values have a trailing blank, e.g. "****** ".) (String.) {H1 H2 H3 H4 H5 H6}.suffix = {****** ***** **** *** ** *} Specifies how headings are decorated with a suffix. (The default values have a leading blank, e.g. " ******".) (String.) {H1 H2 H3 H4 H5 H6}.vspace.{before after} = 0 Specifies how many blank lines are inserted before and after headings. (Numeric.) {PRE P}.{vspace.{before after} indent.{left right}} = 0 Specifies how many blank lines are inserted before and after, and how many blank columns are inserted to the left and to the right of these items. (Numeric.) {BLOCKQUOTE ADDRESS}.{vspace.{before after} indent.{left right}} = {0 0 5 5} Specifies how many blank lines are inserted before and after, and how many blank columns are inserted to the left and to the right of these items. (Numeric.) TABLE.vspace.{before after} = 0 Specifies how many blank lines are inserted before and after tables. (Numeric.) {H1 H2 H3 H4 H5 H6}.attributes = BOLD Specifies the cell attributes for headings. The value is a sequence of NONE, BOLD, UNDERLINE and STRIKETHROUGH. (Option.) {TT I BIG SMALL SUB SUP DFN CODE SAMP KBD CITE}.attributes = NONE Specifies the cell attributes for these text items. Legal values are: NONE, BOLD, UNDERLINE or STRIKETHROUGH. (Option.) U.attributes = UNDERLINE Same for <U> elements, but with a different default value. (Option.) {B EM STRONG}.attributes = BOLD Same for these elements, but with a different default value. (Option.) STRIKE.attributes = STRIKETHROUGH Same for <STRIKE> elements, but with a different default value. (Option.) A.attributes.{internal_link external_link} = UNDERLINE Specifies the cell attributes for links. A link is an <A> elemet that has an "HREF" attribute. An internal link is a link who's "HREF" attribute starts with a hash character (e.g. "<A href="#42">"). Legal values are again NONE, BOLD, UNDERLINE and STRIKETHROUGH. (Option.) IMG.replace.{all noalt} = unset Specifies the string used to replace all <IMG> elements, or those without an "ALT" attribute set. (String.) IMG.alt.{prefix suffix} = {[ ]} Specifies how the values (if any) of IMG elements' "ALT" attributes are marked. (String.) AUTHOR
Current maintainer and primary download location for html2text is: Martin Bayer <mbayer@zedat.fu-berlin.de> http://userpage.fu-berlin.de/~mbayer/tools/ <> SEE ALSO
html2text(1) 2001-06-11 html2textrc(5)
All times are GMT -4. The time now is 04:37 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy