equal
deleted
inserted
replaced
57 "http://www.w3.org/2000/svg" |
57 "http://www.w3.org/2000/svg" |
58 "http://www.w3.org/2005/Atom" |
58 "http://www.w3.org/2005/Atom" |
59 "http://docbook.org/ns/docbook" |
59 "http://docbook.org/ns/docbook" |
60 ) |
60 ) |
61 |
61 |
|
62 # TODO: introspection: after moving to alt2xml the available options and their values should be provided by the parser |
|
63 |
|
64 PARSER_OPTIONS=( |
|
65 "root-name" |
|
66 ); |
|
67 |
62 |
68 |
63 if [[ "$w1" == "--relation" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
69 if [[ "$w1" == "--relation" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
64 elif [[ "$w1" == "--records" && "x$w0" == "x" ]]; then COMPREPLY=("'/'") |
70 elif [[ "$w1" == "--records" && "x$w0" == "x" ]]; then COMPREPLY=("'/'") |
65 elif [[ "$w1" == "--attribute" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
71 elif [[ "$w1" == "--attribute" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
66 elif [[ "$w2" == "--attribute" ]]; then COMPREPLY=($(compgen -W "${DATA_TYPE[*]}" -- "$w0")) |
72 elif [[ "$w2" == "--attribute" ]]; then COMPREPLY=($(compgen -W "${DATA_TYPE[*]}" -- "$w0")) |
75 |
81 |
76 elif [[ "$w1" == "--raw-xml-attribute-wrapper" ]]; then COMPREPLY=("'attribute'") |
82 elif [[ "$w1" == "--raw-xml-attribute-wrapper" ]]; then COMPREPLY=("'attribute'") |
77 elif [[ "$w2" == "--raw-xml-attribute-wrapper" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
83 elif [[ "$w2" == "--raw-xml-attribute-wrapper" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
78 elif [[ "$w3" == "--raw-xml-attribute-wrapper" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
84 elif [[ "$w3" == "--raw-xml-attribute-wrapper" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
79 |
85 |
80 elif [[ "$w1" == "--parser-option" ]]; then COMPREPLY=("''") |
86 elif [[ "$w1" == "--parser-option" ]]; then COMPREPLY=($(compgen -W "${PARSER_OPTIONS[*]}" -- "$w0")) |
81 elif [[ "$w2" == "--parser-option" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
87 elif [[ "$w2" == "--parser-option" && "x$w0" == "x" ]]; then COMPREPLY=("''") |
82 |
88 |
83 else |
89 else |
84 OPTIONS=( |
90 OPTIONS=( |
85 "--namespace" |
91 "--namespace" |
86 "--parser-option" |
92 "--parser-option" |