uspTukubaiコマンドに関する様々な資料がここにあります。

 

 

魂内検索

DOCUMENTS

COMMAND

FORUM

UEC DOCS

VIDEO

 

Alphabetical list

(Video materials in preparation)

tagmrg

Name

tagmrg : Merge characters into a template

Synopsis

Usage   : tagmrg [-l<label>] <template> <tagdata>

Option  : -n<string>

          -s<c>

Version : Tue Oct 27 17:28:16 JST 2015

Edition : 1

Description

Merges fields from <tagdata> into the specified labels within

<template> one row at a time. When the pattern "###TagName###"

appears in the label, the value from <tagdata> with the same

tag name is inserted. If no label names are specified,

all data is merged with <template>.

Example 1

$ cat data

NO NAME AGE

01 boby 30

02 mary 25

03 corn 20

$ cat template

header

<!-- LABEL -->

<name="N_###NO###" value="###NAME####><name="A_###NO###" value="###AGE###">

<!-- LABEL -->

footer

$ tagmrg -lLABEL template data

header

<name="N_01" value="boby"><name="A_01" value="30">

<name="N_02" value="mary"><name="A_02" value="25">

<name="N_03" value="corn"><name="A_03" value="20">

footer

Example 2 When no label is specified

$ cat tagfile

CODE NAME DATE1

0002 sinjuku 0504

$ fcols screen

@           ###CODE###          @

@                    @ ###NAME###

###DATE1###          @          @

$ tagmrg screen tagfile | fcols

@       @ sinjuku

@    0002       @

0504    @       @

Note 1

By default, data fields equal to "@" are replaced with a null string.

You can change the default replacement character with the -d option.

Note 2

If you specify "-" as the file name, the command reads from standard input.

You can do this for <template> or for <tagdata>.