Skip to content

Add dotenv import to README#88

Merged
cdimascio merged 1 commit intocdimascio:masterfrom
razzius:master
Mar 15, 2026
Merged

Add dotenv import to README#88
cdimascio merged 1 commit intocdimascio:masterfrom
razzius:master

Conversation

@razzius
Copy link
Contributor

@razzius razzius commented Mar 15, 2026

When reading the README, I appreciated the simple and to-the-point documentation of how to get a dotenv value:

Dotenv dotenv = Dotenv.load();
dotenv.get("MY_ENV_VAR1")

However the full path of the import isn't anywhere in the readme (I found it in the example code). I figured other people might be looking for that in the readme, so I just added that line to the above example:

import io.github.cdimascio.dotenv.Dotenv;

I know some IDEs can import symbols like Dotenv automatically, and I'm also aware that those lines won't run directly since the import goes outside the class and the Dotenv.load() would go inside some sort of main method, so I'm open to adding a ... or otherwise restructuring that code snippet. What do you all think?

@cdimascio cdimascio merged commit f96c2ec into cdimascio:master Mar 15, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants