diff --git a/setup.py b/setup.py
index d5957bc..51cbf92 100644
--- a/setup.py
+++ b/setup.py
@@ -26,7 +26,7 @@ requirements.update(all=sorted(set().union(*requirements.values())))
 
 setup(
     name='yamlsettings',
-    version='2.0.3',
+    version='2.1.0',
     description='Yaml Settings Configuration Module',
     long_description=readme,
     author='Kyle James Walker',
diff --git a/yamlsettings/helpers.py b/yamlsettings/helpers.py
index 50193b2..151b843 100644
--- a/yamlsettings/helpers.py
+++ b/yamlsettings/helpers.py
@@ -49,7 +49,7 @@ def update_from_env(yaml_dict, prefix=None):
         env_path = "{0}{1}{2}".format(
             prefix.upper(),
             '_' if prefix else '',
-            '_'.join([str(key).upper() for key in path])
+            '_'.join([str(key).replace('-', '_').upper() for key in path])
         )
         env_val = os.environ.get(env_path, None)
         if env_val is not None:

Replace all non-variable characters to underscore in update_from_env
For example:
```python3
import os
import yamlsettings
from yamlsettings.yamldict import YAMLDict

os.environ['FOO_BAR'] = 'barbaz'

settings = YAMLDict({'foo-bar': None})
yamlsettings.update_from_env(settings)

assert settings['foo-bar'] == 'barbaz'
```
diff --git a/tests/test_yamldict.py b/tests/test_yamldict.py
index 66b44c0..747dfb9 100644
--- a/tests/test_yamldict.py
+++ b/tests/test_yamldict.py
@@ -12,7 +12,7 @@ import unittest
 
 from mock import mock_open
 from yamlsettings import (load, load_all, save_all,
-                          update_from_env, update_from_file)
+                          update_from_env, update_from_file, yamldict)
 
 from . import builtin_module, path_override, open_override, isfile_override
 
@@ -228,6 +228,14 @@ class YamlDictTestCase(unittest.TestCase):
         test_defaults.update({'a': (4,)})
         self.assertEqual(test_defaults.a, (4,))
 
+    @mock.patch.dict('os.environ', {'FOO_BAR': 'new-baz'})
+    def test_dash_vars_with_env(self):
+        """Test items with dashes can be overritten with env"""
+        test_settings = yamldict.YAMLDict({'foo-bar': 'baz'})
+        assert test_settings['foo-bar'] == 'baz'
+        update_from_env(test_settings)
+        assert test_settings['foo-bar'] == 'new-baz'
+
 
 if __name__ == '__main__':
     unittest.main()

pip install -e .[all]
parse_log_pytest
requirements.txt
pytest pytest-cov pytest-xdist flake8 pbr
3.7
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
certifi @ file:///croot/certifi_1671487769961/work/certifi
coverage==7.2.7
exceptiongroup==1.2.2
execnet==2.0.2
flake8==5.0.4
importlib-metadata==4.2.0
iniconfig==2.0.0
jedi==0.19.2
mccabe==0.7.0
mock==5.2.0
nose==1.3.7
packaging==24.0
parso==0.8.4
pbr==6.1.1
pluggy==1.2.0
pudb==2022.1.3
pycodestyle==2.9.1
pyflakes==2.5.0
Pygments==2.17.2
pytest==7.4.4
pytest-cov==4.1.0
pytest-mock==3.11.1
pytest-pudb==0.7.0
pytest-runner==6.0.1
pytest-xdist==3.5.0
PyYAML==6.0.1
six==1.17.0
tomli==2.0.1
typing_extensions==4.7.1
urwid==2.6.16
urwid-readline==0.15.1
wcwidth==0.2.13
-e git+https://github.com/KyleJamesWalker/yamlsettings.git@9a2c86590f867345b37e2dd91d8ecd2ef645c7d2#egg=yamlsettings
zipp==3.15.0

name: yamlsettings
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - certifi=2022.12.7=py37h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=1.1.1w=h7f8727e_0
  - pip=22.3.1=py37h06a4308_0
  - python=3.7.16=h7a1cb2a_0
  - readline=8.2=h5eee18b_0
  - setuptools=65.6.3=py37h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - wheel=0.38.4=py37h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - coverage==7.2.7
      - exceptiongroup==1.2.2
      - execnet==2.0.2
      - flake8==5.0.4
      - importlib-metadata==4.2.0
      - iniconfig==2.0.0
      - jedi==0.19.2
      - mccabe==0.7.0
      - mock==5.2.0
      - nose==1.3.7
      - packaging==24.0
      - parso==0.8.4
      - pbr==6.1.1
      - pluggy==1.2.0
      - pudb==2022.1.3
      - pycodestyle==2.9.1
      - pyflakes==2.5.0
      - pygments==2.17.2
      - pytest==7.4.4
      - pytest-cov==4.1.0
      - pytest-mock==3.11.1
      - pytest-pudb==0.7.0
      - pytest-runner==6.0.1
      - pytest-xdist==3.5.0
      - pyyaml==6.0.1
      - six==1.17.0
      - tomli==2.0.1
      - typing-extensions==4.7.1
      - urwid==2.6.16
      - urwid-readline==0.15.1
      - wcwidth==0.2.13
      - zipp==3.15.0
prefix: /opt/conda/envs/yamlsettings

tests/test_yamldict.py::YamlDictTestCase::test_dash_vars_with_env
tests/test_yamldict.py::YamlDictTestCase::test_clone_changes_isolated tests/test_yamldict.py::YamlDictTestCase::test_file_writing tests/test_yamldict.py::YamlDictTestCase::test_limit tests/test_yamldict.py::YamlDictTestCase::test_list_replace_on_update tests/test_yamldict.py::YamlDictTestCase::test_load_all tests/test_yamldict.py::YamlDictTestCase::test_load_first_found tests/test_yamldict.py::YamlDictTestCase::test_load_single_file tests/test_yamldict.py::YamlDictTestCase::test_load_with_envs tests/test_yamldict.py::YamlDictTestCase::test_rebase tests/test_yamldict.py::YamlDictTestCase::test_save_all tests/test_yamldict.py::YamlDictTestCase::test_stupid_override tests/test_yamldict.py::YamlDictTestCase::test_update tests/test_yamldict.py::YamlDictTestCase::test_update_from_file tests/test_yamldict.py::YamlDictTestCase::test_variable_override tests/test_yamldict.py::YamlDictTestCase::test_yaml_dict_merge
setup.py yamlsettings/helpers.py
setup.py yamlsettings/helpers.py