-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
v0.2.31: Fixed environment variable handling in Config class
- Loading branch information
Showing
5 changed files
with
110 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,27 +22,27 @@ def run(self): | |
|
||
# Get package directory | ||
pkg_dir = Path(__file__).parent | ||
|
||
# Get installation directory (where user ran pip install) | ||
install_dir = Path.cwd() | ||
|
||
# Files to copy | ||
core_dirs = ['pynions', 'workflows', 'docs', 'tests', 'data'] | ||
core_dirs = ["pynions", "workflows", "docs", "tests", "data"] | ||
config_files = [ | ||
('.env.example', '.env'), | ||
('pynions.example.json', 'pynions.json'), | ||
('README.md', 'README.md'), | ||
('requirements.txt', 'requirements.txt'), | ||
('pytest.ini', 'pytest.ini') | ||
(".env.example", ".env"), | ||
("pynions.example.json", "pynions.json"), | ||
("README.md", "README.md"), | ||
("requirements.txt", "requirements.txt"), | ||
("pytest.ini", "pytest.ini"), | ||
] | ||
|
||
# Copy core directories | ||
for dir_name in core_dirs: | ||
src_dir = pkg_dir / dir_name | ||
dst_dir = install_dir / dir_name | ||
if src_dir.exists() and not dst_dir.exists(): | ||
shutil.copytree(src_dir, dst_dir) | ||
|
||
# Copy config files | ||
for src_name, dst_name in config_files: | ||
src = pkg_dir / src_name | ||
|
@@ -66,7 +66,7 @@ def run(self): | |
|
||
setup( | ||
name="pynions", | ||
version="0.2.30", | ||
version="0.2.31", | ||
author="Tomas Laurinavicius", | ||
author_email="[email protected]", | ||
description="Simple marketing automation framework", | ||
|
@@ -85,15 +85,52 @@ def run(self): | |
"../pynions.example.json", | ||
"../README.md", | ||
"../requirements.txt", | ||
"../pytest.ini" | ||
"../pytest.ini", | ||
], | ||
}, | ||
data_files=[ | ||
(".", [".env.example", "pynions.example.json", "README.md", "requirements.txt", "pytest.ini"]), | ||
("workflows", ["workflows/example_workflow.py", "workflows/content_analysis_workflow.py", "workflows/research_workflow.py", "workflows/alternatives_writer.py"]), | ||
("docs", [f"docs/{f}" for f in ["changelog.md", "configuration.md", "data-organization.md", "debugging.md", "index.md", "installation.md", "nav.json", "plugins.md", "project-structure.md", "quickstart.md", "testing.md", "workers.md", "workflows.md"]]), | ||
("data", ["data/air.md"]), | ||
("tests", ["tests/test_config.py"]) | ||
( | ||
".", | ||
[ | ||
".env.example", | ||
"pynions.example.json", | ||
"README.md", | ||
"requirements.txt", | ||
"pytest.ini", | ||
], | ||
), | ||
( | ||
"workflows", | ||
[ | ||
"workflows/example_workflow.py", | ||
"workflows/content_analysis_workflow.py", | ||
"workflows/research_workflow.py", | ||
"workflows/alternatives_writer.py", | ||
], | ||
), | ||
( | ||
"docs", | ||
[ | ||
f"docs/{f}" | ||
for f in [ | ||
"changelog.md", | ||
"configuration.md", | ||
"data-organization.md", | ||
"debugging.md", | ||
"index.md", | ||
"installation.md", | ||
"nav.json", | ||
"plugins.md", | ||
"project-structure.md", | ||
"quickstart.md", | ||
"testing.md", | ||
"workers.md", | ||
"workflows.md", | ||
] | ||
], | ||
), | ||
("data", []), | ||
("tests", ["tests/test_config.py"]), | ||
], | ||
install_requires=requirements, | ||
cmdclass={ | ||
|