generated from TBD54566975/tbd-project-template
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: avoid duplicate import aliases (#2502)
fixes #2469 When scaffolding imports for external go packages, FTL will use the shortest unique part of the path as the alias. This allows package aliases to have neat and expected aliases in simple cases, and falling back to the next best option as conflicts arise. For example: ``` import ( unique "github.com/two2/foo/unique.Type" one_foo_bar "github.com/one/foo/bar.Type" two_foo_bar "github.com/two/foo/bar.Type" ) ```
- Loading branch information
Showing
2 changed files
with
263 additions
and
83 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.