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

Make an initial commit when creating a Snap from template #1917

Merged
merged 2 commits into from
Nov 8, 2023

Conversation

ziad-saab
Copy link
Contributor

Note: merge this after #1916

When creating a new Snap using the create-snap CLI, we make an initial commit with the code of the template. This makes it easier for devs to see the changes they make as they start hacking on the template, without having to remember to make an initial commit manually.

This is similar to what's done by other "create" projects such as CRA.

Tested:

image

@ziad-saab ziad-saab requested a review from a team as a code owner November 3, 2023 06:27
Copy link

codecov bot commented Nov 3, 2023

Codecov Report

Attention: 10 lines in your changes are missing coverage. Please review.

Comparison is base (d533938) 96.19% compared to head (4dfcb59) 96.09%.
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1917      +/-   ##
==========================================
- Coverage   96.19%   96.09%   -0.10%     
==========================================
  Files         245      246       +1     
  Lines        5888     5999     +111     
  Branches      964      980      +16     
==========================================
+ Hits         5664     5765     +101     
- Misses        224      234      +10     
Files Coverage Δ
packages/create-snap/src/cmds/init/initHandler.ts 100.00% <100.00%> (ø)
packages/create-snap/src/cmds/init/initUtils.ts 100.00% <100.00%> (ø)
...ages/snaps-controllers/src/snaps/SnapController.ts 97.65% <100.00%> (ø)
packages/snaps-controllers/src/utils.ts 97.22% <100.00%> (+0.55%) ⬆️
...ges/snaps-simulator/src/features/manifest/sagas.ts 100.00% <100.00%> (ø)
...ages/snaps-simulator/src/features/polling/sagas.ts 95.08% <100.00%> (+0.74%) ⬆️
...lator/src/features/simulation/test/mockManifest.ts 100.00% <ø> (ø)
packages/snaps-utils/src/localization.ts 100.00% <100.00%> (ø)
packages/snaps-utils/src/manifest/manifest.ts 99.35% <100.00%> (+0.04%) ⬆️
packages/snaps-utils/src/manifest/validation.ts 100.00% <ø> (ø)
... and 6 more

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ziad-saab ziad-saab requested a review from Mrtenz November 6, 2023 04:55
Mrtenz
Mrtenz previously approved these changes Nov 6, 2023
@FrederikBolding
Copy link
Member

@ziad-saab Can you rebase this and resolve the conflict? Then we can merge

@ziad-saab ziad-saab force-pushed the zs/create-snap-initial-commit branch 2 times, most recently from 979d117 to fb1300b Compare November 8, 2023 05:53
@ziad-saab ziad-saab force-pushed the zs/create-snap-initial-commit branch from fb1300b to 24408e8 Compare November 8, 2023 06:01
@FrederikBolding FrederikBolding merged commit af4270f into main Nov 8, 2023
@FrederikBolding FrederikBolding deleted the zs/create-snap-initial-commit branch November 8, 2023 08:32
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.

3 participants