piclist 2.4.1 → 2.4.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/AGENTS.md ADDED
@@ -0,0 +1,36 @@
1
+ # Repository Guidelines
2
+
3
+ ## Project Structure & Module Organization
4
+
5
+ This is a TypeScript ESM package and CLI for PicList/PicGo-style image uploading. Source lives in `src/`, with `src/index.ts` as the package entry. Core runtime classes are in `src/core/`, shared helpers in `src/utils/`, CLI and plugin plumbing in `src/lib/` and `src/plugins/`, and type declarations in `src/types/`. Executable entrypoints are `bin/picgo` and `bin/picgo-server`. Tests mirror behavior under `test/`, using paths such as `test/utils/common.test.ts` and `test/plugins/uploader/utils.test.ts`. Static images are in `assets/`; generated build output goes to `dist/` and should not be edited directly.
6
+
7
+ ## Build, Test, and Development Commands
8
+
9
+ This repository currently tracks `yarn.lock`; use Yarn for consistency unless intentionally migrating package managers.
10
+
11
+ - `yarn build`: remove `dist/` and build production output with Rollup.
12
+ - `yarn dev`: run Rollup in watch mode for development.
13
+ - `yarn start`: run the `picgo` CLI from `bin/picgo`.
14
+ - `yarn server`: run the local server entrypoint.
15
+ - `yarn test`: run the Vitest suite once.
16
+ - `yarn test:watch`: run Vitest interactively.
17
+ - `yarn test:coverage`: generate V8 coverage reports.
18
+ - `yarn lint`: run ESLint across configured files.
19
+ - `yarn lint:dpdm`: fail on circular dependencies from `src/index.ts`.
20
+ - `yarn cz`: create a commit through the configured Commitizen flow.
21
+
22
+ ## Coding Style & Naming Conventions
23
+
24
+ Use TypeScript with ESM imports. Prettier enforces 2-space indentation, single quotes, no semicolons, trailing commas, and 120-column wrapping. ESLint requires sorted imports/exports, `eqeqeq`, `prefer-const`, object shorthand, Node protocol imports, and no unused variables unless prefixed with `_`. Keep module and utility filenames lower camel case where the existing tree does, such as `configManager.ts` and `eventBus.ts`.
25
+
26
+ ## Testing Guidelines
27
+
28
+ Vitest discovers `test/**/*.test.ts` with globals enabled and a 10-second timeout. Add focused tests next to the relevant behavior area under `test/`, and name files `*.test.ts`. Coverage includes `src/**/*.ts` and excludes `src/types/**` and `src/custom-env.d.ts`.
29
+
30
+ ## Commit & Pull Request Guidelines
31
+
32
+ Recent history uses emoji-prefixed conventional subjects, for example `:sparkles: Feature(custom): add new command...` and `:bug: Fix(custom): fix docker build issue...`. Prefer `yarn cz` so commitlint and release tooling stay aligned. Pull requests should include a concise summary, linked issues when applicable, validation commands/results, and screenshots or logs for CLI/server behavior changes.
33
+
34
+ ## Security & Configuration Tips
35
+
36
+ Never log secrets, tokens, private prompts, or private file contents. Before adding a production dependency, document why it is needed and summarize maintenance, license, security, Electron compatibility, and bundle/runtime impact.
@@ -26,6 +26,7 @@ export declare class Lifecycle extends EventEmitter {
26
26
  private addWatermark;
27
27
  private compressImage;
28
28
  private convertHeicAndCompress;
29
+ private convertHeicToJpegBuffer;
29
30
  private saveProcessedImage;
30
31
  private getFileBaseName;
31
32
  private buildInRename;