summaryrefslogtreecommitdiff
path: root/src-3.0/GF/Command/Commands.hs
diff options
context:
space:
mode:
authoraarne <aarne@cs.chalmers.se>2008-06-18 09:14:31 +0000
committeraarne <aarne@cs.chalmers.se>2008-06-18 09:14:31 +0000
commit8e5b78f886065d082677101b28c44d7980763eb0 (patch)
tree1573210ce78564d167b5a28cf65578263966c310 /src-3.0/GF/Command/Commands.hs
parent0f21f8f3436d732838dc76da0c1005eb332961ff (diff)
term macro help
Diffstat (limited to 'src-3.0/GF/Command/Commands.hs')
-rw-r--r--src-3.0/GF/Command/Commands.hs11
1 files changed, 9 insertions, 2 deletions
diff --git a/src-3.0/GF/Command/Commands.hs b/src-3.0/GF/Command/Commands.hs
index 6fd4a1fb2..7441e6fb5 100644
--- a/src-3.0/GF/Command/Commands.hs
+++ b/src-3.0/GF/Command/Commands.hs
@@ -114,14 +114,21 @@ allCommands pgf = Map.fromList [
}),
("dt", emptyCommandInfo {
longname = "define_tree",
- syntax = "dt IDENT (TREE | STRING)", -- | '<' COMMANDLINE)",
+ syntax = "dt IDENT (TREE | STRING | \"<\" COMMANDLINE)",
synopsis = "define a tree or string macro",
explanation = unlines [
"Defines IDENT as macro for TREE or STRING, until IDENT gets redefined.",
- -- "The defining value can also come from a command, preceded by '<'.",
+ "The defining value can also come from a command, preceded by \"<\".",
+ "If the command gives many values, the first one is selected.",
"A use of the macro has the form %IDENT. Currently this use cannot be",
"a subtree of another tree. This command must be a line of its own",
"and thus cannot be a part of a pipe."
+ ],
+ examples = [
+ ("dt ex \"hello world\" -- define ex as string"),
+ ("dt ex UseN man_N -- define ex as string"),
+ ("dt ex < p -cat=NP \"the man in the car\" -- define ex as parse result"),
+ ("l -lang=LangSwe %ex | ps -to_utf8 -- linearize the tree ex")
]
}),
("e", emptyCommandInfo {