Skip to content

Commit 656a343

Browse files
Merge pull request #67 from magebitcom/release
Release
2 parents 151e3ed + 9f2bf91 commit 656a343

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+657
-55
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: Run CI jobs
2-
on: [push, pull_request]
2+
on: [push]
33

44
jobs:
55
lint:

.github/workflows/release.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,14 @@ jobs:
1919
uses: softprops/action-gh-release@v2
2020
if: startsWith(github.ref, 'refs/tags/')
2121
with:
22-
files: '*.vsix'
22+
files: '*.vsix'
23+
deploy:
24+
runs-on: ubuntu-latest
25+
needs: build
26+
steps:
27+
- name: Checkout
28+
uses: actions/checkout@v4
29+
- name: Publish
30+
run: npm run deploy
31+
env:
32+
VSCE_PAT: ${{ secrets.VSCE_PAT }}

CHANGELOG.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,30 @@ All notable changes to the "magento-toolbox" extension will be documented in thi
44

55
Check [Keep a Changelog](http://keepachangelog.com/) for recommendations on how to structure this file.
66

7+
## [1.2.0]
8+
9+
- Added: Generator command for sample Layout XML file
10+
- Added: Generator command for sample page_types.xml file
11+
- Added: Generator command for sample crontab.xml file
12+
- Added: Generator command for sample email_templates.xml file
13+
- Added: Generator command for sample sections.xml file
14+
- Added: Generator command for sample fieldset.xml file
15+
- Added: Generator command for sample view.xml file
16+
- Added: Generator command for sample indexer.xml file
17+
- Added: Generator command for sample mview.xml file
18+
- Added: Generator command for sample widget.xml file
19+
- Added: Generator command for sample extension_attributes.xml file
20+
- Added: Generator command for sample system.xml file
21+
- Added: Generator command for sample config.xml file
22+
723
## [1.1.3] - 3/12/2025
824

925
- Fixed: Block, observer, plugin and preference class generation fails if class name includes backslashes
1026
- Fixed: Composer.json license is not capitalized
1127
- Fixed: Module generation module.xml sequence elements are not added
1228
- Fixed: Observer XML generation fails if file header comment is not configured
1329
- Fixed: Preference type attribute does not include full class namespace
14-
- Chore: added unit tests for generator commands
30+
- Chore: Added unit tests for generator commands
1531

1632
## [1.1.2] - 2/27/2025
1733

package.json

Lines changed: 106 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,58 @@
110110
{
111111
"command": "magento-toolbox.generatePreference",
112112
"title": "Magento Toolbox: Generate Preference"
113+
},
114+
{
115+
"command": "magento-toolbox.generateLayoutXmlFile",
116+
"title": "Magento Toolbox: Generate Layout XML"
117+
},
118+
{
119+
"command": "magento-toolbox.generatePageTypesXmlFile",
120+
"title": "Magento Toolbox: Generate Page Types XML"
121+
},
122+
{
123+
"command": "magento-toolbox.generateCrontabXmlFile",
124+
"title": "Magento Toolbox: Generate Crontab XML"
125+
},
126+
{
127+
"command": "magento-toolbox.generateEmailTemplatesXmlFile",
128+
"title": "Magento Toolbox: Generate Email Templates XML"
129+
},
130+
{
131+
"command": "magento-toolbox.generateSectionsXmlFile",
132+
"title": "Magento Toolbox: Generate Sections XML"
133+
},
134+
{
135+
"command": "magento-toolbox.generateFieldsetXmlFile",
136+
"title": "Magento Toolbox: Generate Fieldset XML"
137+
},
138+
{
139+
"command": "magento-toolbox.generateViewXmlFile",
140+
"title": "Magento Toolbox: Generate View XML"
141+
},
142+
{
143+
"command": "magento-toolbox.generateIndexerXmlFile",
144+
"title": "Magento Toolbox: Generate Indexer XML"
145+
},
146+
{
147+
"command": "magento-toolbox.generateMviewXmlFile",
148+
"title": "Magento Toolbox: Generate MVIEW XML"
149+
},
150+
{
151+
"command": "magento-toolbox.generateWidgetXmlFile",
152+
"title": "Magento Toolbox: Generate Widget XML"
153+
},
154+
{
155+
"command": "magento-toolbox.generateExtensionAttributesXmlFile",
156+
"title": "Magento Toolbox: Generate Extension Attributes XML"
157+
},
158+
{
159+
"command": "magento-toolbox.generateSystemXmlFile",
160+
"title": "Magento Toolbox: Generate System XML"
161+
},
162+
{
163+
"command": "magento-toolbox.generateConfigXmlFile",
164+
"title": "Magento Toolbox: Generate Config XML"
113165
}
114166
],
115167
"menus": {
@@ -183,6 +235,58 @@
183235
{
184236
"command": "magento-toolbox.generateWebapiXmlFile",
185237
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
238+
},
239+
{
240+
"command": "magento-toolbox.generateLayoutXmlFile",
241+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
242+
},
243+
{
244+
"command": "magento-toolbox.generatePageTypesXmlFile",
245+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
246+
},
247+
{
248+
"command": "magento-toolbox.generateCrontabXmlFile",
249+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
250+
},
251+
{
252+
"command": "magento-toolbox.generateEmailTemplatesXmlFile",
253+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
254+
},
255+
{
256+
"command": "magento-toolbox.generateSectionsXmlFile",
257+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
258+
},
259+
{
260+
"command": "magento-toolbox.generateFieldsetXmlFile",
261+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
262+
},
263+
{
264+
"command": "magento-toolbox.generateViewXmlFile",
265+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
266+
},
267+
{
268+
"command": "magento-toolbox.generateIndexerXmlFile",
269+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
270+
},
271+
{
272+
"command": "magento-toolbox.generateMviewXmlFile",
273+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
274+
},
275+
{
276+
"command": "magento-toolbox.generateWidgetXmlFile",
277+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
278+
},
279+
{
280+
"command": "magento-toolbox.generateExtensionAttributesXmlFile",
281+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
282+
},
283+
{
284+
"command": "magento-toolbox.generateSystemXmlFile",
285+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
286+
},
287+
{
288+
"command": "magento-toolbox.generateConfigXmlFile",
289+
"when": "resourcePath =~ /app\\/code\\/.+\\/.+/i"
186290
}
187291
]
188292
}
@@ -201,7 +305,8 @@
201305
"test": "vscode-test",
202306
"format": "prettier --write \"src/**/*.{ts,tsx,js,jsx,json,css,scss,md}\"",
203307
"format:check": "prettier --check \"src/**/*.{ts,tsx,js,jsx,json,css,scss,md}\"",
204-
"package-vsix": "vsce package"
308+
"package-vsix": "vsce package",
309+
"deploy": "vsce publish"
205310
},
206311
"devDependencies": {
207312
"@types/ejs": "^3.1.5",

src/command/GenerateAclXmlFileCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ export default class GenerateAclXmlFileCommand extends SimpleTemplateGeneratorCo
1010
return 'ACL XML File';
1111
}
1212

13-
getTemplatePath(data: TemplateWizardData): string {
13+
getFilePath(data: TemplateWizardData): string {
1414
const [vendor, module] = data.module.split('_');
1515

1616
return `app/code/${vendor}/${module}/etc/acl.xml`;
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
import { SimpleTemplateGeneratorCommand } from './SimpleTemplateGeneratorCommand';
2+
import { TemplateWizardData } from 'wizard/SimpleTemplateWizard';
3+
import FileHeader from 'common/xml/FileHeader';
4+
5+
export default class GenerateConfigXmlFileCommand extends SimpleTemplateGeneratorCommand {
6+
constructor() {
7+
super('magento-toolbox.generateConfigXmlFile');
8+
}
9+
10+
getWizardTitle(): string {
11+
return 'Config XML File';
12+
}
13+
14+
getFileHeader(data: TemplateWizardData): string | undefined {
15+
return FileHeader.getHeader(data.module);
16+
}
17+
18+
getFilePath(data: TemplateWizardData): string {
19+
const [vendor, module] = data.module.split('_');
20+
21+
return `app/code/${vendor}/${module}/etc/config.xml`;
22+
}
23+
24+
getTemplateName(data: TemplateWizardData): string {
25+
return 'xml/blank-config';
26+
}
27+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
import { SimpleTemplateGeneratorCommand } from './SimpleTemplateGeneratorCommand';
2+
import { TemplateWizardData } from 'wizard/SimpleTemplateWizard';
3+
import FileHeader from 'common/xml/FileHeader';
4+
5+
export default class GenerateCrontabXmlCommand extends SimpleTemplateGeneratorCommand {
6+
constructor() {
7+
super('magento-toolbox.generateCrontabXmlFile');
8+
}
9+
10+
getWizardTitle(): string {
11+
return 'Crontab XML File';
12+
}
13+
14+
getFileHeader(data: TemplateWizardData): string | undefined {
15+
return FileHeader.getHeader(data.module);
16+
}
17+
18+
getFilePath(data: TemplateWizardData): string {
19+
const [vendor, module] = data.module.split('_');
20+
21+
return `app/code/${vendor}/${module}/etc/crontab.xml`;
22+
}
23+
24+
getTemplateName(data: TemplateWizardData): string {
25+
return 'xml/blank-crontab';
26+
}
27+
}

src/command/GenerateDiXmlFileCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ export default class GenerateDiXmlFileCommand extends SimpleTemplateGeneratorCom
2323
return 'DI XML File';
2424
}
2525

26-
getTemplatePath(data: TemplateWizardData): string {
26+
getFilePath(data: TemplateWizardData): string {
2727
const [vendor, module] = data.module.split('_');
2828

2929
if (data.area && data.area !== MagentoScope.Global) {
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
import { SimpleTemplateGeneratorCommand } from './SimpleTemplateGeneratorCommand';
2+
import { TemplateWizardData } from 'wizard/SimpleTemplateWizard';
3+
import FileHeader from 'common/xml/FileHeader';
4+
5+
export default class GenerateEmailTemplatesXmlCommand extends SimpleTemplateGeneratorCommand {
6+
constructor() {
7+
super('magento-toolbox.generateEmailTemplatesXmlFile');
8+
}
9+
10+
getWizardTitle(): string {
11+
return 'Email Templates XML File';
12+
}
13+
14+
getFileHeader(data: TemplateWizardData): string | undefined {
15+
return FileHeader.getHeader(data.module);
16+
}
17+
18+
getFilePath(data: TemplateWizardData): string {
19+
const [vendor, module] = data.module.split('_');
20+
21+
return `app/code/${vendor}/${module}/etc/email_templates.xml`;
22+
}
23+
24+
getTemplateName(data: TemplateWizardData): string {
25+
return 'xml/blank-email-templates';
26+
}
27+
}

src/command/GenerateEventsXmlCommand.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export default class GenerateEventsXmlCommand extends SimpleTemplateGeneratorCom
2828
return FileHeader.getHeader(data.module);
2929
}
3030

31-
getTemplatePath(data: TemplateWizardData): string {
31+
getFilePath(data: TemplateWizardData): string {
3232
const [vendor, module] = data.module.split('_');
3333

3434
if (data.area && data.area !== MagentoScope.Global) {

0 commit comments

Comments
 (0)