Skip to content

Commit

Permalink
Up version. Update readme. Add build and deploy script.
Browse files Browse the repository at this point in the history
  • Loading branch information
JMSchietekat committed Aug 11, 2021
1 parent 305f2a8 commit 5c23396
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,17 @@ The functionality described is in line with the guidelines set out in the [The T
```python
from local_env_vars.env import LocalEnvVars

env = EnvironmentManager("sql_server_address", "sql_username", "sql_password")
env = LocalEnvVars("sql_server_address", "sql_username", "sql_password")

connection_string = "Driver={{SQL Server}};Server={0}; Database=AdventureWorks;uid={1};pwd={2}".format(
env.vars['sql_server_address'], env.vars['sql_username'], env.vars['sql_password']
)
```

Running this code for the first time will create a `.env` file with the following content. It will throw an exception reporting that you must provide values to the keys.
Running this code for the first time will create an `.env` and add `.evn` to the project `.gitignore` file.

The `.env` file will have the following content. It will throw an exception reporting that you must provide values to the keys.

`{"sql_server_address": "", "sql_username": "", "sql_password": ""}`

After you have populated the keys with values you will be able to execute the code without any exceptions.



3 changes: 3 additions & 0 deletions scripts/build_and_deploy.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
rmdir dist -y
py -m build
twine upload dist/*
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = local-env-vars
version = 0.0.3
version = 0.0.4
author = Justin Schietekat
author_email = justinschietekat@gmail.com
description = A simple local environmental variable manager
Expand Down

0 comments on commit 5c23396

Please sign in to comment.