From 349320192af59e5f0ca01aa94d77fe4595616b56 Mon Sep 17 00:00:00 2001 From: Jade Clarke <45100065+jade-clarke@users.noreply.github.com> Date: Sun, 17 Apr 2022 14:45:46 -0400 Subject: [PATCH] Changed the DefaultSection constant to a variable so that it may be altered for use with aws cli configs. --- deprecated.go | 5 +---- ini.go | 8 ++++---- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/deprecated.go b/deprecated.go index e8bda06..48b8e66 100644 --- a/deprecated.go +++ b/deprecated.go @@ -14,12 +14,9 @@ package ini -const ( +var ( // Deprecated: Use "DefaultSection" instead. DEFAULT_SECTION = DefaultSection -) - -var ( // Deprecated: AllCapsUnderscore converts to format ALL_CAPS_UNDERSCORE. AllCapsUnderscore = SnackCase ) diff --git a/ini.go b/ini.go index ac2a93a..99e7f86 100644 --- a/ini.go +++ b/ini.go @@ -23,15 +23,15 @@ import ( ) const ( - // DefaultSection is the name of default section. You can use this constant or the string literal. - // In most of cases, an empty string is all you need to access the section. - DefaultSection = "DEFAULT" - // Maximum allowed depth when recursively substituing variable names. depthValues = 99 ) var ( + // DefaultSection is the name of default section. You can use this var or the string literal. + // In most of cases, an empty string is all you need to access the section. + DefaultSection = "DEFAULT" + // LineBreak is the delimiter to determine or compose a new line. // This variable will be changed to "\r\n" automatically on Windows at package init time. LineBreak = "\n"