Skip to content

Commit

Permalink
refactor: rebuild development scripts and release workflow (#84)
Browse files Browse the repository at this point in the history
* refactor: add dev server and fix `update-beta.json` bug

* chore: add renovate config

* feat: release plugin to GitHub release via action

* chore: update vsc settings

* Cancel release by action

* docs: update readme

* Update README.md

* Update README.md

fix format

* Update README.md

* Update README.md

fix hint

* tweak

* Merge #81

* Fix indent

* Merge ade4962

* Revent delete env

* tweak

* feat: release via GitHub action

* docs: update readme

* Update README.md

* style: fix prettier

* add: stdout log to file

* Update README.md

fix typo

* Update release.yml

fix typo

* write Zotero log to `logs/zotero.log`

* do not provide update-beta.json default

* fix prettier in readme

* tweak

* fix wrong link in readme

* Move 3rd package config to package.json

---------

Co-authored-by: windingwind <[email protected]>
  • Loading branch information
northword and windingwind authored Dec 12, 2023
1 parent e2885ec commit fb9109d
Show file tree
Hide file tree
Showing 21 changed files with 810 additions and 520 deletions.
41 changes: 0 additions & 41 deletions .eslintrc.json

This file was deleted.

21 changes: 21 additions & 0 deletions .github/renovate.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": [
"config:recommended",
":semanticPrefixChore",
":prHourlyLimitNone",
":prConcurrentLimitNone",
":enableVulnerabilityAlerts",
":dependencyDashboard",
"schedule:weekends"
],
"packageRules": [
{
"matchPackageNames": ["zotero-plugin-toolkit", "zotero-types"],
"automerge": true
}
],
"git-submodules": {
"enabled": true
}
}
33 changes: 33 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Release

on:
push:
tags:
- v**

permissions:
contents: write

jobs:
release-it:
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.GitHub_TOKEN }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 20
# cache: npm

- name: Install deps
run: npm install

- name: Release to GitHub
# if: github.event_name == 'push' && github.ref_type == 'tag' && startsWith(github.ref, 'refs/tags/v')
run: |
npm run release -- --no-increment --no-git --github.release --ci --verbose
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
**/build
build
logs
node_modules
package-lock.json
pnpm-lock.yaml
yarn.lock
zotero-cmd.json
7 changes: 7 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
build
logs
node_modules
package-lock.json
yarn.lock
pnpm-lock.yaml
# zotero-cmd.json
3 changes: 0 additions & 3 deletions .prettierrc

This file was deleted.

14 changes: 0 additions & 14 deletions .release-it.json

This file was deleted.

15 changes: 4 additions & 11 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,23 +7,16 @@
{
"type": "node",
"request": "launch",
"name": "StartDev",
"name": "Start",
"runtimeExecutable": "npm",
"runtimeArgs": ["run", "start-watch"]
"runtimeArgs": ["run", "start"]
},
{
"type": "node",
"request": "launch",
"name": "Restart",
"name": "Build",
"runtimeExecutable": "npm",
"runtimeArgs": ["run", "restart"]
},
{
"type": "node",
"request": "launch",
"name": "Restart in Prod Mode",
"runtimeExecutable": "npm",
"runtimeArgs": ["run", "restart-prod"]
"runtimeArgs": ["run", "build"]
}
]
}
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
"editor.formatOnType": false,
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
"source.fixAll.eslint": "explicit"
}
}
Loading

0 comments on commit fb9109d

Please sign in to comment.