Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
tasshi-me committed Nov 1, 2024
1 parent 67bffa2 commit 39db43e
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/plugin/core/contents/__tests__/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ describe("ContentsZip", () => {
const manifestJSONPath = path.join(pluginDir, "manifest.json");
const manifest = await ManifestFactory.loadJsonFile(manifestJSONPath);

const contentsZip = await ContentsZip.createFromManifest(
const contentsZip = await ContentsZip.generateFromManifest(
manifest,
new LocalFSDriver(pluginDir),
);
Expand All @@ -30,7 +30,7 @@ describe("ContentsZip", () => {
const manifestJSONPath = path.join(pluginDir, "manifest.json");
const manifest = await ManifestFactory.loadJsonFile(manifestJSONPath);

const contentsZip = await ContentsZip.createFromManifest(
const contentsZip = await ContentsZip.generateFromManifest(
manifest,
new LocalFSDriver(pluginDir),
);
Expand Down
6 changes: 3 additions & 3 deletions src/plugin/core/contents/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { ManifestFactory } from "../manifest";

import type { DriverInterface } from "../driver";
import { ZipFileDriver } from "../driver";
import { createContentsZip } from "./zip";
import { generateContentsZip } from "./zip";

/**
* Contents represents the plugin source files aggregated by Manifest
Expand All @@ -25,11 +25,11 @@ export class ContentsZip extends ZipFileDriver implements ContentsInterface {
super(buffer);
}

public static async createFromManifest(
public static async generateFromManifest(
manifest: ManifestInterface,
driver: DriverInterface,
): Promise<ContentsZip> {
const buffer = await createContentsZip(manifest, driver);
const buffer = await generateContentsZip(manifest, driver);
// const buffer = await _createContentsZipStream(manifest, driver);
return ContentsZip.fromBuffer(buffer);
}
Expand Down
2 changes: 1 addition & 1 deletion src/plugin/core/contents/zip.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { logger } from "../../../utils/log";
/**
* Create a zipped contents
*/
export const createContentsZip = async (
export const generateContentsZip = async (
manifest: ManifestInterface,
driver: DriverInterface,
): Promise<Buffer> => {
Expand Down
2 changes: 1 addition & 1 deletion src/plugin/core/manifest/v1/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export class ManifestV1 implements ManifestInterface {
}

async generateContentsZip(driver: DriverInterface): Promise<ContentsZip> {
return ContentsZip.createFromManifest(this, driver);
return ContentsZip.generateFromManifest(this, driver);
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/plugin/core/manifest/v2/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export class ManifestV2 implements ManifestInterface {
}

async generateContentsZip(driver: DriverInterface): Promise<ContentsZip> {
return ContentsZip.createFromManifest(this, driver);
return ContentsZip.generateFromManifest(this, driver);
}
}

Expand Down

0 comments on commit 39db43e

Please sign in to comment.