parent
23563b48b4
commit
a710e228ab
30 changed files with 1903 additions and 894 deletions
@ -1,440 +0,0 @@ |
|||||||
apache.disable_module |
|
||||||
..................... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[disable an apache module] |
|
||||||
apache.disable_module = module_name |
|
||||||
|
|
||||||
apache.disable_site |
|
||||||
................... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[disable a virtual host] |
|
||||||
apache.disable_site = domain_name |
|
||||||
|
|
||||||
apache.enable_module |
|
||||||
.................... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[enable an apache module] |
|
||||||
apache.enable_module = module_name |
|
||||||
|
|
||||||
apache.enable_site |
|
||||||
.................. |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[enable a virtual host] |
|
||||||
apache.enable_site = domain_name |
|
||||||
|
|
||||||
apache.test |
|
||||||
........... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[run an apache config test] |
|
||||||
apache: test |
|
||||||
|
|
||||||
append |
|
||||||
...... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[append to a file] |
|
||||||
append = path |
|
||||||
content = None |
|
||||||
|
|
||||||
archive |
|
||||||
....... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[create an archive file] |
|
||||||
archive = from_path |
|
||||||
absolute = False |
|
||||||
exclude = None |
|
||||||
file_name = archive.tgz |
|
||||||
strip = 0 |
|
||||||
to_path = . |
|
||||||
view = False |
|
||||||
|
|
||||||
certbot |
|
||||||
....... |
|
||||||
|
|
||||||
Alias: ssl |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[get new ssl certificate from let's encrypt] |
|
||||||
certbot = domain_name |
|
||||||
email = None |
|
||||||
webroot = None |
|
||||||
|
|
||||||
copy |
|
||||||
.... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[copy a file or directory] |
|
||||||
copy = from_path to_path |
|
||||||
overwrite = False |
|
||||||
recursive = False |
|
||||||
|
|
||||||
django |
|
||||||
...... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[run a django management command] |
|
||||||
django = name |
|
||||||
|
|
||||||
django.dumpdata |
|
||||||
............... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[export django fixtures] |
|
||||||
django.dumpdata = app_name |
|
||||||
file_name = initial |
|
||||||
indent = 4 |
|
||||||
natural_foreign = False |
|
||||||
natural_primary = False |
|
||||||
path = None |
|
||||||
|
|
||||||
django.loaddata |
|
||||||
............... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[load django fixtures] |
|
||||||
django.loaddata = app_name |
|
||||||
file_name = initial |
|
||||||
path = None |
|
||||||
|
|
||||||
extract |
|
||||||
....... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[extract an archive] |
|
||||||
extract = from_path |
|
||||||
absolute = False |
|
||||||
exclude = None |
|
||||||
file_name = archive.tgz |
|
||||||
strip = 0 |
|
||||||
to_path = None |
|
||||||
view = False |
|
||||||
|
|
||||||
install |
|
||||||
....... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[install a package using apt-get] |
|
||||||
apt = package |
|
||||||
remove = False |
|
||||||
|
|
||||||
makedir |
|
||||||
....... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[create a directory] |
|
||||||
makedir = path |
|
||||||
mode = None |
|
||||||
recursive = True |
|
||||||
|
|
||||||
message |
|
||||||
....... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[run a message command] |
|
||||||
message = output |
|
||||||
back_title = Message |
|
||||||
dialog = False |
|
||||||
height = 15 |
|
||||||
width = 100 |
|
||||||
|
|
||||||
mkdir |
|
||||||
..... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[create a directory] |
|
||||||
mkdir = path |
|
||||||
mode = None |
|
||||||
recursive = True |
|
||||||
|
|
||||||
move |
|
||||||
.... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[move a file or directory] |
|
||||||
move = from_path to_path |
|
||||||
|
|
||||||
perms |
|
||||||
..... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[set permissions on a file or directory] |
|
||||||
perms = path |
|
||||||
group = None |
|
||||||
mode = None |
|
||||||
owner = None |
|
||||||
recursive = False |
|
||||||
|
|
||||||
pg.createdb |
|
||||||
........... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[create a postgresql database] |
|
||||||
pg.createdb = name |
|
||||||
admin_pass = None |
|
||||||
admin_user = postgres |
|
||||||
host = localhost |
|
||||||
owner = None |
|
||||||
port = 5432 |
|
||||||
template = None |
|
||||||
|
|
||||||
pg.createuser |
|
||||||
............. |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[create a postgresql user] |
|
||||||
pg.createuser = name |
|
||||||
admin_pass = None |
|
||||||
admin_user = postgres |
|
||||||
host = localhost |
|
||||||
password = None |
|
||||||
port = 5432 |
|
||||||
|
|
||||||
pg.db |
|
||||||
..... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[create a postgresql database] |
|
||||||
pg.db = name |
|
||||||
admin_pass = None |
|
||||||
admin_user = postgres |
|
||||||
host = localhost |
|
||||||
owner = None |
|
||||||
port = 5432 |
|
||||||
template = None |
|
||||||
|
|
||||||
pg.dropdb |
|
||||||
......... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[remove a postgresql database] |
|
||||||
pg.dropdb = name |
|
||||||
admin_pass = None |
|
||||||
admin_user = postgres |
|
||||||
host = localhost |
|
||||||
port = 5432 |
|
||||||
|
|
||||||
pg.dropuser |
|
||||||
........... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[remove a postgres user] |
|
||||||
pg.dropuser = name |
|
||||||
admin_pass = None |
|
||||||
admin_user = postgres |
|
||||||
host = localhost |
|
||||||
port = 5432 |
|
||||||
|
|
||||||
pg.dump |
|
||||||
....... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[export a postgres database] |
|
||||||
pg.dump = name |
|
||||||
admin_pass = None |
|
||||||
admin_user = postgres |
|
||||||
file_name = None |
|
||||||
host = localhost |
|
||||||
port = 5432 |
|
||||||
|
|
||||||
pg.exists |
|
||||||
......... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[determine if a postgres database exists] |
|
||||||
pg.exists = name |
|
||||||
admin_pass = None |
|
||||||
admin_user = postgres |
|
||||||
host = localhost |
|
||||||
port = 5432 |
|
||||||
|
|
||||||
pip |
|
||||||
... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[install a python package using pip] |
|
||||||
pip = package |
|
||||||
remove = False |
|
||||||
upgrade = False |
|
||||||
|
|
||||||
psql |
|
||||||
.... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[execute a psql command] |
|
||||||
psql = sql |
|
||||||
database = template1 |
|
||||||
host = localhost |
|
||||||
password = None |
|
||||||
port = 5432 |
|
||||||
user = postgres |
|
||||||
|
|
||||||
reload |
|
||||||
...... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[reload a service] |
|
||||||
reload = service |
|
||||||
|
|
||||||
remove |
|
||||||
...... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[remove a file or directory] |
|
||||||
remove = path |
|
||||||
force = False |
|
||||||
recursive = False |
|
||||||
|
|
||||||
restart |
|
||||||
....... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[restart a service] |
|
||||||
restart = service |
|
||||||
|
|
||||||
rsync |
|
||||||
..... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[synchronize files from a local to remote directory] |
|
||||||
rsync = source target |
|
||||||
delete = False |
|
||||||
guess = False |
|
||||||
host = None |
|
||||||
key_file = None |
|
||||||
links = True |
|
||||||
port = 22 |
|
||||||
recursive = True |
|
||||||
user = None |
|
||||||
|
|
||||||
run |
|
||||||
... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[a command to be executed] |
|
||||||
run = statement |
|
||||||
comment = None |
|
||||||
condition = None |
|
||||||
cd = None |
|
||||||
environments = None |
|
||||||
function = None |
|
||||||
prefix = None |
|
||||||
register = None |
|
||||||
shell = None |
|
||||||
stop = False |
|
||||||
sudo = None |
|
||||||
tags = None |
|
||||||
|
|
||||||
scopy |
|
||||||
..... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[copy a file from the local (machine) to the remote host] |
|
||||||
scp = from_path to_path |
|
||||||
host = None |
|
||||||
key_file = None |
|
||||||
port = 22 |
|
||||||
user = None |
|
||||||
|
|
||||||
sed |
|
||||||
... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[replace text in a file] |
|
||||||
sed = path |
|
||||||
backup = .b |
|
||||||
change = None |
|
||||||
delimiter = / |
|
||||||
find = None |
|
||||||
|
|
||||||
start |
|
||||||
..... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[start a service] |
|
||||||
start = service |
|
||||||
|
|
||||||
stop |
|
||||||
.... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[stop a service] |
|
||||||
stop = service |
|
||||||
|
|
||||||
symlink |
|
||||||
....... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[create a symlink] |
|
||||||
symlink = source |
|
||||||
force = False |
|
||||||
target = None |
|
||||||
|
|
||||||
touch |
|
||||||
..... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[touch a file or directory] |
|
||||||
touch = path |
|
||||||
|
|
||||||
virtualenv |
|
||||||
.......... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[create a python virtual environment] |
|
||||||
virtualenv = name |
|
||||||
|
|
||||||
write |
|
||||||
..... |
|
||||||
|
|
||||||
.. code-block:: ini |
|
||||||
|
|
||||||
[write to a file] |
|
||||||
write = path |
|
||||||
content = None |
|
||||||
overwrite = False |
|
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,17 @@ |
|||||||
|
Requirements |
||||||
|
------------ |
||||||
|
|
||||||
|
superpython |
||||||
|
----------- |
||||||
|
|
||||||
|
|
||||||
|
**URLs** |
||||||
|
|
||||||
|
- `Source Code <https://github.com/develmaycare/superpython>`_ |
||||||
|
|
||||||
|
**Install** |
||||||
|
|
||||||
|
.. code-block:: bash |
||||||
|
|
||||||
|
pip install git+https://github.com/develmaycare/superpython; |
||||||
|
|
@ -0,0 +1,39 @@ |
|||||||
|
.. _commands: |
||||||
|
|
||||||
|
******** |
||||||
|
Commands |
||||||
|
******** |
||||||
|
|
||||||
|
.. code-block:: text |
||||||
|
|
||||||
|
usage: tease [-h] [-c] [-C= VARIABLES] [-d] [-D] [-f= FILTERS] [-O= OPTIONS] [-s] [-T= TEMPLATE_LOCATIONS] [-w= OUTPUT_FILE] [-V= VARIABLES_FILE] |
||||||
|
[-v] [--version] |
||||||
|
[path] |
||||||
|
|
||||||
|
positional arguments: |
||||||
|
path The path to the configuration file. |
||||||
|
|
||||||
|
optional arguments: |
||||||
|
-h, --help show this help message and exit |
||||||
|
-c, --color Enable code highlighting for terminal output. |
||||||
|
-C= VARIABLES, --context= VARIABLES |
||||||
|
Context variables for use in pre-parsing the config and templates. In the form of: name:value |
||||||
|
-d, --docs Output documentation instead of code. |
||||||
|
-D, --debug Enable debug output. |
||||||
|
-f= FILTERS, --filter= FILTERS |
||||||
|
Filter the commands in the form of: attribute:value |
||||||
|
-O= OPTIONS, --option= OPTIONS |
||||||
|
Common command options in the form of: name:value |
||||||
|
-s, --script Output commands as a script. |
||||||
|
-T= TEMPLATE_LOCATIONS, --template-path= TEMPLATE_LOCATIONS |
||||||
|
The location of template files that may be used with the template command. |
||||||
|
-w= OUTPUT_FILE, --write= OUTPUT_FILE |
||||||
|
Write the output to disk. |
||||||
|
-V= VARIABLES_FILE, --variables-file= VARIABLES_FILE |
||||||
|
Load variables from a file. |
||||||
|
-v Show version number and exit. |
||||||
|
--version Show verbose version information and exit. |
||||||
|
|
||||||
|
NOTES |
||||||
|
|
||||||
|
This command is used to parse configuration files and output the commands. |
@ -0,0 +1,27 @@ |
|||||||
|
.. _contact: |
||||||
|
|
||||||
|
******* |
||||||
|
Contact |
||||||
|
******* |
||||||
|
|
||||||
|
General Contact |
||||||
|
=============== |
||||||
|
|
||||||
|
Please use the `contact form at develmaycare.com`_ to inquire about training, commercial development or support, to |
||||||
|
report security issues, and other questions or communications. |
||||||
|
|
||||||
|
.. _contact form at develmaycare.com: https://develmaycare.com/contact/?product=ScriptTease |
||||||
|
|
||||||
|
Issue Tracker |
||||||
|
============= |
||||||
|
|
||||||
|
Bugs and feature requests are logged with the `issue tracker`_. Do *not* log security issues here. |
||||||
|
|
||||||
|
.. _issue tracker: https://github.com/develmaycare/python-scripttease/issues |
||||||
|
|
||||||
|
Support |
||||||
|
======= |
||||||
|
|
||||||
|
Support inquiries and other questions may be answered on StackOverflow `using the python-scripttease tag`_. |
||||||
|
|
||||||
|
.. _using the python-scripttease tag: https://stackoverflow.com/questions/tagged/python-scripttease |
@ -0,0 +1,47 @@ |
|||||||
|
.. _getting-started: |
||||||
|
|
||||||
|
*************** |
||||||
|
Getting Started |
||||||
|
*************** |
||||||
|
|
||||||
|
System Requirements |
||||||
|
=================== |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
Install |
||||||
|
======= |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
Configuration |
||||||
|
============= |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
Examples |
||||||
|
======== |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
Next Steps |
||||||
|
========== |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
Resources |
||||||
|
========= |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
FAQs |
||||||
|
==== |
||||||
|
|
||||||
|
**Question?** |
||||||
|
|
||||||
|
Answer. |
||||||
|
|
||||||
|
Have a question? `Just ask`_! |
||||||
|
|
||||||
|
.. _Just ask: https://{{ project_domain }}/contact |
||||||
|
|
@ -0,0 +1,110 @@ |
|||||||
|
.. _how-to: |
||||||
|
|
||||||
|
****** |
||||||
|
How To |
||||||
|
****** |
||||||
|
|
||||||
|
Create a New Command Overlay |
||||||
|
============================ |
||||||
|
|
||||||
|
:ref:`topics-overlays` are used to define the commands supported by a given application, service, or operating system. Commands are defined as a function. |
||||||
|
|
||||||
|
1) Define a Module |
||||||
|
------------------ |
||||||
|
|
||||||
|
The first step is to create a new module in which functions will be defined. |
||||||
|
|
||||||
|
.. code-block:: python |
||||||
|
|
||||||
|
# module_name.py |
||||||
|
from ..commands import Command |
||||||
|
|
||||||
|
For overlays that represent an operating system, the ``command_exists()`` function is required: |
||||||
|
|
||||||
|
.. code-block:: python |
||||||
|
|
||||||
|
def command_exists(name): |
||||||
|
return name in MAPPINGS |
||||||
|
|
||||||
|
|
||||||
|
2) Define Command Function |
||||||
|
-------------------------- |
||||||
|
|
||||||
|
The purpose of each function is to provide an interface for instantiating a :py:class`scripttease.library.commands.base.Command` instance. The example below is taken from the ``posix`` module. |
||||||
|
|
||||||
|
.. code-block:: python |
||||||
|
|
||||||
|
# module_name.py |
||||||
|
# ... |
||||||
|
|
||||||
|
def mkdir(path, mode=None, recursive=True, **kwargs): |
||||||
|
"""Create a directory. |
||||||
|
|
||||||
|
- path (str): The path to be created. |
||||||
|
- mode (int | str): The access permissions of the new directory. |
||||||
|
- recursive (bool): Create all directories along the path. |
||||||
|
|
||||||
|
""" |
||||||
|
kwargs.setdefault("comment", "create directory %s" % path) |
||||||
|
|
||||||
|
statement = ["mkdir"] |
||||||
|
if mode is not None: |
||||||
|
statement.append("-m %s" % mode) |
||||||
|
|
||||||
|
if recursive: |
||||||
|
statement.append("-p") |
||||||
|
|
||||||
|
statement.append(path) |
||||||
|
|
||||||
|
return Command(" ".join(statement), **kwargs) |
||||||
|
|
||||||
|
The arguments and any specific keyword arguments are automatically used by the parser, but also serve as a simple interface for programmatic use. |
||||||
|
|
||||||
|
Each function *must* also accept ``**kwargs`` and should set a default for ``comment`` as above. |
||||||
|
|
||||||
|
3) Add Functions to the Mapping |
||||||
|
------------------------------- |
||||||
|
|
||||||
|
The final step adds the function to the mapping. This makes it available to the command factory. |
||||||
|
|
||||||
|
.. code-block:: python |
||||||
|
|
||||||
|
# module_name.py |
||||||
|
# ... |
||||||
|
|
||||||
|
MAPPINGS = { |
||||||
|
'mkdir': mkdir, |
||||||
|
} |
||||||
|
|
||||||
|
For overlays that represent an operating system, ``MAPPINGS`` is required -- in addition to ``command_exists()`` above. For commands that are specific to service or application, the name of the dictionary may be anything that is appropriate. For example, ``DJANGO_MAPPINGS``. |
||||||
|
|
||||||
|
Additionally, for an operating system overlay, you may wish to import other mappings and incorporate them into ``MAPPINGS``. |
||||||
|
|
||||||
|
.. code-block:: python |
||||||
|
|
||||||
|
# module_name.py |
||||||
|
from ..commands import Command |
||||||
|
from .common import COMMON_MAPPINGS |
||||||
|
from .django import DJANGO_MAPPINGS |
||||||
|
from .pgsql import PGSQL_MAPPINGS |
||||||
|
|
||||||
|
MAPPINGS = { |
||||||
|
# ... |
||||||
|
} |
||||||
|
|
||||||
|
MAPPINGS.update(COMMON_MAPPINGS) |
||||||
|
MAPPINGS.update(DJANGO_MAPPINGS) |
||||||
|
MAPPINGS.update(PGSQL_MAPPINGS) |
||||||
|
|
||||||
|
Export Commands as a Script |
||||||
|
=========================== |
||||||
|
|
||||||
|
.. code-block:: python |
||||||
|
|
||||||
|
config = Config("commands.ini") |
||||||
|
if not config.load(): |
||||||
|
print("Bummer!") |
||||||
|
exit() |
||||||
|
|
||||||
|
script = config.as_script() |
||||||
|
print(script) |
@ -0,0 +1,155 @@ |
|||||||
|
******* |
||||||
|
Project |
||||||
|
******* |
||||||
|
|
||||||
|
Contributing |
||||||
|
============ |
||||||
|
|
||||||
|
We welcome contributions to this and any of `our open source projects`_. There are a number of ways to participate and contribute. See :ref:`contact`. |
||||||
|
|
||||||
|
.. _our open source projects: https://develmaycare.com/products/ |
||||||
|
|
||||||
|
Reporting Issues |
||||||
|
---------------- |
||||||
|
|
||||||
|
Perhaps the easiest way to contribute is to submit an issue. If you have found a bug or error in the documentation, please submit a request. See :ref:`contact`. |
||||||
|
|
||||||
|
.. important:: |
||||||
|
Do **not** report security issues using the issue tracker. Instead, send an email to security@develmaycare.com with details on the issue you've discovered. |
||||||
|
|
||||||
|
Submitting Feature Requests |
||||||
|
--------------------------- |
||||||
|
|
||||||
|
Although we reserve the right to decline new features, we welcome all feature requests. See :ref:`contact`. |
||||||
|
|
||||||
|
Testing and Quality Control |
||||||
|
--------------------------- |
||||||
|
|
||||||
|
Testing involves using Script Tease in real life or in development. Feel free to report any issues you find, or to improve the unit tests. |
||||||
|
|
||||||
|
Pull Requests |
||||||
|
------------- |
||||||
|
|
||||||
|
Pull requests are welcome. Such requests should be associated with an issue. We may ignore pull requests that do not have a corresponding issue, so create an issue if one does not already exist. |
||||||
|
|
||||||
|
Translations |
||||||
|
------------ |
||||||
|
|
||||||
|
TODO: Translations help make Script Tease available to more people around the world. |
||||||
|
|
||||||
|
Blogging |
||||||
|
-------- |
||||||
|
|
||||||
|
You may help spread awareness of Script Tease by writing blog posts. We are happy to link out to reviews and tutorials from our web site. `Let us know if you've created a blog post`_ that we can share. Be sure to include a link to the post. |
||||||
|
|
||||||
|
You may also provide us with a guest post to be included on our blog. |
||||||
|
|
||||||
|
.. _Let us know if you've created a blog post: https://develmaycare.com/contact/?product=ScriptTease |
||||||
|
|
||||||
|
.. note:: |
||||||
|
We reserve the right to proof and approve or decline all content posted on our web site. |
||||||
|
|
||||||
|
Development |
||||||
|
=========== |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
Setting Up For Development |
||||||
|
-------------------------- |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
Style Guide |
||||||
|
----------- |
||||||
|
|
||||||
|
Script Tease follows `PEP8`_ and (where appropriate) the `Django style guide`_ and `JavaScript Standard Style`_. |
||||||
|
|
||||||
|
.. _Django style guide: https://docs.djangoproject.com/en/stable/internals/contributing/writing-code/coding-style/ |
||||||
|
.. _JavaScript Standard Style: https://standardjs.com |
||||||
|
.. _PEP8: https://www.python.org/dev/peps/pep-0008/ |
||||||
|
|
||||||
|
We *do* make a few exceptions and provide additional guidance which is documented in our `developer docs`_. |
||||||
|
|
||||||
|
.. _developer docs: https://docs.develmaycare.com/en/developer/ |
||||||
|
|
||||||
|
Tips for Successful Development |
||||||
|
------------------------------- |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
Getting Help |
||||||
|
------------ |
||||||
|
|
||||||
|
TODO |
||||||
|
|
||||||
|
Dependencies |
||||||
|
============ |
||||||
|
|
||||||
|
.. include:: _includes/project-dependencies.rst |
||||||
|
|
||||||
|
Tests |
||||||
|
===== |
||||||
|
|
||||||
|
.. include:: _includes/project-tests.rst |
||||||
|
|
||||||
|
Releasing |
||||||
|
========= |
||||||
|
|
||||||
|
Versioning |
||||||
|
---------- |
||||||
|
|
||||||
|
Script Tease follows a loose form of `semantic versioning`_. The use of semantic versioning makes it clear when deprecation occurs and backward compatibility is removed. Documented incompatibilities may still exist where deprecation is not feasible (technically or financially). |
||||||
|
|
||||||
|
.. _semantic versioning: https://semver.org/ |
||||||
|
|
||||||
|
Cadence |
||||||
|
------- |
||||||
|
|
||||||
|
Prior to the 1.0 release, new features may be released at any time. After the 1.0 release, new features are planned for release every 3 months. Patch-level changes (to fix bugs or security issues) are always released as needed. |
||||||
|
|
||||||
|
Long-Term Support |
||||||
|
----------------- |
||||||
|
|
||||||
|
Some releases may be designated as long-term support (LTS) releases. Such releases will have security and critical bug fixes applied for 6 months. |
||||||
|
|
||||||
|
Deprecation Policy |
||||||
|
------------------ |
||||||
|
|
||||||
|
Minor releases may deprecate features from a previous minor release. For example, if a feature is deprecated in release 1.1, it will continue to work in the 1.2 release, though warnings may be raised. However, the deprecated feature may be removed in release 1.3 and may not function as previously expected or will raise errors. |
||||||
|
|
||||||
|
Major releases may *always* remove deprecated features. |
||||||
|
|
||||||
|
Patch-level releases *never* remove deprecated features. |
||||||
|
|
||||||
|
Legal |
||||||
|
===== |
||||||
|
|
||||||
|
.. code-block:: text |
||||||
|
|
||||||
|
Copyright (c) Pleasant Tents, LLC |
||||||
|
|
||||||
|
All rights reserved. |
||||||
|
|
||||||
|
Redistribution and use in source and binary forms, with or without modification, |
||||||
|
are permitted provided that the following conditions are met: |
||||||
|
|
||||||
|
* Redistributions of source code must retain the above copyright notice, |
||||||
|
this list of conditions and the following disclaimer. |
||||||
|
* Redistributions in binary form must reproduce the above copyright notice, |
||||||
|
this list of conditions and the following disclaimer in the documentation |
||||||
|
and/or other materials provided with the distribution. |
||||||
|
* Neither the name of Pleasant Tents, LLC nor the names of its contributors |
||||||
|
may be used to endorse or promote products derived from this software |
||||||
|
without specific prior written permission. |
||||||
|
|
||||||
|
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS |
||||||
|
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT |
||||||
|
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR |
||||||
|
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR |
||||||
|
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, |
||||||
|
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, |
||||||
|
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR |
||||||
|
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF |
||||||
|
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING |
||||||
|
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
||||||
|
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
@ -0,0 +1,22 @@ |
|||||||
|
.. _topics-overlays: |
||||||
|
|
||||||
|
******* |
||||||
|
Overlay |
||||||
|
******* |
||||||
|
|
||||||
|
An overlay is a collection of functions that provide an interface to command creation. |
||||||
|
|
||||||
|
There are currently three (3) general and re-usable overlays: |
||||||
|
|
||||||
|
- common |
||||||
|
- django |
||||||
|
- pgsql |
||||||
|
|
||||||
|
And two (2) overlays that are specific to operating systems: |
||||||
|
|
||||||
|
- posix |
||||||
|
- ubuntu |
||||||
|
|
||||||
|
The examples that follow instantiate command instances from an INI file. Each example is shown with the defaults. All commands support a number of :ref:`topics-configuration-common-parameters`. |
||||||
|
|
||||||
|
.. include:: _includes/overlays.rst |
@ -0,0 +1,11 @@ |
|||||||
|
.. _topics: |
||||||
|
|
||||||
|
****** |
||||||
|
Topics |
||||||
|
****** |
||||||
|
|
||||||
|
.. toctree:: |
||||||
|
:maxdepth: 2 |
||||||
|
|
||||||
|
Configuration <topics-configuration> |
||||||
|
Overlays <topics-overlays> |
@ -0,0 +1,5 @@ |
|||||||
|
; SuperPython already has many of the required dependencies, including jinja2 and pygments. |
||||||
|
[superpython] |
||||||
|
comment = Used throughout for its various components and utilities. |
||||||
|
scm = https://github.com/develmaycare/superpython |
||||||
|
source = https://github.com/develmaycare/superpython |
@ -1,3 +1 @@ |
|||||||
coverage |
superpython |
||||||
django |
|
||||||
sphinx |
|
Loading…
Reference in new issue