Repository navigation
Conversation
Upstream github.com/ettle/strcase (v0.2.0) is no longer maintained. Copy the sources the repo actually uses into internal/strcase, keeping the package API frozen; upstream MIT license text and copyright notice are preserved in internal/strcase/LICENSE as the license requires. Only env/util.go imported the package; behavior is verified by the vendored upstream test suite (caser/strcase/unicode tests) plus the existing env/config tests.
Fast Fallback has been enabled by default since Go 1.12; the field is deprecated and fails staticcheck SA1019 on CI.
Contributor
Author
4 tasks done
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Internalizes
github.com/ettle/strcase(v0.2.0) asinternal/strcasebecause the upstream project is no longer maintained. The upstream is MIT licensed; the license text and copyright notice are preserved ininternal/strcase/LICENSEas the MIT license requires.Changes
internal/strcase(caser, split, convert, initialisms, unicode helpers, package-level wrappers), with upstream tests (caser_test.go,strcase_test.go,unicode_test.go) kept as the behavioral spec. CLI, docs and the rest of the upstream repo were dropped.internal/strcase/doc.go(upstream, version, license, do-not-extend policy).env/util.go, to the internal import path.go mod tidydropsgithub.com/ettle/strcasefrom go.mod/go.sum.No behavioral change: key normalization in
env(T2HOST→T2_HOSTetc.) is verified unchanged by the vendored upstream test suite plus the existingenv/configtests.Testing
go test ./internal/strcase/)go build ./...,go test ./env/ ./config/,go vet ./...cleangolangci-lint runrepo-wide: 0 issues