Lines Matching refs:SCHEMA
26 Usage: $0 output.xml xml-schema [type [os zip[:dest]]*...]*
28 - schema is one of 'repository' or 'addon'
48 # Get the schema type. Must be either "repository" or "addon".
49 SCHEMA="$1"
50 [[ ! -f "$SCHEMA" ]] && error "Invalid XML schema name: $SCHEMA."
53 # Get XML:NS for SDK from the schema
55 XMLNS=$(sed -n '/xmlns:sdk="/s/.*"\(.*\)".*/\1/p' "$SCHEMA")
56 [[ -z "$XMLNS" ]] && error "Failed to find xmlns:sdk in $SCHEMA."
59 # Extract the schema version number from the XMLNS, e.g. it would extract "3"
62 # Get the root element from the schema. This is the first element
64 ROOT=$(sed -n -e '/xsd:element.*name="sdk-/s/.*name="\(sdk-[^"]*\)".*/\1/p' "$SCHEMA")
65 [[ -z "$ROOT" ]] && error "Failed to find root element in $SCHEMA."
144 # this in this script. Instead schema validation will fail if the extra
231 # ignore things which are too *new* for this schema. This lets
344 # XML validation against the schema will be done at the end.
416 echo "## Validate XML against schema"
417 xmllint --schema $SCHEMA "$OUT"