ysb123 commited on
Commit
cfbfbdd
ยท
1 Parent(s): bf65b0a

Update a1111.py

Browse files
Files changed (1) hide show
  1. a1111.py +8 -7
a1111.py CHANGED
@@ -1,9 +1,10 @@
1
- from git import Repo
2
 
3
- # Clone a repository
4
  repo_url = 'https://github.com/AUTOMATIC1111/stable-diffusion-webui'
5
- local_path = './Repo'
6
- Repo.clone_from(repo_url, local_path)
7
-
8
- # The repository has been cloned successfully
9
- print("Repository cloned successfully! ๐Ÿ˜„")
 
 
 
1
+ import subprocess
2
 
 
3
  repo_url = 'https://github.com/AUTOMATIC1111/stable-diffusion-webui'
4
+ dest_path = './Repo'
5
+ # Run the git clone command
6
+ try:
7
+ subprocess.run(['git', 'clone', repo_url, dest_path], check=True)
8
+ print('Clone operation completed successfully! ๐Ÿ˜„')
9
+ except subprocess.CalledProcessError:
10
+ print('Clone operation failed! ๐Ÿ˜ž')