config2py 0.1.31__py3-none-any.whl → 0.1.33__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
config2py/tools.py CHANGED
@@ -27,7 +27,18 @@ def get_configs_local_store(
27
27
  If it's a file, it's assumed to be an ini or cfg file.
28
28
  If it's a string, it's assumed to be an app name, from which to create a folder
29
29
  """
30
- if config_src != 'oa' and os.path.isdir(config_src):
30
+ if os.path.isdir(config_src):
31
+ # TODO: This was a quick fix to avoid unknowingly making directories in the
32
+ # wrong place. Broke stuff so leaving this for later.
33
+ # if os.path.sep not in config_src:
34
+ # raise ValueError(
35
+ # f"There's a directory named {config_src}, so I'm not sure if you want "
36
+ # f" me to make an 'app' folder or not. Please specify "
37
+ # f"{config_src + os.path.sep} if you want to use it as a folder. "
38
+ # f"If you want to make an 'app' folder for {config_src}, then call the "
39
+ # f"get_configs_local_store function from a directory that doesn't "
40
+ # "contain a {config_src} folder."
41
+ # )
31
42
  return TextFiles(config_src)
32
43
  elif os.path.isfile(config_src):
33
44
  # TODO: Not tested
@@ -37,7 +48,6 @@ def get_configs_local_store(
37
48
  from config2py.s_configparser import ConfigStore
38
49
 
39
50
  return ConfigStore(config_src)
40
-
41
51
  elif os.path.sep not in config_src: # it's just a string
42
52
  # TODO: is "get" the right word, since it makes the folder too
43
53
  path = get_configs_folder_for_app(config_src, configs_name=configs_name)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: config2py
3
- Version: 0.1.31
3
+ Version: 0.1.33
4
4
  Summary: Simplified reading and writing configurations from various sources and formats
5
5
  Home-page: https://github.com/i2mint/config2py
6
6
  Author: OtoSense
@@ -2,14 +2,14 @@ config2py/__init__.py,sha256=ru-bUQk5EuOLzHmNAcElSN8P2saSUEb5KFRkfTkzsUo,770
2
2
  config2py/base.py,sha256=saq1YVbeRg8jBoXcmc0y-maNJ5vHHeWwu5tc_EbOetE,15895
3
3
  config2py/errors.py,sha256=QdwGsoJhv6LHDHp-_yyz4oUg1Fgu4S-S7O2nuA0a5cw,203
4
4
  config2py/s_configparser.py,sha256=XhxFz6-PG4-QsecJfbjLFdBWHcPU6dwgqwkTZyY_y3E,15873
5
- config2py/tools.py,sha256=emjvqOGKx2PJwdndbjB0kKMFXO3HC3-twi7ge8UgXz8,8448
5
+ config2py/tools.py,sha256=6wPAdnossxMPeQ6T0eqUilP3VnHAfbrJcFsg4xmaahA,9137
6
6
  config2py/util.py,sha256=mzIsU2ozkatWx61NphsbD502IrwuI2Vi0V8NEjpNRXQ,15745
7
7
  config2py/scrap/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
8
8
  config2py/tests/__init__.py,sha256=sk-yGJQOZES2z70M4xmZB57tsxSktX_84ybDuV8Cz5Q,297
9
9
  config2py/tests/test_tools.py,sha256=T0rBy8s6wHgQXnnr7Z1xkF1so3XkdGVASerEQ27ByxE,1950
10
10
  config2py/tests/util.py,sha256=vO1VIepbH6vY2e-VHP7HX6jnVzzIDyFsp6md_uBnIXw,1351
11
- config2py-0.1.31.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
12
- config2py-0.1.31.dist-info/METADATA,sha256=YchbjtFSWD4kGhYUBAUBDdRpqKyo04LibFnAJsB5FZY,14559
13
- config2py-0.1.31.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
14
- config2py-0.1.31.dist-info/top_level.txt,sha256=DFnlOIKMIGWQRROr3voJFhWFViHaWgTTeWZjC5YC9QQ,10
15
- config2py-0.1.31.dist-info/RECORD,,
11
+ config2py-0.1.33.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
12
+ config2py-0.1.33.dist-info/METADATA,sha256=kg26LOTcSczZ0pjFwn6sHUtnJDPI6UO-Bhf8qDO0-2Q,14559
13
+ config2py-0.1.33.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
14
+ config2py-0.1.33.dist-info/top_level.txt,sha256=DFnlOIKMIGWQRROr3voJFhWFViHaWgTTeWZjC5YC9QQ,10
15
+ config2py-0.1.33.dist-info/RECORD,,