-
Notifications
You must be signed in to change notification settings - Fork 123
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #83 from Folltoshe/main
chore: 优化启动脚本
- Loading branch information
Showing
4 changed files
with
36 additions
and
38 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 was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import os | ||
import argparse | ||
import subprocess | ||
|
||
|
||
if __name__ == "__main__": | ||
parser = argparse.ArgumentParser(description="Script to set environment variables and run different environments.") | ||
parser.add_argument( | ||
"environment", | ||
choices=["production", "development"], | ||
nargs="?", | ||
default="production", | ||
help="Specify the environment to run.", | ||
) | ||
args = parser.parse_args() | ||
try: | ||
if args.environment: | ||
os.environ["CURRENT_ENV"] = args.environment | ||
subprocess.run(["python", "main.py"]) | ||
except KeyboardInterrupt: | ||
pass |
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 |
---|---|---|
|
@@ -9,16 +9,16 @@ | |
description = "Description not available" | ||
|
||
setup( | ||
name='lx_music_api_server_setup', | ||
name="lx_music_api_server_setup", | ||
version=version, | ||
scripts=['poetry_run.py'], | ||
author='helloplhm-qwq', | ||
author_email='[email protected]', | ||
scripts=["run.py"], | ||
author="helloplhm-qwq", | ||
author_email="[email protected]", | ||
description=description, | ||
url='https://github.com/helloplhm-qwq/lx-music-api-server', | ||
url="https://github.com/helloplhm-qwq/lx-music-api-server", | ||
classifiers=[ | ||
'Programming Language :: Python :: 3', | ||
'License :: OSI Approved :: MIT License', | ||
'Operating System :: OS Independent', | ||
"Programming Language :: Python :: 3", | ||
"License :: OSI Approved :: MIT License", | ||
"Operating System :: OS Independent", | ||
], | ||
) |