Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Module's composer.json template adjustments #66

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
11 changes: 8 additions & 3 deletions resources/fileTemplates/internal/Magento Module Composer.json.ft
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,14 @@
"version": "${MODULE_VERSION}",
"description": "${MODULE_DESCRIPTION}",
"type": "magento2-module",
#if (${DEPENDENCIES}) "require": {
${DEPENDENCIES} }, #end
#if (${LICENSE}) ${LICENSE}, #end
#if (${DEPENDENCIES})
"require": {
${DEPENDENCIES}
},
#end
#if (${LICENSE})
${LICENSE},
#end
"autoload": {
"files": [
"registration.php"
Expand Down
49 changes: 49 additions & 0 deletions resources/fileTemplates/internal/Magento Module Composer.json.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
<html lang="en">
<body>
<p face="verdana" size="-1">
The composer.json file determines the module's hard dependencies on other modules.<br>
It is required in a module for extensions provider vendors and it's optional for custom implementations, but it is highly recommended to use.
</p>

<table width="100%" border="0" cellpadding="5" cellspacing="0" style="border-collapse: collapse">
<tr>
<td colspan="3"><font face="verdana" size="-1">Template's predefined variables:</font></td>
</tr>
<tr>
<td valign="top"><nobr><font face="verdana" size="-2"><b>${COMPOSER_PACKAGE_NAME}</b></font></nobr></td>
<td width="10">&nbsp;</td>
<td width="100%" valign="top"><font face="verdana" size="-1">Module's composer name.</font></td>
</tr>
<tr>
<td valign="top"><nobr><font face="verdana" size="-2"><b>${MODULE_VERSION}</b></font></nobr></td>
<td width="10">&nbsp;</td>
<td width="100%" valign="top"><font face="verdana" size="-1">Module's version.</font></td>
</tr>
<tr>
<td valign="top"><nobr><font face="verdana" size="-2"><b>${MODULE_DESCRIPTION}</b></font></nobr></td>
<td width="10">&nbsp;</td>
<td width="100%" valign="top"><font face="verdana" size="-1">Short description of what the module does.</font></td>
</tr>
<tr>
<td valign="top"><nobr><font face="verdana" size="-2"><b>${DEPENDENCIES}</b></font></nobr></td>
<td width="10">&nbsp;</td>
<td width="100%" valign="top"><font face="verdana" size="-1">A list of the module's dependencies.</font></td>
</tr>
<tr>
<td valign="top"><nobr><font face="verdana" size="-2"><b>${LICENSE}</b></font></nobr></td>
<td width="10">&nbsp;</td>
<td width="100%" valign="top"><font face="verdana" size="-1">Module's licence.</font></td>
</tr>
<tr>
<td valign="top"><nobr><font face="verdana" size="-2"><b>${PACKAGE}</b></font></nobr></td>
<td width="10">&nbsp;</td>
<td width="100%" valign="top"><font face="verdana" size="-1">Module's package name. Also know as Vendor name.</font></td>
</tr>
<tr>
<td valign="top"><nobr><font face="verdana" size="-2"><b>${MODULE_NAME}</b></font></nobr></td>
<td width="10">&nbsp;</td>
<td width="100%" valign="top"><font face="verdana" size="-1">Module's name.</font></td>
</tr>
</table>
</body>
</html>