Skip to content

Commit

Permalink
fix: add remark frontmatter support
Browse files Browse the repository at this point in the history
  • Loading branch information
Xunnamius committed Jan 3, 2021
1 parent 2e2d170 commit a8cd378
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 9 deletions.
6 changes: 4 additions & 2 deletions .github/ISSUE_TEMPLATE/BUG_REPORT.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---

## name: 🤯 Bug report
about: Create a report and help us improve
labels: 🤯 bug, needs triage
name: 🤯 Bug report
about: Create a report to help us improve
labels: 🤯 bug, needs triage
---

<details open><summary><strong>Problematic behavior</strong></summary>

Expand Down
6 changes: 4 additions & 2 deletions .github/ISSUE_TEMPLATE/FEATURE_REQUEST.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
---

## name: 🤩 Feature request&#xA;about: Tell us about your awesome idea&#xA;labels: 🤩 feature
name: 🤩 Feature request
about: Tell us about your awesome idea
labels: 🤩 feature
---

<!--
Include a clear and concise description of what the problem is. If applicable,
Expand Down
28 changes: 28 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,14 @@
},
"scripts": {
"build": "npm run build-dist --",
"build-changelog": "conventional-changelog --outfile CHANGELOG.md --preset angular --config .changelogrc.js --release-count 0 --skip-unstable && (if [ \"$CHANGELOG_SKIP_TITLE\" != 'true' ]; then { node -e 'console.log(require(\"./.changelogrc.js\").changelogTitle)'; cat CHANGELOG.md; } > CHANGELOG.md.tmp && mv CHANGELOG.md.tmp CHANGELOG.md; fi) && remark -o --use reference-links --use gfm CHANGELOG.md && prettier --write CHANGELOG.md",
"build-changelog": "conventional-changelog --outfile CHANGELOG.md --preset angular --config .changelogrc.js --release-count 0 --skip-unstable && (if [ \"$CHANGELOG_SKIP_TITLE\" != 'true' ]; then { node -e 'console.log(require(\"./.changelogrc.js\").changelogTitle)'; cat CHANGELOG.md; } > CHANGELOG.md.tmp && mv CHANGELOG.md.tmp CHANGELOG.md; fi) && remark -o --use reference-links --use gfm --use frontmatter CHANGELOG.md && prettier --write CHANGELOG.md",
"build-dist": "npm run clean && NODE_ENV=production tsc --project tsconfig.types.json && NODE_ENV=production webpack --config-name main && NODE_ENV=esm babel src --extensions .ts --out-dir dist/lib --out-file-extension .mjs && { echo -n '\"undefined\"!=typeof window&&(window.global=window);'; cat dist/lib/index.js; } > dist/lib/index.js-tmp && mv -f dist/lib/index.js-tmp dist/lib/index.js",
"build-docs": "typedoc --plugin typedoc-plugin-markdown --out docs --readme none src/index.ts && find docs -name '*.md' -exec sed -i -e 's/`__namedParameters`: //g' {} + && find docs -name '*.md' -exec sed -i -e 's/__namedParameters/\\(destructured\\)/g' {} + && find docs -name '*.md' -exec sed -i -e 's/Project: //g' {} + && sed -i -e 1,4d docs/README.md",
"build-stats": "NODE_ENV=production webpack --config-name main --json > bundle-stats.json",
"clean": "rm -rf dist coverage external-scripts/bin",
"format": "sort-package-json && remark -o --use reference-links --use gfm . && prettier --write .",
"format": "sort-package-json && remark -o --use reference-links --use gfm --use frontmatter . && prettier --write .",
"postinstall": "if [ -z \"$CI\" ]; then husky install; else echo 'skipped installing husky git hooks'; fi",
"lint": "stdbuf -i0 -o0 -e0 tsc --project tsconfig.lint.json; X=$?; stdbuf -i0 -o0 -e0 eslint --parser-options=project:tsconfig.lint.json src && remark --quiet --frail --use gfm --use lint-final-newline --use lint-no-auto-link-without-protocol --use lint-no-blockquote-without-marker --use lint-ordered-list-marker-style --use lint-hard-break-spaces --use lint-no-duplicate-definitions --use lint-no-heading-content-indent --use lint-no-inline-padding --use lint-no-undefined-references --use lint-no-unused-definitions . && [ $X -eq 0 ]",
"lint": "stdbuf -i0 -o0 -e0 tsc --project tsconfig.lint.json; X=$?; stdbuf -i0 -o0 -e0 eslint --parser-options=project:tsconfig.lint.json src && remark --quiet --frail --use gfm --use frontmatter --use lint-final-newline --use lint-no-auto-link-without-protocol --use lint-no-blockquote-without-marker --use lint-ordered-list-marker-style --use lint-hard-break-spaces --use lint-no-duplicate-definitions --use lint-no-heading-content-indent --use lint-no-inline-padding --use lint-no-undefined-references --use lint-no-unused-definitions . && [ $X -eq 0 ]",
"list-tasks": "node -e 'console.log(Object.keys(require(\"./package.json\").scripts).join(\"\\n\"))'",
"test": "npm run test-unit --",
"test-integration": "npm run list-tasks | grep -e '^test-integration-' | xargs -n1 npm run",
Expand Down Expand Up @@ -81,7 +81,7 @@
}
},
"lint-staged": {
"*.md": "remark -o --use reference-links --use gfm",
"*.md": "remark -o --use reference-links --use gfm --use frontmatter",
"package.json": "sort-package-json",
"*": "prettier --write --ignore-unknown"
},
Expand Down Expand Up @@ -163,6 +163,7 @@
"prettier": "^2.2.1",
"puppeteer": "5.4.0",
"remark-cli": "^9.0.0",
"remark-frontmatter": "^3.0.0",
"remark-gfm": "^1.0.0",
"remark-lint-final-newline": "^1.0.5",
"remark-lint-hard-break-spaces": "^2.0.1",
Expand Down
3 changes: 2 additions & 1 deletion release.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,8 @@ module.exports = {
[
'@semantic-release/exec',
{
prepareCmd: 'remark -o --use reference-links --use gfm CHANGELOG.md'
prepareCmd:
'remark -o --use reference-links --use gfm --use frontmatter CHANGELOG.md'
}
],
[
Expand Down

0 comments on commit a8cd378

Please sign in to comment.