Skip to content

Commit c1afc88

Browse files
authored
Add .swiftpm/config/registries.json to default .gitignore (#3468)
As discussed in SE-0292, a user may inadvertently reveal the existence of a private registry or expose hardcoded credentials by checking in their project's .swiftpm/config/registries.json file or directory. By adding this entry to the .gitignore file in the new project template, we significantly minimize the possibility of the user leaking credentials in the future.
1 parent 23f435f commit c1afc88

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Sources/Workspace/InitPackage.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,7 @@ public final class InitPackage {
260260
/*.xcodeproj
261261
xcuserdata/
262262
DerivedData/
263+
.swiftpm/config/registries.json
263264
.swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata
264265
.netrc
265266

0 commit comments

Comments
 (0)