File size: 945 Bytes
6823db2
 
 
 
1286203
6823db2
1286203
6823db2
1286203
6823db2
ded6a94
6823db2
ded6a94
 
6823db2
ded6a94
badbe89
ded6a94
6823db2
ded6a94
6823db2
ded6a94
badbe89
6823db2
1286203
6823db2
1286203
b31e292
ded6a94
b31e292
ded6a94
b31e292
 
6823db2
 
 
 
 
 
 
 
4897adc
 
 
 
 
 
8e37bff
6823db2
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
import os
import time
import shutil
import subprocess

# command = ["pip", "install", "flet==0.23.2"]

# subprocess.run(command, check=True)

# command = ["pip", "install", "flet-fastapi==0.19.0", "--no-deps"]

# subprocess.run(command, check=True)


gh_token = os.getenv("gh_token")

url_with_token = f"https://{gh_token}@github.com/Eslam-Magdy-1297/ZP-Dashboard.git"

os.system(f"git clone {url_with_token}")

time.sleep(10)

source_dir = "ZP-Dashboard"
destination_dir = "."

import os

current_directory = os.getcwd()

items = os.listdir(current_directory)

for item in items:
    print(item)
    
for item in os.listdir(source_dir):
    s = os.path.join(source_dir, item)
    d = os.path.join(destination_dir, item)
    shutil.move(s, d)

os.rmdir(source_dir)

directory = "."

# List all files and directories
for item in os.listdir(directory):
    print(item)
    
with open("index.py", "r") as file:
    code = file.read()
    exec(code)