create Folder latest / move Update out of Version to rename

main
sebastian.serfling 2024-08-12 15:08:04 +02:00
parent ba564899b9
commit 293267e70c
3 changed files with 6 additions and 6 deletions

View File

@ -2,6 +2,6 @@
<project version="4"> <project version="4">
<component name="VcsDirectoryMappings"> <component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" /> <mapping directory="" vcs="Git" />
<mapping directory="$PROJECT_DIR$/latest" vcs="Git" /> <mapping directory="$PROJECT_DIR$/1.1" vcs="Git" />
</component> </component>
</project> </project>

View File

@ -20,15 +20,15 @@ print(current_version)
if current_version != new_version: if current_version != new_version:
try: try:
git.Repo.clone_from("http://172.17.1.251/sebastian.serfling/Agents.git",get_latest_release("","")) git.Repo.clone_from("http://172.17.1.251/sebastian.serfling/Agents.git",f'../{get_latest_release("","")}')
except: except:
next next
if os.path.isdir(f"{new_version}"): if os.path.isdir(f"../{new_version}"):
try: try:
shutil.move("latest", f"{current_version}") shutil.move("latest", f"../{current_version}")
except: except:
print("folder not Found") print("folder not Found")
os.rename(f"{new_version}", "latest") shutil.move(f"../{new_version}", "../latest")

View File

@ -1 +1 @@
1.0 1.1