Skip to content
This repository was archived by the owner on Apr 11, 2026. It is now read-only.

Commit 8625068

Browse files
committed
docs: tweaks
1 parent 958bc34 commit 8625068

2 files changed

Lines changed: 75 additions & 53 deletions

File tree

.devcontainer/devcontainer.json

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,16 +3,28 @@
33
{
44
"name": "Zotero Plugins Marketplace",
55
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
6-
"image": "mcr.microsoft.com/devcontainers/typescript-node:1-22-bookworm",
6+
// https://github.com/devcontainers/images/tree/main/src/base-ubuntu
7+
"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
78

89
// Features to add to the dev container. More info: https://containers.dev/features.
910
"features": {
10-
"ghcr.io/devcontainers-contrib/features/pnpm:2": {}
11+
// https://github.com/devcontainers/features/blob/main/src/node/README.md
12+
"ghcr.io/devcontainers/features/node:1": {
13+
"version": "lts",
14+
"pnpmVersion": "latest"
15+
}
1116
},
1217

1318
// Use 'forwardPorts' to make a list of ports inside the container available locally.
14-
// "forwardPorts": [5173, 4173],
15-
// "portsAttributes": {},
19+
"forwardPorts": [5173, 4173],
20+
"portsAttributes": {
21+
"5173": {
22+
"label": "dev port"
23+
},
24+
"4173": {
25+
"label": "build port"
26+
}
27+
},
1628

1729
// Use 'postCreateCommand' to run commands after the container is created.
1830
"postCreateCommand": "pnpm i",

README.md

Lines changed: 59 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,73 +1,83 @@
11
# Zotero Plugin Registry
22

3-
> A self-hosted registry and store for Zotero plugins based on their `update.json` manifests.
3+
**Zotero Plugin Registry** is a self-hosted, structured registry that aggregates plugin metadata by collecting and parsing developers' self-hosted `update.json` files.
44

5-
## Overview
5+
This project is the successor to the plugin listing functionality in [`zotero-chinese/zotero-plugins`](https://github.com/zotero-chinese/zotero-plugins), which was primarily designed to cache and mirror `.xpi` files hosted on GitHub to support users in mainland China. However, that system did not automatically parse plugin versions or compatibility information from `update.json`, nor did it support plugins hosted outside GitHub.
66

7-
Zotero Plugin Registry is a self-hosted platform that aggregates Zotero plugins by collecting developers' self-hosted `update.json` files.
8-
It provides a unified service for users to browse, search, and get version and compatibility information about Zotero plugins.
7+
In contrast, this new repository:
8+
9+
- Collects only essential metadata for each plugin (`meta.json`) and the URL to its `update.json`
10+
- Automatically fetches and parses version and compatibility info from the `update.json`
11+
- Generates structured JSON outputs for frontend applications or indexing
12+
- Serves as the canonical data source for a new, internationalized Zotero plugin store frontend
13+
14+
The previous [frontend site](https://github.com/zotero-chinese/website) and [zotero-plugins project](https://github.com/zotero-chinese/zptero-plugins) created by the Zotero Chinese community will continue to serve Chinese users with a localized interface and GitHub mirror links. This project aims to power a new global plugin ecosystem, with improved automation, wider plugin support, and international accessibility.
915

1016
## Project Structure
1117

1218
```plain
13-
main/
19+
.
1420
└── plugins/
15-
└── <plugin-id>/
16-
├── meta.json # Base plugin metadata (manually maintained)
17-
├── meta.generated.json # Generated metadata including versions
18-
├── latest.json # Generated latest version info
19-
└── icon.png # Optional plugin icon
21+
└── <plugin-id>/
22+
├── meta.json # Base plugin metadata (manually maintained)
23+
├── meta.generated.json # Generated metadata including versions
24+
└── icon.png # Optional plugin icon
2025
scripts/
21-
└── build.ts # Build script to generate aggregated data
22-
.gitignore # Ignore generated JSON files
23-
package.json # Project config and dependencies
24-
README.md # This document
26+
└── build.ts # Build script to generate aggregated data
27+
package.json # Project config and dependencies
28+
README.md # This document
2529
```
2630

27-
## Quick Start
28-
29-
1. Clone the repository and install dependencies
30-
31-
```bash
32-
git clone https://github.com/zotero-plugin-dev/zotero-plugin-registry.git
33-
cd zotero-plugin-registry
34-
pnpm install
35-
```
36-
37-
2. Add plugin metadata in `main/plugins/<plugin-id>/meta.json`, example:
38-
39-
```json
40-
{
41-
42-
"name": "Zotero Format Metadata",
43-
"update_json": "https://example.com/path/to/update.json",
44-
"description": "A useful Zotero plugin.",
45-
"homepage": "https://github.com/northword/zotero-format-metadata",
46-
"tags": ["metadata"]
47-
}
48-
```
49-
50-
3. Run the build script to generate aggregated data
31+
## Submitting Plugins
32+
33+
[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/zotero-plugin-dev/zotero-plugin-registry?quickstart=1)
34+
35+
> [!NOTE]
36+
>
37+
> How to add a plugin that hasn't been included?
38+
>
39+
> Add plugin metadata in `./plugins/<plugin-id>/meta.json`, the basic format is shown below, and existing items can also be used as references.
40+
>
41+
> After editing, commit and pull request. We will process it as soon as possible.
42+
43+
```json
44+
{
45+
46+
"name": "Zotero Format Metadata",
47+
"update_json": "https://example.com/path/to/update.json",
48+
"description": "A useful Zotero plugin.",
49+
"homepage": "https://github.com/northword/zotero-format-metadata",
50+
"tags": ["metadata"]
51+
}
52+
```
5153

52-
```bash
53-
pnpm run build
54-
```
54+
## Development Guide
5555

56-
4. After building, `meta.generated.json` and `latest.json` files will be created inside each plugin directory, ready for deployment or frontend consumption.
56+
Before starting development, you need to create a [GitHub personal access token](https://docs.github.com/zh/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens) and store it in the local environment variable `GITHUB_TOKEN`.
5757

58-
## Build Script Usage
58+
```bash
59+
# Clone the repository
60+
git clone https://github.com/zotero-plugin-dev/zotero-plugin-registry.git
61+
cd zotero-plugin-registry
5962

60-
- Build all plugins:
63+
# Install dependencies
64+
corepack enable
65+
pnpm install
6166

62-
```bash
67+
# Build all plugins:
6368
pnpm run build
69+
70+
# Build a specific plugin by ID:
71+
pnpm run --only [email protected]
6472
```
6573

66-
- Build a specific plugin by ID:
74+
After script run, `meta.generated.json` and `latest.json` files will be created inside each plugin directory, ready for deployment or frontend consumption.
6775

68-
```bash
69-
pnpx ts-node scripts/build.ts --only [email protected]
70-
```
76+
> [!NOTE]
77+
>
78+
> How to use this project as a dependency for secondary development?
79+
>
80+
> Developers can use the dist files like `index.json` from the `publish` branch.
7181
7282
## Contributing
7383

0 commit comments

Comments
 (0)