Metadata-Version: 2.1
Name: mojo-startup
Version: 2.0.3
Summary: Automation Mojo Startup Package
License: LICENSE.txt
Keywords: python
Author: Myron W. Walker
Requires-Python: >=3.9,<4.0
Classifier: License :: OSI Approved :: MIT License
Classifier: License :: Other/Proprietary License
Classifier: Operating System :: POSIX
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3
Requires-Dist: mojo-collections (>=2.0.1,<2.1.0)
Requires-Dist: typing-extensions (>=4.11.0,<5.0.0)
Description-Content-Type: text/x-rst

=======================
mojo-startup
=======================
This package sets up a pattern for extremely early pre-configuration of variable extensibility
hook for the startup configuration.  This module looks for a single environment variable to be set:

.. code::

    MJR_STARTUP_SETTINGS

The value of this variable is accessed like so:

.. code::

    from mojo.startup.startupvariables import MOJO_STARTUP_VARIABLES
    
    print(MOJO_STARTUP_VARIABLES.MJR_STARTUP_SETTINGS)


The `MJR_STARTUP_SETTINGS` is an environment variable that is is set to the path for a config file that should point to the
configuration file that is used to startup the environment of a process.

The default value for the `MJR_STARTUP_SETTINGS` variable is `~/.mojo.config`.

The `mojo-startup` module makes a singleton `ConfigParser` available for other modules to use.  This
configuration parser can be accessed by:

.. code::
    
    from mojo.startup.wellknown import StartupConfigSingleton
    
    cparser = StartupConfigSingleton()
    
    defaults_section = cparser["DEFAULTS"]
    someval = defaults_section["SOME_VARIABLE"]

===========
Description
===========
This module does one very important thing.  It establishes the path for all other 'mojo' packages
on where to load default config from.  This is very important because it provides extensibility
as early as possible before the running of any code.

The pattern established for defaults for variables is:
* Variable is set to a hard coded default
* Startup configuration is checked for an override
* The environment variables are checked for an override

=================
Code Organization
=================
* .vscode - Common tasks
* development - This is where the runtime environment scripts are located
* repository-setup - Scripts for homing your repository and to your checkout and machine setup
* userguide - Where you put your user guide
* source/packages - Put your root folder here 'source/packages/(root-module-folder)'
* source/sphinx - This is the Sphinx documentation folder
* workspaces - This is where you add VSCode workspaces templates and where workspaces show up when homed.

==========
References
==========

- `User Guide <userguide/userguide.rst>`
- `Coding Standards <userguide/10-00-coding-standards.rst>`

