Skip to content

Releases: douglasmiranda/gconfigs

gConfigs 2.0.0

Choose a tag to compare

@douglasmiranda douglasmiranda released this 04 May 04:07
2.0.0
2dfe005

2.0.0 - 2026-05-04

What's New

  • Added support for TOML and INI files.
  • Improved casting and management of the output of configuration values.

Breaking Changes

  • Signatures of cast functions have changed.
  • Main call signature of GConfigs.get() has changed to require keyword arguments for anything other than the key.
  • Minimum Python version is now 3.11.

Examples

import gconfigs

# OLD:
envs.as_bool("DEBUG", default=False)
# NEW:
envs("DEBUG", default=False, cast=bool)

Commit Summary

  • feat: Add TOML file support. 3d448ee
  • feat: Add INI file support with parser. ef66a54
  • feat: Add error handling for invalid value casting in ValueOutput. 0ce215b
  • feat: Ensure iterator resets for multiple iterations in GConfigs. 404bd2b
  • feat: Enhance GConfigs with output formatting and type casting capabilities. 8676441
  • feat: Update permissions and fix attest action in publish workflow 75da569

Full Changelog: 1.1.2...2.0.0

gConfigs 1.1.2

Choose a tag to compare

@douglasmiranda douglasmiranda released this 01 May 04:07
1.1.2
2e68626

1.1.2 - 2026-05-01

What's Changed

  • feat: Implemented clearer boundaries for LocalFiles backend. fe3bfa8
    • Do not allow path traversal.
    • Do not allow access to nested paths.
    • Better permission checking.
    • Added info about those things to README.
  • Other minor dev things.

Full Changelog: 1.1.1...1.1.2

gConfigs 1.1.1

Choose a tag to compare

@douglasmiranda douglasmiranda released this 01 May 01:37
1.1.1
794f3c4

1.1.1 - 2026-04-30

Commit Summary

  • fix: Update changelog generation to include commit links f0f0ddb
  • fix: Parse dotenv files in a better way. 621a4d5
  • refactor: Sets the backend on GConfigs init in a more pleasing to the eye manner. fb12062
  • fix: Update documentation for .keys method implementation in backends.py 50cfb16
  • fix: Update release task to include uv.lock in git add. 2a919d7
  • fix: Update gconfigs version to 1.1.0 in uv.lock 6b9404c

Full Changelog: 1.1.0...1.1.1

gConfigs 1.1.0

Choose a tag to compare

@douglasmiranda douglasmiranda released this 30 Apr 05:00
1.1.0
91a7100

1.1.0 - 2026-04-30

What's Changed

Oh well... I did forget to upgrade pytest and pytest-cov. This even bumps the minimum Python version to 3.10.

Semver-wise, this is a breaking change, but I don't expect it to cause any issues in practice. If you are still on Python 3.8 or 3.9, you can just stick to gConfigs 1.0.0, which will continue to work fine.

Just copy what's under src/gconfigs/ into your project and avoid the dependency entirely and be happy. It works in even older Python versions.

Commit Summary

  • fix: Upgrade pytest and pytest-cov. (d018d98)

Full Changelog: 1.0.0...1.1.0

gConfigs 1.0.0

Choose a tag to compare

@douglasmiranda douglasmiranda released this 30 Apr 04:31
1.0.0
811f6b0

1.0.0 - 2026-04-30

What's Changed

The core functionality of gConfigs remains the same, but there have been some significant changes in the user API.

Demo:

import gconfigs

# 1) Environment variables
envs = gconfigs.envs()
debug = envs.as_bool("DEBUG", default=False)
home = envs("HOME", default="/")

# 2) Mounted directory (for configs or secrets)
configs = gconfigs.local_files("/run/configs")
language_code = configs("LANGUAGE_CODE", default="en-us")

# 3) Single local file
secrets = gconfigs.local_file()
db_password = secrets("/run/secrets/DB_PASSWORD")

# 4) Dotenv file
dotenvs = gconfigs.dotenvs(".env")
project_name = dotenvs("PROJECT_NAME", default="my-app")

API Overview

The package exposes four factory functions:

  • gconfigs.envs() -> reads from process environment variables
  • gconfigs.dotenvs(filepath=".env") -> reads from dotenv files
  • gconfigs.local_files(path="/run/configs", pattern="*") -> reads from files in a directory
  • gconfigs.local_file() -> reads from a single file path provided at call time

Each factory returns a GConfigs instance.

Check the README for more details.

Full Changelog: v0.1.5...1.0.0

v0.1.5 - New use_instead option!

Choose a tag to compare

@douglasmiranda douglasmiranda released this 11 Apr 03:44
5f6ca74

v0.1.5 (2019-04-10)

Hey, long time no see. I've been using gConfigs in some projects, and it works fine, that's why there was no update in a long time, but now it was time to go back and make some improvements.

  • Don't raise an exception when the dotenv file is empty #3
  • New use_instead option. #4 docs
  • Added CODE OF CONDUCT!
  • Dev: Using Poetry; Some Travis changes; Some updates to Makefile;

Love Django and Docker? You may want to take a look at my new repo: https://github.com/douglasmiranda/ddpt

Open sourcing gConfigs

Pre-release

Choose a tag to compare

@douglasmiranda douglasmiranda released this 09 Apr 05:46
51f7623

gConfigs logo

gConfigs, something like "get configs".

It's an configs parser.

You can get your configs from environment variables, local mounted files and .env (dotenv) files.

So, just install and try it.

$ pip install gconfigs
$ # or
$ pipenv install gconfigs

So help me find bugs, and let's discuss possible new backends to implement.