-
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.
- Loading branch information
1 parent
b121362
commit 682a878
Showing
1 changed file
with
30 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Stable Diffusion Exe | ||
# Python 3 | ||
# Execute stable diffusion .bat file | ||
|
||
import subprocess | ||
import os | ||
|
||
print('#-------------------------------------------#') | ||
print('# Stable Diffusion Quick Exe by SpawnTerror #') | ||
print('#-------------------------------------------#') | ||
print(f' ') | ||
current_dir = os.getcwd() | ||
print(f'Detecting current dir = ', current_dir) | ||
|
||
file_name = "webui-user.bat" | ||
file_path = current_dir + '\\' + file_name | ||
print(f'Generating the filepath = ', file_path) | ||
print(f' ') | ||
|
||
if os.path.exists(file_path): | ||
print(f'#-----------------------------------#') | ||
print(f'# Executing the webui-user.bat file #') | ||
print(f'#-----------------------------------#') | ||
print(f' ') | ||
os.chdir(current_dir) | ||
subprocess.call(file_path, shell=True) | ||
else: | ||
print(f'This exe has to be located within your \'stable-diffusion-webui\' folder!') | ||
input(f'Press any key to exit...') | ||
|