ᴊ
.github
key: apply ValueMapper to substituted reference values (#382)
testdata
Optimize `Key.Strings` by reducing memory re-allocations and simplifying control flow (#385)
.editorconfig
Return an empty array from `ValueWithShadows` if there is none (#313)
.gitignore
github: refurbish issue forms and pull request templates (#312)
.golangci.yml
key: apply ValueMapper to substituted reference values (#382)
bench_test.go
Optimize `Key.Strings` by reducing memory re-allocations and simplifying control flow (#385)
codecov.yml
chore: various config updates to CI (#322)
data_source.go
key: apply ValueMapper to substituted reference values (#382)
deprecated.go
ini: allow changing the default section name (#319)
error.go
parser: fix line skipping when key is empty (#323)
file_test.go
key: apply ValueMapper to substituted reference values (#382)
file.go
key: apply ValueMapper to substituted reference values (#382)
go.mod
chore: enable Go modules and modernize CI (#374)
go.sum
chore: enable Go modules and modernize CI (#374)
helper_test.go
all: rewrite tests to use testify instead of goconvey (#300)
helper.go
*: some move around
ini_test.go
key: apply ValueMapper to substituted reference values (#382)
ini.go
ini: allow changing the default section name (#319)
key_test.go
key: apply ValueMapper to substituted reference values (#382)
key.go
Optimize `Key.Strings` by reducing memory re-allocations and simplifying control flow (#385)
LICENSE
license: update indeitfy information
Makefile
data_source: support io.Reader
parser_test.go
test: rename package to be same as the main (#304)
parser.go
Fix parsing of double-quoted values with backslash continuations (#373)
README.md
README: fix up dead links
section_test.go
test: rename package to be same as the main (#304)
section.go
section: preallocate the size of keys hash (#297)
struct_test.go
chore: enable Go modules and modernize CI (#374)
struct.go
key: apply ValueMapper to substituted reference values (#382)

INI

Package ini provides INI file read and write functionality in Go.

Features

  • Load from multiple data sources(file, []byte, io.Reader and io.ReadCloser) with overwrites.
  • Read with recursion values.
  • Read with parent-child sections.
  • Read with auto-increment key names.
  • Read with multiple-line values.
  • Read with tons of helper methods.
  • Read and convert values to Go types.
  • Read and WRITE comments of sections and keys.
  • Manipulate sections, keys and comments with ease.
  • Keep sections and keys in order as you parse and save.

Installation

The minimum requirement of Go is 1.13.

$ go get gopkg.in/ini.v1@latest

NOTE

If you previously used github.com/go-ini/ini as the import path in your project, without updating all of your code, you can use the following command to replace the import path in your go.mod:

go mod edit -replace github.com/go-ini/ini=gopkg.in/ini.v1@latest

Getting Help

License

This project is under Apache v2 License. See the LICENSE file for the full license text.