File: tovek.awk

package info (click to toggle)
magyarispell 0.99.4-1.1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 3,988 kB
  • ctags: 132
  • sloc: sh: 883; awk: 337; makefile: 240
file content (24 lines) | stat: -rw-r--r-- 458 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#
# tvek felvtele kivtelekhez a kivetelek knyvtrbl
#
/	/ {
    c = index($1, "/");
    if (c == 0) {
	print $1 "/0g" param
	if ($3 == "") {
	    print "__" $1 "/" $2
	} else {
	    print "__" $1 "/" $2 " " $3
	}
    } else {    
	print substr($1, 1, c-1) "/0g" substr($1, c) param
	if ($3 == "") {
	    print "__" substr($1, 1, c-1) "/" $2
	} else {
	    print "__" substr($1, 1, c-1) "/" $2 " " $3
	}
    }
    next
}
/^$/ { next }
{ print $1 param }