Browse Source

Cleanup: Typos, comments, error message, and debugs

pull/11/head
Ryan Reed 1 year ago
parent
commit
b520ea8bf9
3 changed files with 6 additions and 8 deletions
  1. +3
    -3
      README.md
  2. +1
    -1
      src/transpose/console.py
  3. +2
    -4
      tests/utils.py

+ 3
- 3
README.md View File

@ -14,7 +14,7 @@ A tool for moving and symlinking directories to a central location
* [Storing a Directory](#storing-a-directory) * [Storing a Directory](#storing-a-directory)
* [Restoring a Stored Directory](#restoring-a-stored-directory) * [Restoring a Stored Directory](#restoring-a-stored-directory)
* [Applying a Previously Transpose Managed Directory](#applying-a-previously-transpose-managed-directory) * [Applying a Previously Transpose Managed Directory](#applying-a-previously-transpose-managed-directory)
* [Modifying Tranpose Config Directly](#modifying-tranpose-config-directly)
* [Modifying Transpose Config Directly](#modifying-transpose-config-directly)
* [Development](#development) * [Development](#development)
<!-- vim-markdown-toc --> <!-- vim-markdown-toc -->
@ -107,9 +107,9 @@ transpose apply "Game1"
``` ```
### Modifying Tranpose Config Directly
### Modifying Transpose Config Directly
It's possible to modify the tranpose configuration file, `STORE_PATH/transpose.json`, using the console:
It's possible to modify the transpose configuration file, `STORE_PATH/transpose.json`, using the console:
``` ```
transpose config add "NewEntry" "/path/to/location" transpose config add "NewEntry" "/path/to/location"


+ 1
- 1
src/transpose/console.py View File

@ -13,7 +13,7 @@ def entry_point() -> None:
try: try:
run(args, config_path) run(args, config_path)
except TransposeError as e: except TransposeError as e:
print(f"Tranpose Error: {e}")
print(f"Transpose Error: {e}")
def run(args, config_path) -> None: def run(args, config_path) -> None:


+ 2
- 4
tests/utils.py View File

@ -79,8 +79,8 @@ def setup_store():
tests-temp/ tests-temp/
source/ source/
store/ store/
transpose-bad.json
transpose-invalid.json
transpose-bad.json
transpose-invalid.json
transpose.json transpose.json
""" """
try: try:
@ -95,13 +95,11 @@ def setup_store():
bad_config = '{"version": "1.0.0"}' # Missing entries bad_config = '{"version": "1.0.0"}' # Missing entries
with open(str(bad_config_path), "w") as f: with open(str(bad_config_path), "w") as f:
f.write(bad_config) f.write(bad_config)
assert bad_config_path.exists()
invalid_config_path = STORE_PATH.joinpath("transpose-invalid.json") invalid_config_path = STORE_PATH.joinpath("transpose-invalid.json")
invalid_config = "[{'invalidJSONFormat'}]" invalid_config = "[{'invalidJSONFormat'}]"
with open(str(invalid_config_path), "w") as f: with open(str(invalid_config_path), "w") as f:
f.write(invalid_config) f.write(invalid_config)
assert invalid_config_path.exists()
yield yield
finally: finally:


Loading…
Cancel
Save