Ejemplo n.º 1
0
    def _create_docs(self, author, description, license_name):

        with open("README.md", "a") as readme:
            readme.write(readme_md.src(self._project_name, description))

        with open("LICENSE", "w") as doc:
            if [doc for doc in ["mit", "MIT"] if doc in license_name]:
                doc.write(licenses.mit.src(self._get_current, author))

            elif [
                    doc for doc in ["agpl", "AGPL", "AGPLv3"]
                    if doc in license_name
            ]:
                doc.write(licenses.agpl_v3.src(self._get_current, author))

            elif [
                    doc for doc in ["apache", "Apache", "Apache2"]
                    if doc in license_name
            ]:
                doc.write(licenses.apache_v2.src(self._get_current, author))

            elif [
                    doc for doc in ["gpl", "GPL", "GPLv3"]
                    if doc in license_name
            ]:
                doc.write(licenses.gpl_v3.src(self._get_current, author))

            elif [
                    doc for doc in ["lgpl", "LGPL", "LGPLv3"]
                    if doc in license_name
            ]:
                doc.write(licenses.lgpl_v3.src(self._get_current, author))

            elif [
                    doc for doc in ["mpl", "MPL", "MPLv2"]
                    if doc in license_name
            ]:
                doc.write(licenses.mpl_v2.src(self._get_current, author))

            elif [
                    doc for doc in ["unlicense", "Unlicense"]
                    if doc in license_name
            ]:
                doc.write(licenses.unlicense.src(self._get_current, author))
Ejemplo n.º 2
0
 def _create_docs(self):
     with open("README.md", "a") as readme:
         readme.write(readme_md.src(self._project_name))
Ejemplo n.º 3
0
    def _create_docs(self, author, description, license_name):

        with open("README.md", "a") as readme:
            readme.write(readme_md.src(self._project_name, description))
Ejemplo n.º 4
0
 def _create_docs(self, name):
     with open("README.md", "a") as readme:
         readme.write(readme_md.src(name))