Skip to content

Commit e502fdf

Browse files
authored
update RAM initialism (#331)
Issue #, if available: aws-controllers-k8s/ec2-controller#52 Description of changes: * adds `Ramdisk` to initialisms because the source did not consistently camel case By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
1 parent 95f81d3 commit e502fdf

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

pkg/names/names.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,8 @@ var (
119119
{"Nat", "NAT", "nat", regexp.MustCompile("Nat(?!i)", regexp.None)},
120120
{"Oidc", "OIDC", "oidc", nil},
121121
{"Ocsp", "OCSP", "ocsp", nil},
122+
// Capitalize the 'd' following RAM in certain cases
123+
{"Ramdisk", "RAMDisk", "ramDisk", regexp.MustCompile("Ramdisk", regexp.None)},
122124
// Model fields starting with 'Ram' refer to RAM
123125
{"Ram", "RAM", "ram", regexp.MustCompile("Ram", regexp.None)},
124126
{"Rfc", "RFC", "rfc", nil},

pkg/names/names_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ func TestNames(t *testing.T) {
7070
{"Package", "Package", "package_", "package_"},
7171
{"Param", "Param", "param", "param"},
7272
{"Ram", "RAM", "ram", "ram"},
73+
{"RamdiskId", "RAMDiskID", "ramDiskID", "ram_disk_id"},
7374
{"RamDiskId", "RAMDiskID", "ramDiskID", "ram_disk_id"},
7475
{"RepositoryUriTest", "RepositoryURITest", "repositoryURITest", "repository_uri_test"},
7576
{"RequestedAmiVersion", "RequestedAMIVersion", "requestedAMIVersion", "requested_ami_version"},

0 commit comments

Comments
 (0)