Skip to content
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

feat(pack): add support for scaffolding new extensions #2041

Open
wants to merge 13 commits into
base: main
Choose a base branch
from

Conversation

sarthaksarthak9
Copy link
Contributor

@sarthaksarthak9 sarthaksarthak9 commented Jan 30, 2024

Add support for scaffolding new extensions

Output

Before

Screenshot from 2024-02-07 06-53-10

After

Screenshot from 2024-01-17 21-26-07

Documentation

  • Should this change be documented?
    • Yes, see #___
    • No

Related

Resolves #1636

@sarthaksarthak9 sarthaksarthak9 requested review from a team as code owners January 30, 2024 04:11
@github-actions github-actions bot added the type/enhancement Issue that requests a new feature or improvement. label Jan 30, 2024
@github-actions github-actions bot added this to the 0.33.0 milestone Jan 30, 2024
Copy link

codecov bot commented Jan 30, 2024

Codecov Report

Attention: Patch coverage is 41.54930% with 83 lines in your changes missing coverage. Please review.

Project coverage is 79.30%. Comparing base (e3f8bc2) to head (3401edf).
Report is 345 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2041      +/-   ##
==========================================
- Coverage   79.63%   79.30%   -0.32%     
==========================================
  Files         176      177       +1     
  Lines       13214    13367     +153     
==========================================
+ Hits        10522    10600      +78     
- Misses       2022     2093      +71     
- Partials      670      674       +4     
Flag Coverage Δ
os_linux 78.20% <41.55%> (-0.36%) ⬇️
os_macos 76.10% <41.55%> (-0.29%) ⬇️
os_windows 78.70% <41.55%> (-0.32%) ⬇️
unit 79.30% <41.55%> (-0.32%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

---- 🚨 Try these New Features:

@sarthaksarthak9 sarthaksarthak9 marked this pull request as draft January 30, 2024 13:22
@sarthaksarthak9 sarthaksarthak9 changed the title feat(pack): add support for scaffolding new extensions #2026 feat(pack): add support for scaffolding new extensions Feb 1, 2024
@sarthaksarthak9 sarthaksarthak9 marked this pull request as ready for review February 1, 2024 12:47
@jjbustamante jjbustamante modified the milestones: 0.33.0, 0.34.0 Feb 1, 2024
}

func (e *ExtensionDescriptor) EnsureStackSupport(_ string, _ []string, _ bool) error {
return nil
}

func (e *ExtensionDescriptor) EnsureTargetSupport(_, _, _, _ string) error {
return nil
func (e *ExtensionDescriptor) EnsureTargetSupport(os, arch, distroName, distroVersion string) error {
Copy link
Member

Choose a reason for hiding this comment

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

@jjbustamante are you aware of any existing logic we can re-use to validate that extensions support targets?

Copy link
Member

Choose a reason for hiding this comment

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

I think this code is similar to this one maybe we can try to refactor it and externalize it to be reuse in both places?

Copy link
Contributor Author

@sarthaksarthak9 sarthaksarthak9 Feb 4, 2024

Choose a reason for hiding this comment

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

@jjbustamante could you please give some clarification on the appropriate directory for storing the refactored files!! Any additional information about the specific files or workflow would be super helpful!!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@jjbustamante @natalieparellano I think a direct refactoring using a common function might not be feasible due to the structural differences (ExtensionDescriptor and BuildpackDescriptor). While the two structs share similarities, they do have some distinct fields.

Copy link
Member

@natalieparellano natalieparellano left a comment

Choose a reason for hiding this comment

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

@sarthaksarthak9 thank you for this, the PR is progressing nicely. I left a few comments :)

@sarthaksarthak9
Copy link
Contributor Author

@sarthaksarthak9 thank you for this, the PR is progressing nicely. I left a few comments :)

thank you for reviewing :)

remove the stack flag and update the commands
@github-actions github-actions bot modified the milestones: 0.37.0, 0.36.0 Nov 26, 2024
@jjbustamante jjbustamante modified the milestones: 0.36.0, 0.37.0 Nov 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/enhancement Issue that requests a new feature or improvement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

pack should support pack extension new
3 participants