<?xml version="1.0" encoding="utf-8"?>
<xs:schema id="nuspec"
    targetNamespace="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"
    elementFormDefault="qualified"
    xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"
    xmlns:mstns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"
    xmlns:xs="http://www.w3.org/2001/XMLSchema"
>
    <xs:element name="package">
        <xs:complexType>
            <xs:sequence>
                <xs:element name="metadata" maxOccurs="1" minOccurs="1">
                    <xs:complexType>
                        <xs:all>
                            <xs:element name="id" maxOccurs="1" minOccurs="1" type="xs:string" />
                            <xs:element name="version" maxOccurs="1" minOccurs="1" type="xs:string" />
                            <xs:element name="title" maxOccurs="1" minOccurs="0" type="xs:string" />
                            <xs:element name="authors" maxOccurs="1" minOccurs="1" type="xs:string" />
                            <xs:element name="owners" maxOccurs="1" minOccurs="0" type="xs:string" />                            
                            <xs:element name="licenseUrl" maxOccurs="1" minOccurs="0" type="xs:anyURI" />                                
                            <xs:element name="projectUrl" maxOccurs="1" minOccurs="0" type="xs:anyURI" />                                
                            <xs:element name="iconUrl" maxOccurs="1" minOccurs="0" type="xs:anyURI" />                                
                            <xs:element name="requireLicenseAcceptance" maxOccurs="1" minOccurs="0" type="xs:boolean" />
                            <xs:element name="description" maxOccurs="1" minOccurs="1" type="xs:string" />
                            <xs:element name="summary" maxOccurs="1" minOccurs="0" type="xs:string" />
                            <xs:element name="language" maxOccurs="1" minOccurs="0" type="xs:string" default="en-US" />
                            <xs:element name="tags" maxOccurs="1" minOccurs="0" type="xs:string" />
                            <xs:element name="dependencies" maxOccurs="1" minOccurs="0">
                                <xs:complexType>
                                    <xs:sequence>
                                        <xs:element name="dependency" minOccurs="1" maxOccurs="unbounded">
                                            <xs:complexType>
                                                <xs:attribute name="id" type="xs:string" use="required" />
                                                <xs:attribute name="version" type="xs:string" use="optional" />
                                            </xs:complexType>
                                        </xs:element>
                                    </xs:sequence>
                                </xs:complexType>
                            </xs:element>
                        </xs:all>
                    </xs:complexType>
                </xs:element>                
                <xs:element name="files" minOccurs="0" maxOccurs="1">
                    <xs:complexType>
                        <xs:sequence>
                            <xs:element name="file" minOccurs="1" maxOccurs="unbounded">
                                <xs:complexType>
                                    <xs:attribute name="src" use="required" type="xs:string" />
                                    <xs:attribute name="target" use="optional" type="xs:string" />
                                </xs:complexType>
                            </xs:element>
                        </xs:sequence>
                    </xs:complexType>
                </xs:element>
            </xs:sequence>
        </xs:complexType>
    </xs:element>
</xs:schema>
