Skip to content

fix(pack): ignore .oo-thumbnail.json #63

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 2, 2025
Merged

fix(pack): ignore .oo-thumbnail.json #63

merged 1 commit into from
Apr 2, 2025

Conversation

BlackHole1
Copy link
Member

No description provided.

@BlackHole1 BlackHole1 requested a review from Copilot April 2, 2025 13:27
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR aims to address packaging behavior for .oo-thumbnail.json as indicated in the title. Key changes include test fixture additions, updates to package file generation in npm.ts with corresponding tests, and an additional test in the pack command to validate the packaged files.

Reviewed Changes

Copilot reviewed 5 out of 7 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
tests/fixtures/pack_ignore/src/index.ts Adds a basic fixture file.
tests/fixtures/pack_ignore/package.oo.yaml Introduces a test package fixture.
src/utils/npm.ts Updates package files list to include .oo-thumbnail.json.
src/utils/npm.test.ts Adjusts tests to reflect the inclusion of .oo-thumbnail.json.
src/cmd/pack.test.ts Adds a test to validate that the tar archive includes .oo-thumbnail.json.
Files not reviewed (2)
  • tests/fixtures/pack_ignore/.gitignore: Language not supported
  • tests/fixtures/pack_ignore/package.json: Language not supported
Comments suppressed due to low confidence (1)

src/cmd/pack.test.ts:104

  • This test expects the tar archive to contain 'package/package/.oo-thumbnail.json', which appears to duplicate the 'package' folder structure and deviates from the intended file exclusion suggested by the PR title. Verify if this double nesting is correct or if the file should be omitted.
            expect(result).toContainEqual("package/package/.oo-thumbnail.json");

Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the packaging functionality to handle the .oo-thumbnail.json file correctly during packaging.

  • Updates the package.json generation logic to include "package/.oo-thumbnail.json".
  • Enhances test coverage to explicitly verify that .oo-thumbnail.json is present in the package tarball.
  • Adds a new test fixture and package configuration for the pack_ignore scenario.

Reviewed Changes

Copilot reviewed 5 out of 9 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tests/fixtures/pack_ignore/src/index.ts Added a simple fixture comment ("// PASS") for the pack_ignore tests
tests/fixtures/pack_ignore/package.oo.yaml Introduces a minimal package configuration for testing the pack_ignore setup
src/utils/npm.ts Updates package file list to include the .oo-thumbnail.json file
src/utils/npm.test.ts Updates tests to verify that .oo-thumbnail.json is included during packaging
src/cmd/pack.test.ts Adds a new test case ensuring that .oo-thumbnail.json is not ignored
Files not reviewed (4)
  • tests/fixtures/pack_ignore/.oo-thumbnail.json: Language not supported
  • tests/fixtures/pack_ignore/_gitignore: Language not supported
  • tests/fixtures/pack_ignore/foo.txt: Language not supported
  • tests/fixtures/pack_ignore/package.json: Language not supported
Comments suppressed due to low confidence (1)

src/cmd/pack.test.ts:86

  • The test title indicates that .oo-thumbnail.json should be included, but the PR title suggests it should be ignored. Consider aligning the test description with the PR title for clarity.
it("should not ignore .oo-thumbnail.json", async (ctx) => {

@BlackHole1 BlackHole1 merged commit 71c1092 into main Apr 2, 2025
1 check passed
@BlackHole1 BlackHole1 deleted the fix-ignore branch April 2, 2025 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant