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: add opt-in --preserve-generated-from option #940

Merged
merged 4 commits into from
Oct 3, 2023

Conversation

JoshuaKGoldberg
Copy link
Owner

PR Checklist

Overview

GitHub doesn't have a unified "create a new blank repository" API. So unless the new --preserve-generated-from option is true, repo creation will check whether the authenticated user has the same login as the --owner option, then use either createForAuthenticatedUser or `createInOrg.

Slightly rephrases the end-of-README notice while I'm here to remove my username from it. And in doing so, expands the "does the notice already exist?" logic to check previous variants.

@codecov
Copy link

codecov bot commented Oct 3, 2023

Codecov Report

Merging #940 (59ad618) into main (766a735) will increase coverage by 0.11%.
The diff coverage is 98.21%.

@@            Coverage Diff             @@
##             main     #940      +/-   ##
==========================================
+ Coverage   93.34%   93.46%   +0.11%     
==========================================
  Files          90       91       +1     
  Lines        4809     4850      +41     
  Branches      401      405       +4     
==========================================
+ Hits         4489     4533      +44     
+ Misses        319      316       -3     
  Partials        1        1              
Flag Coverage Δ
create 71.16% <38.18%> (-0.31%) ⬇️
initialize 38.18% <38.18%> (-0.03%) ⬇️
migrate 70.02% <40.00%> (-0.30%) ⬇️
unit 68.07% <98.21%> (+0.35%) ⬆️

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

Files Coverage Δ
src/shared/options/args.ts 100.00% <100.00%> (ø)
src/shared/options/createRepositoryWithApi.ts 100.00% <100.00%> (ø)
src/shared/options/ensureRepositoryExists.ts 93.33% <100.00%> (ø)
src/shared/options/optionsSchema.ts 100.00% <100.00%> (ø)
src/shared/options/readOptions.ts 94.14% <100.00%> (+1.87%) ⬆️
src/steps/updateReadme.ts 100.00% <100.00%> (ø)
src/steps/writeReadme/index.ts 100.00% <100.00%> (ø)
src/shared/types.ts 0.00% <0.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@JoshuaKGoldberg JoshuaKGoldberg merged commit fc1eda7 into main Oct 3, 2023
16 checks passed
@JoshuaKGoldberg JoshuaKGoldberg deleted the preserve-generated-from-option branch October 3, 2023 13:07
@github-actions
Copy link

github-actions bot commented Oct 3, 2023

🎉 This is included in version v1.35.0 🎉

The release is available on:

Cheers! 📦🚀

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.

🚀 Feature: Add option to remove "generated from" notice from created repositories
1 participant