diff --git a/CB/Core.py b/CB/Core.py index 70be5c9..0879c2d 100644 --- a/CB/Core.py +++ b/CB/Core.py @@ -88,8 +88,8 @@ def parse_url(self, url): raise NotImplementedError('Provided URL is not supported.') def add_addon(self, url): - if 'curse://' in url: - url = url.split('/download-client')[0].replace('curse://', 'https://').strip() + if 'twitch://' in url: + url = url.split('/download-client')[0].replace('twitch://', 'https://').strip() addon = self.check_if_installed(url) if not addon: new = self.parse_url(url) @@ -217,10 +217,10 @@ def search(self, query): def create_reg(self): with open('CurseBreaker.reg', 'w') as outfile: - outfile.write('Windows Registry Editor Version 5.00\n[HKEY_CURRENT_USER\Software\Classes\curse]\n"URL Proto' - 'col"="\\"\\""\n@="\\"URL:CurseBreaker Protocol\\""\n[HKEY_CURRENT_USER\Software\Classes\curs' - 'e\DefaultIcon]\n@="\\"CurseBreaker.exe,1\\""\n[HKEY_CURRENT_USER\Software\Classes\curse\shel' - 'l]\n[HKEY_CURRENT_USER\Software\Classes\curse\shell\open]\n[HKEY_CURRENT_USER\Software\Class' - 'es\curse\shell\open\command]\n@="\\"' + os.path.abspath(sys.executable).replace('\\', '\\\\') - + '\\" \\"%1\\""') + outfile.write('Windows Registry Editor Version 5.00\n[HKEY_CURRENT_USER\Software\Classes\\twitch]\n"URL Pro' + 'tocol"="\\"\\""\n@="\\"URL:CurseBreaker Protocol\\""\n[HKEY_CURRENT_USER\Software\Classes\\t' + 'witch\DefaultIcon]\n@="\\"CurseBreaker.exe,1\\""\n[HKEY_CURRENT_USER\Software\Classes\\twitc' + 'h\shell]\n[HKEY_CURRENT_USER\Software\Classes\\twitch\shell\open]\n[HKEY_CURRENT_USER\Softwa' + 're\Classes\\twitch\shell\open\command]\n@="\\"' + + os.path.abspath(sys.executable).replace('\\', '\\\\') + '\\" \\"%1\\""') diff --git a/CB/__init__.py b/CB/__init__.py index 9998515..68b8204 100644 --- a/CB/__init__.py +++ b/CB/__init__.py @@ -1,4 +1,4 @@ -__version__ = '1.4.0' +__version__ = '1.4.1' __license__ = 'GPLv3' __copyright__ = '2019, Paweł Jastrzębski ' __docformat__ = 'restructuredtext en' diff --git a/CurseBreaker.py b/CurseBreaker.py index 7ea8c0a..bb95d03 100644 --- a/CurseBreaker.py +++ b/CurseBreaker.py @@ -48,7 +48,7 @@ def start(self): self.setup_completer() self.setup_table() # Curse URI Support - if len(sys.argv) == 2 and 'curse://' in sys.argv[1]: + if len(sys.argv) == 2 and 'twitch://' in sys.argv[1]: try: self.c_install(sys.argv[1].strip()) except Exception as e: