Skip to content

Commit 4466aef

Browse files
Update plugin-metadata, add code coverage and github actions
1 parent b9adc61 commit 4466aef

File tree

10 files changed

+1000
-6
lines changed

10 files changed

+1000
-6
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: bug
6+
assignees: ''
7+
8+
---
9+
10+
**Describe the bug**
11+
A clear and concise description of what the bug is.
12+
13+
**To Reproduce**
14+
Steps to reproduce the behavior:
15+
1. Go to '...'
16+
2. Click on '....'
17+
3. Scroll down to '....'
18+
4. See error
19+
20+
**Expected behavior**
21+
A clear and concise description of what you expected to happen.
22+
23+
**Screenshots**
24+
If applicable, add screenshots to help explain your problem.
25+
26+
**Additional context**
27+
Add any other context about the problem here.

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
blank_issues_enabled: false
2+
contact_links:
3+
- name: Comuns RPG Maker Discord server
4+
url: https://discord.gg/TqzckXj
5+
about: Please ask any questions here.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
name: Feature request
3+
about: Suggest an idea for this project
4+
title: ''
5+
labels: enhancement
6+
assignees: ''
7+
8+
---
9+
10+
**Is your feature request related to a problem? Please describe.**
11+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
12+
13+
**Describe the solution you'd like**
14+
A clear and concise description of what you want to happen.
15+
16+
**Describe alternatives you've considered**
17+
A clear and concise description of any alternative solutions or features you've considered.
18+
19+
**Additional context**
20+
Add any other context or screenshots about the feature request here.
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Bundle
2+
on:
3+
release:
4+
types: ['created']
5+
jobs:
6+
deploy:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- name: Get release
10+
id: get_release
11+
uses: bruceadams/get-release@v1.2.0
12+
env:
13+
GITHUB_TOKEN: ${{ github.token }}
14+
- name: Checkout
15+
uses: actions/checkout@v2
16+
- name: Setup node
17+
uses: actions/setup-node@v1
18+
with:
19+
node-version: '14'
20+
- name: Build
21+
run: |
22+
npm ci
23+
npm run build
24+
- name: Get plugin name
25+
id: plugin_name
26+
uses: notiz-dev/github-action-json-property@release
27+
with:
28+
path: 'package.json'
29+
prop_path: 'name'
30+
- name: Upload Release Bundle
31+
uses: actions/upload-release-asset@v1
32+
env:
33+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
34+
with:
35+
upload_url: ${{ steps.get_release.outputs.upload_url }}
36+
asset_path: ./dist/js/plugins/${{ steps.plugin_name.outputs.prop }}.js
37+
asset_name: ${{ steps.plugin_name.outputs.prop }}.js
38+
asset_content_type: application/javascript

.github/workflows/docs.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Docs
2+
on:
3+
push:
4+
branches:
5+
- master
6+
jobs:
7+
deploy:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Checkout
11+
uses: actions/checkout@v2
12+
- name: Setup node
13+
uses: actions/setup-node@v1
14+
with:
15+
node-version: '12'
16+
- name: Install Typescript & TypeDoc
17+
run: npm install -g typescript typedoc
18+
- name: Build with TypeDoc
19+
run: typedoc --excludeNotExported --excludePrivate --out docs src
20+
- name: Deploy to Github Pages
21+
uses: JamesIves/github-pages-deploy-action@releases/v3
22+
with:
23+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
24+
BRANCH: gh-pages
25+
FOLDER: docs

.github/workflows/tests.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Tests
2+
on:
3+
push:
4+
branches:
5+
- master
6+
jobs:
7+
deploy:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Checkout
11+
uses: actions/checkout@v2
12+
- name: Setup node
13+
uses: actions/setup-node@v1
14+
with:
15+
node-version: '12'
16+
- name: Run tests
17+
run: |
18+
npm ci
19+
npm run coverage
20+
- name: Upload report to Codecov
21+
uses: codecov/codecov-action@v1
22+
with:
23+
file: ./coverage/lcov.info

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
11
node_modules/
2-
dist/
2+
dist/
3+
coverage/
4+
.nyc_output/

.nycrc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"extends": "@istanbuljs/nyc-config-typescript"
3+
}

0 commit comments

Comments
 (0)