- 论坛徽章:
- 145
|
回复 1# jiawei2426
$ awk '/^)/{add=0}/^[\t ]*[(](bottom|left)/{add=($1=="(left")?0.5:100}add{if(match($0,"offset=([^ ]+)",a)){sub(a[1],sprintf("%.4f",a[1]+add))}}1' FILE
(globals
version = 3
io_order = default
)
(iopin
(bottom
(pin name="COE" offset=122.0000 layer=4 width=0.2000 depth=0.6000 place_status=fixed )
(pin name="MOON" offset=126.0000 layer=4 width=0.2000 depth=0.6000 place_status=fixed )
(pin name="TYPE" offset=130.0000 layer=4 width=0.2000 depth=0.6000 place_status=fixed )
)
(left
(pin name="AMB" offset=22.5000 layer=3 width=0.2000 depth=0.6000 place_status=fixed )
(pin name="END" offset=26.5000 layer=3 width=0.2000 depth=0.6000 place_status=fixed )
(pin name="TOU" offset=30.5000 layer=3 width=0.2000 depth=0.6000 place_status=fixed )
)
|
|