generated from windingwind/zotero-plugin-template
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit d307558
Showing
43 changed files
with
12,486 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Usage: | ||
# Copy this file as `.env` and fill in the variables below as instructed. | ||
|
||
# If you are developing more than one plugin, you can store the bin path and | ||
# profile path in the system environment variables, which can be omitted here. | ||
|
||
# The path of the Zotero binary file. | ||
# The path delimiter should be escaped as `\\` for win32. | ||
# The path is `*/Zotero.app/Contents/MacOS/zotero` for MacOS. | ||
ZOTERO_PLUGIN_ZOTERO_BIN_PATH = /path/to/zotero.exe | ||
|
||
# The path of the profile used for development. | ||
# Start the profile manager by `/path/to/zotero.exe -p` to create a profile for development. | ||
# @see https://www.zotero.org/support/kb/profile_directory | ||
ZOTERO_PLUGIN_PROFILE_PATH = /path/to/profile | ||
|
||
# The directory where the database is located. | ||
# If this field is kept empty, Zotero will start with the default data. | ||
# @see https://www.zotero.org/support/zotero_data | ||
ZOTERO_PLUGIN_DATA_DIR = | ||
|
||
# Custom commands to kill Zotero processes. | ||
# Commands for different platforms are already built into zotero-plugin, | ||
# if the built-in commands are not suitable for your needs, please modify this variable. | ||
# ZOTERO_PLUGIN_KILL_COMMAND = | ||
|
||
# GitHub Token | ||
# For scaffold auto create release and upload assets. | ||
# Fill in this variable if you are publishing locally instead of CI. | ||
# GITHUB_TOKEN = |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* text=auto eol=lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# To get started with Dependabot version updates, you'll need to specify which | ||
# package ecosystems to update and where the package manifests are located. | ||
# Please see the documentation for all configuration options: | ||
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates | ||
|
||
version: 2 | ||
updates: | ||
- package-ecosystem: "npm" # See documentation for possible values | ||
directory: "/" # Location of package manifests | ||
schedule: | ||
interval: "weekly" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"$schema": "https://docs.renovatebot.com/renovate-schema.json", | ||
"extends": [ | ||
"config:recommended", | ||
":semanticPrefixChore", | ||
":prHourlyLimitNone", | ||
":prConcurrentLimitNone", | ||
":enableVulnerabilityAlerts", | ||
":dependencyDashboard", | ||
"group:allNonMajor", | ||
"schedule:weekly" | ||
], | ||
"labels": ["dependencies"], | ||
"packageRules": [ | ||
{ | ||
"matchPackageNames": [ | ||
"zotero-plugin-toolkit", | ||
"zotero-types", | ||
"zotero-plugin-scaffold" | ||
], | ||
"schedule": ["at any time"], | ||
"automerge": true | ||
} | ||
], | ||
"git-submodules": { | ||
"enabled": true | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: Release | ||
|
||
on: | ||
push: | ||
tags: | ||
- v** | ||
|
||
permissions: | ||
contents: write | ||
issues: write | ||
pull-requests: write | ||
|
||
jobs: | ||
release: | ||
runs-on: ubuntu-latest | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GitHub_TOKEN }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 20 | ||
|
||
- name: Install deps | ||
run: npm install -f | ||
|
||
- name: Build | ||
run: | | ||
npm run build | ||
- name: Release to GitHub | ||
run: | | ||
npm run release | ||
sleep 1s | ||
- name: Notify release | ||
uses: apexskier/github-release-commenter@v1 | ||
continue-on-error: true | ||
with: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
comment-template: | | ||
:rocket: _This ticket has been resolved in {release_tag}. See {release_link} for release notes._ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
build | ||
logs | ||
node_modules | ||
pnpm-lock.yaml | ||
yarn.lock | ||
.DS_Store | ||
.env |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
.vscode | ||
build | ||
logs | ||
node_modules | ||
package-lock.json | ||
yarn.lock | ||
pnpm-lock.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"recommendations": [ | ||
"dbaeumer.vscode-eslint", | ||
"esbenp.prettier-vscode", | ||
"macabeus.vscode-fluent" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ | ||
// 使用 IntelliSense 了解相关属性。 | ||
// 悬停以查看现有属性的描述。 | ||
// 欲了解更多信息,请访问: https://go.microsoft.com/fwlink/?linkid=830387 | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"type": "node", | ||
"request": "launch", | ||
"name": "Start", | ||
"runtimeExecutable": "npm", | ||
"runtimeArgs": ["run", "start"] | ||
}, | ||
{ | ||
"type": "node", | ||
"request": "launch", | ||
"name": "Build", | ||
"runtimeExecutable": "npm", | ||
"runtimeArgs": ["run", "build"] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"editor.formatOnType": false, | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": "explicit" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
{ | ||
"appendElement - full": { | ||
"scope": "javascript,typescript", | ||
"prefix": "appendElement", | ||
"body": [ | ||
"appendElement({", | ||
"\ttag: '${1:div}',", | ||
"\tid: '${2:id}',", | ||
"\tnamespace: '${3:html}',", | ||
"\tclassList: ['${4:class}'],", | ||
"\tstyles: {${5:style}: '$6'},", | ||
"\tproperties: {},", | ||
"\tattributes: {},", | ||
"\t[{ '${7:onload}', (e: Event) => $8, ${9:false} }],", | ||
"\tcheckExistanceParent: ${10:HTMLElement},", | ||
"\tignoreIfExists: ${11:true},", | ||
"\tskipIfExists: ${12:true},", | ||
"\tremoveIfExists: ${13:true},", | ||
"\tcustomCheck: (doc: Document, options: ElementOptions) => ${14:true},", | ||
"\tchildren: [$15]", | ||
"}, ${16:container});" | ||
] | ||
}, | ||
"appendElement - minimum": { | ||
"scope": "javascript,typescript", | ||
"prefix": "appendElement", | ||
"body": "appendElement({ tag: '$1' }, $2);" | ||
}, | ||
"register Notifier": { | ||
"scope": "javascript,typescript", | ||
"prefix": "registerObserver", | ||
"body": [ | ||
"registerObserver({", | ||
"\t notify: (", | ||
"\t\tevent: _ZoteroTypes.Notifier.Event,", | ||
"\t\ttype: _ZoteroTypes.Notifier.Type,", | ||
"\t\tids: string[],", | ||
"\t\textraData: _ZoteroTypes.anyObj", | ||
"\t) => {", | ||
"\t\t$0", | ||
"\t}", | ||
"});" | ||
] | ||
} | ||
} |
Oops, something went wrong.