Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
fe85873
Bump sphinx-rtd-theme from 1.1.1 to 1.2.0 in /docs
dependabot[bot] Feb 8, 2023
6b73238
Merge pull request #113 from mautic/dependabot/pip/docs/sphinx-rtd-th…
RCheesley Feb 8, 2023
a8a40ab
Adding plugin CI docs
escopecz Feb 27, 2023
5fa1ff0
So the link must be the file name and not the link name?
escopecz Feb 27, 2023
8f3e481
Initial fixes
RCheesley Feb 27, 2023
c0c27a9
Vale and spelling fixes
RCheesley Feb 27, 2023
6ac79e8
Vale fix
RCheesley Feb 27, 2023
2b8803b
Vale fix
RCheesley Feb 27, 2023
21b9fba
Add Codecov to vocab
RCheesley Feb 27, 2023
73178e1
Merge branch 'main' into plugin-ci
RCheesley Feb 27, 2023
c6f0ed5
Fix typo and remove duplicate file
RCheesley Feb 27, 2023
2f4c944
Small fix to theme
RCheesley Feb 27, 2023
1054959
Add headers, improve flow
RCheesley Feb 27, 2023
bf8c4b4
Merge pull request #115 from escopecz/plugin-ci
RCheesley Feb 27, 2023
bb46f71
Bump myst-parser from 0.18.1 to 0.19.0 in /docs
dependabot[bot] Mar 1, 2023
3aa96cb
Merge pull request #116 from mautic/dependabot/pip/docs/myst-parser-0…
RCheesley Mar 1, 2023
47484fc
Bump sphinx from 5.3.0 to 6.1.3 in /docs
dependabot[bot] Mar 1, 2023
98d12aa
Merge pull request #109 from mautic/dependabot/pip/docs/sphinx-6.1.3
RCheesley Mar 1, 2023
62a9812
Bump myst-parser from 0.19.0 to 0.19.1 in /docs
dependabot[bot] Mar 2, 2023
43d0a7f
Merge pull request #117 from mautic/dependabot/pip/docs/myst-parser-0…
RCheesley Mar 2, 2023
fa49d8d
Bump readthedocs-sphinx-search from 0.2.0 to 0.3.1 in /docs
dependabot[bot] Mar 28, 2023
b944c58
Merge pull request #120 from mautic/dependabot/pip/docs/readthedocs-s…
RCheesley Mar 28, 2023
433c876
Bump myst-parser from 0.19.1 to 1.0.0 in /docs
dependabot[bot] Mar 28, 2023
fc5a70d
Merge pull request #118 from mautic/dependabot/pip/docs/myst-parser-1…
RCheesley Mar 28, 2023
6a0c0ba
Adding info about overwriteWithBlank for batch endpoint
escopecz Apr 21, 2023
9579b91
better wording
escopecz Apr 21, 2023
ef936ff
Merge pull request #122 from escopecz/overwriteWithBlank-for-batch
escopecz Apr 24, 2023
64ae8a8
Bump sphinx from 6.1.3 to 6.2.1 in /docs
dependabot[bot] Apr 26, 2023
04d5145
Merge pull request #124 from mautic/dependabot/pip/docs/sphinx-6.2.1
RCheesley Apr 26, 2023
05a87f7
Bump Python version to 3.8
RCheesley Apr 26, 2023
4c3a756
Merge pull request #125 from mautic/bump-python-version
RCheesley Apr 26, 2023
7e33c75
Creating new structure.
lenonleite Apr 27, 2023
810d486
Creating new structure.
lenonleite Apr 27, 2023
0b61b97
Creating new structure.
lenonleite Apr 27, 2023
dc2fd87
Creating new structure.
lenonleite Apr 27, 2023
35bf3d5
English improvement
lenonleite Apr 27, 2023
f3f8bcd
Creating new structure.
lenonleite Apr 28, 2023
d21ebe0
English improvements
lenonleite May 4, 2023
62fb491
English improvements
lenonleite May 4, 2023
7fe540b
English improvements
lenonleite May 4, 2023
33e895b
English improvements
lenonleite May 5, 2023
ec68daf
REST API: Add Notifications docs
dennisameling May 30, 2023
764e461
Merge pull request #132 from mautic/rest-api-notifications
escopecz May 31, 2023
b84131c
Merge branch 'main' into development-environment
RCheesley Jul 24, 2023
6507424
Small fix to the headings
RCheesley Jul 24, 2023
8213500
Merge pull request #126 from lenonleite/development-environment
RCheesley Jul 24, 2023
5d1d9b4
Small fix to code block and language
RCheesley Jul 24, 2023
c182b36
Add missing link files + vale fixes
RCheesley Jul 24, 2023
a8b6469
Add links and tidy up
RCheesley Jul 24, 2023
54a7d75
Readability
RCheesley Jul 24, 2023
2bcaf44
Fixes
RCheesley Jul 24, 2023
56cdf81
Create links
RCheesley Jul 24, 2023
21606fc
Let's not duplicate information
RCheesley Jul 24, 2023
76be243
Update getting_started.rst
RCheesley Jul 24, 2023
5fcd297
Merge pull request #134 from mautic/dev-env-fixes
RCheesley Jul 24, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/styles/Vocab/Mautic/accept.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ CCPA
Citrix
Clearbit
CloudAMQP
Codecov
config
Config
Company(ies)
Expand Down
2 changes: 1 addition & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ sphinx:

