https://github.com/martinohmann/endure
Easily load and store values of arbitrary go types in files or other persistent storages
https://github.com/martinohmann/endure
go json persistence xml yaml
Last synced: about 2 months ago
JSON representation
Easily load and store values of arbitrary go types in files or other persistent storages
- Host: GitHub
- URL: https://github.com/martinohmann/endure
- Owner: martinohmann
- License: mit
- Created: 2019-01-18T14:13:52.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-01-18T14:24:16.000Z (over 7 years ago)
- Last Synced: 2025-02-01T02:42:57.970Z (over 1 year ago)
- Topics: go, json, persistence, xml, yaml
- Language: Go
- Homepage:
- Size: 8.79 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
endure
======
[](https://travis-ci.org/martinohmann/endure)
[](https://goreportcard.com/report/github.com/martinohmann/endure)
[](https://godoc.org/github.com/martinohmann/endure)
Easily load and store values of arbitrary go types in files or other persistent
storages. The main purpose of this library is to provide an easy-to-use
interface for reading and writing config and state files.
Endure supports marshalling to and unmarshalling from various encodings. It
provides ready-to-use helpers for json, xml and yaml. Other encodings can be
easily supported via pluggable marshal and unmarshal functions.
Installation
------------
```sh
go get -u github.com/martinohmann/endure
```
Usage
-----
Check out the [`examples`](examples) directory for common usage examples.
For an example of how to use custom encoding, have a look at [`custom_test.go`](custom_test.go).
License
-------
The source code of endure is released under the MIT License. See the bundled
LICENSE file for details.