vorstcavry commited on
Commit
804e493
1 Parent(s): d242347

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -0
app.py CHANGED
@@ -87,6 +87,18 @@ Gitclone(r"https://github.com/NoCrypt/sd_hf_out",user_home / r"stable-diffusion-
87
  Gitclone(r"https://github.com/NoCrypt/ncpt_colab_timer",user_home / r"stable-diffusion-webui" / r"extensions" / r"ncpt_colab_timer")
88
  Gitclone(r"https://github.com/vorstcavry/static",user_home / r"stable-diffusion-webui" / r"static")
89
  !echo -n {start_huggingface} > /home/user/app/stable-diffusion-webui/static/colabTimer.txt
 
 
 
 
 
 
 
 
 
 
 
 
90
  #Gitclone(r"https://github.com/Iyashinouta/sd-model-downloader",user_home / r"stable-diffusion-webui" / r"extensions" / r"sd-model-downloader")
91
  #Gitclone(r"https://github.com/AIrjen/OneButtonPrompt",user_home / r"stable-diffusion-webui" / r"extensions" / r"OneButtonPrompt")
92
  #Gitclone(r"https://github.com/AUTOMATIC1111/stable-diffusion-webui-wildcards",user_home / r"stable-diffusion-webui" / r"extensions" / r"stable-diffusion-webui-wildcards")
 
87
  Gitclone(r"https://github.com/NoCrypt/ncpt_colab_timer",user_home / r"stable-diffusion-webui" / r"extensions" / r"ncpt_colab_timer")
88
  Gitclone(r"https://github.com/vorstcavry/static",user_home / r"stable-diffusion-webui" / r"static")
89
  !echo -n {start_huggingface} > /home/user/app/stable-diffusion-webui/static/colabTimer.txt
90
+
91
+ import subprocess
92
+
93
+ # Replace this with the desired text and file path
94
+
95
+ output_file = "/home/user/app/stable-diffusion-webui/static/colabTimer.txt"
96
+
97
+ try:
98
+ subprocess.run(["echo", "-n", {start_huggingface}], stdout=open(output_file, "w"), shell=True, check=True)
99
+ print(f"Text has been written to {output_file}")
100
+ except subprocess.CalledProcessError as e:
101
+ print(f"An error occurred: {e}")
102
  #Gitclone(r"https://github.com/Iyashinouta/sd-model-downloader",user_home / r"stable-diffusion-webui" / r"extensions" / r"sd-model-downloader")
103
  #Gitclone(r"https://github.com/AIrjen/OneButtonPrompt",user_home / r"stable-diffusion-webui" / r"extensions" / r"OneButtonPrompt")
104
  #Gitclone(r"https://github.com/AUTOMATIC1111/stable-diffusion-webui-wildcards",user_home / r"stable-diffusion-webui" / r"extensions" / r"stable-diffusion-webui-wildcards")