# Explicitly set the version of Python and its requirements
python:
version: 3.7
version: 3.8
install:
- requirements: docs/requirements.txt
2 changes: 1 addition & 1 deletion docs/_static/theme.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.wy-side-nav-search, .wy-nav-side {
.wy-side-nav-search, .wy-nav-side, .wy-nav-top {
background-color: #4e5e9e;
}

Expand Down
83 changes: 83 additions & 0 deletions docs/development-environment/environments.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
Environments
############

:xref:`Symfony 4 environment conventions`

In all environments, Mautic loads the following files if they exist,
the latter taking precedence over the former:

* ``.env`` contains default values for the environment variables needed by the app
* ``.env.local`` uncommitted file with local overrides
* ``.env.$APP_ENV`` committed environment-specific defaults
* ``.env.$APP_ENV.local`` uncommitted environment-specific overrides

Real environment variables win over ``.env`` files.

.. warning:: Don't define secrets in this file, or any other committed files. Set secrets via environment variables, or through other secret management tools.

Run ``composer dump-env prod`` to compile .env files for production use (``requires symfony/flex >=1.2``). Read more about
:xref:`Symfony 4 best practices environment variables`.

By default the structure come with 3 environments
``.env``
``.env.test``
``.env.test.local``

Mautic loads default values filled in the ``app/config/parameters.php`` file at installation.
These values can be overridden by the ``.env`` structure.

Development environment
=======================
``.env`` come with two values:

.. code-block:: bash

APP_ENV=prod
APP_DEBUG=0

It's recommended to create the ``.env.local`` file. This file overrides the values in ``.env`` file.
Example:

.. code-block:: bash

APP_ENV=dev
APP_DEBUG=1
DB_HOST=...
DB_PORT=3306
DB_NAME=...
DB_USER=...
DB_PASSWD=...
MAUTIC_DB_PREFIX=...
MAUTIC_TABLE_PREFIX=...

Test environment
================

In the test environment there are two files.

The first one is the default file ``.env.test`` that includes credentials used to create a test instance of Mautic.

.. code-block:: bash

DB_HOST=127.0.0.1
DB_PORT=3306
DB_NAME=mautictest
DB_USER=root
DB_PASSWD=
MAUTIC_DB_PREFIX=test_
MAUTIC_TABLE_PREFIX=test_
MAUTIC_ENV=test
MAUTIC_ADMIN_USERNAME=admin
MAUTIC_ADMIN_PASSWORD=mautic

The second one, ``.env.test.local`` includes values for the DDEV local development environment, overriding the ``.env.test`` values.
It's recommended making any changes to this file with its values.

.. code-block:: bash

DB_HOST=db
DB_USER=db
DB_PASSWD=db
DB_NAME=test
...
MAUTIC_DB_PREFIX=...
11 changes: 11 additions & 0 deletions docs/development-environment/getting_started.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
Development environment
#######################

Introduction
============
Mautic is a system based on the :xref:`Symfony framework` and :xref:`Doctrine`.

Mautic uses the :xref:`Symfony framework` as a foundation for the app.

It follows the :xref:`Symfony coding standards` and :xref:`Symfony best practices`.

37 changes: 37 additions & 0 deletions docs/development-environment/how_to_install_with_ddev.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
How to install Mautic with DDEV
###############################

.. note::
If you get stuck, join the lively Mautic Community on :xref:`Mautic Slack` or the :xref:`Developer Forum` for support and answers. **Please first post in the forum**, then share the link in Slack, so others can learn from your question.

Pre-requisites with DDEV
========================
1. You should have DDEV and Docker or Colima installed on your machine. If not, please follow the instructions here: :xref:`ddev install`

Installing Mautic is a two-step process:
========================================
1. Clone this repository

.. code-block:: bash

git clone https://github.com/mautic/mautic.git

.. Note:: Clone the repository in the directory where you want to install Mautic.

1. Install Mautic running DDEV.

.. code-block:: bash

cd mautic
ddev start

.. list-table:: Users and passwords
:header-rows: 1

* - Username
- Password
* - ``admin``
- ``mautic``
* - ``sales``
- ``mautic``

42 changes: 42 additions & 0 deletions docs/development-environment/setup.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
How to install Mautic manually
##############################

Pre-requisites to setup
=======================

Mautic assumed that the system already has ``composer`` and ``git`` installed and configured.

.. note::
If you get stuck, join the lively Mautic Community on :xref:`Mautic Slack` or the :xref:`Developer Forum` for support and answers. **Please first post in the forum**, then share the link in Slack, so others can learn from your question.

Steps
=====
1. To setup the developer environment, fork and clone the source from GitHub as outlined in :doc:`/development-environment/how_to_install_with_ddev`.
2. Run ``composer install`` on the source.
3. Open your browser and complete the installation through the Mautic installer.

You can also run the install process from command line:

* Add a ``local.php`` file in ``app/config``
* Edit the ``local.php`` file using the following template (Mautic adapts to new local settings):

.. code-block:: php

<?php
$parameters = array(
'db_driver' => 'pdo_mysql',
'db_host' => 'localhost',
'db_table_prefix' => null,
'db_port' => '3306',
'db_name' => 'mautic',
'db_user' => 'root',
'db_password' => 'root_password',
'db_backup_tables' => true,
'db_backup_prefix' => 'bak_',
);

* Run the following command and add your own options:

.. code-block:: bash

php bin/console mautic:install https://mautic.example.com
12 changes: 12 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,16 @@ Welcome to Mautic's developer documentation

This is a work in progress. More to come soon. In the meantime, go to :xref:`Legacy Developer Docs` to view the developer documentation.

.. toctree::
:maxdepth: 2
:caption: Development Environment
:hidden:

development-environment/getting_started
development-environment/how_to_install_with_ddev
development-environment/setup
development-environment/environments

.. toctree::
:maxdepth: 2
:caption: Themes
Expand Down Expand Up @@ -56,6 +66,7 @@ This is a work in progress. More to come soon. In the meantime, go to :xref:`Leg
plugins/installation
plugins/data
plugins/translations
plugins/continuous-integration

.. toctree::
:maxdepth: 2
Expand Down Expand Up @@ -95,6 +106,7 @@ This is a work in progress. More to come soon. In the meantime, go to :xref:`Leg
rest_api/categories
rest_api/contacts
rest_api/fields
rest_api/notifications
rest_api/reports
rest_api/text_messages

Expand Down
7 changes: 7 additions & 0 deletions docs/links/codecov.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "codecov"
link_text = "Codecov"
link_url = "https://about.codecov.io"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/codecov_gh_app.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "codecov_gh_app"
link_text = "Codecov GitHub App"
link_url = "https://github.com/apps/codecov"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/composer.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "composer"
link_text = "Composer"
link_url = "https://getcomposer.org"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/ddev_install.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "ddev install"
link_text = "Install DDEV"
link_url = "https://ddev.readthedocs.io/en/stable/#installation"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/doctrine.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "Doctrine"
link_text = "Doctrine"
link_url = "https://www.doctrine-project.org/"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/hello_world_plugin.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "hello_world_plugin"
link_text = "Hello World Plugin"
link_url = "https://github.com/mautic/plugin-helloworld"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/mautic_dev_forum.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "Developer Forum"
link_text = "Developer Forum"
link_url = "https://forum.mautic.org/c/development"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/mautic_github.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "Mautic's GitHub Repo"
link_text = "Mautic's GitHub repository"
link_url = "https://github.com/mautic/mautic"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/mautic_slack.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "Mautic Slack"
link_text = "Slack"
link_url = "https://mau.tc/slack-invite"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/php_cs_fixer.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "php_cs_fixer"
link_text = "PHP CS Fixer"
link_url = "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/phpstan.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "phpstan"
link_text = "PHPStan"
link_url = "https://phpstan.org"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/phpunit.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "phpunit"
link_text = "PHPUnit"
link_url = "https://phpunit.de"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/rector.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "rector"
link_text = "Rector"
link_url = "https://getrector.com"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/symfony_best_practices.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "Symfony best practices"
link_text = "Symfony best practices"
link_url = "https://symfony.com/doc/current/best_practices.html"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/symfony_coding_standards.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "Symfony coding standards"
link_text = "Symfony coding standards"
link_url = "https://symfony.com/doc/current/contributing/code/standards.html"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/symfony_docs_best_pratice_environments.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "Symfony 4 best practices environment variables"
link_text = "best practices"
link_url = "https://symfony.com/doc/current/best_practices.html#use-environment-variables-for-infrastructure-configuration"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/symfony_docs_configuration_environments.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "Symfony 4 environment conventions"
link_text = "Mautic follows the Symfony 4.4 environment conventions:"
link_url = "https://symfony.com/doc/4.4/index.html"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/symfony_framework.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "Symfony framework"
link_text = "Symfony framework"
link_url = "https://symfony.com/"

link.xref_links.update({link_name: (link_text, link_url)})
7 changes: 7 additions & 0 deletions docs/links/twig_lint.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from . import link

link_name = "twig_lint"
link_text = "Twig Lint"
link_url = "https://symfony.com/doc/5.4/templates.html#linting-twig-templates"

link.xref_links.update({link_name: (link_text, link_url)})
Loading