Added cpl_cli docs & moved cpl_cli/templates -> cpl_cli/_templates
This commit is contained in:
36
src/cpl_cli/_templates/build/init_template.py
Normal file
36
src/cpl_cli/_templates/build/init_template.py
Normal file
@@ -0,0 +1,36 @@
|
||||
import textwrap
|
||||
|
||||
|
||||
class InitTemplate:
|
||||
|
||||
@staticmethod
|
||||
def get_init_py() -> str:
|
||||
string = textwrap.dedent("""\
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
\"\"\"
|
||||
$Name $Description
|
||||
~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
$LongDescription
|
||||
|
||||
:copyright: (c) $CopyrightDate $CopyrightName
|
||||
:license: $LicenseDescription
|
||||
|
||||
\"\"\"
|
||||
|
||||
__title__ = '$Title'
|
||||
__author__ = '$Author'
|
||||
__license__ = '$LicenseName'
|
||||
__copyright__ = 'Copyright (c) $CopyrightDate $CopyrightName'
|
||||
__version__ = '$Version'
|
||||
|
||||
from collections import namedtuple
|
||||
|
||||
$Imports
|
||||
|
||||
VersionInfo = namedtuple('VersionInfo', 'major minor micro')
|
||||
version_info = VersionInfo(major='$Major', minor='$Minor', micro='$Micro')
|
||||
""")
|
||||
|
||||
return string
|
Reference in New Issue
Block a user