Personal-use NixOS configuration
1diff --git a/pythonlib/camoufox/pkgman.py b/pythonlib/camoufox/pkgman.py
2index b6f0c3f..b168a73 100644
3--- a/pythonlib/camoufox/pkgman.py
4+++ b/pythonlib/camoufox/pkgman.py
5@@ -54,6 +54,8 @@ OS_NAME: Literal['mac', 'win', 'lin'] = OS_MAP[sys.platform]
6 INSTALL_DIR: Path = Path(user_cache_dir("camoufox"))
7 LOCAL_DATA: Path = Path(os.path.abspath(__file__)).parent
8
9+STORE_DIR: Path = Path(LOCAL_DATA / "camoufox-bin")
10+
11 # The supported architectures for each OS
12 OS_ARCH_MATRIX: Dict[str, List[str]] = {
13 'win': ['x86_64', 'i686'],
14@@ -326,10 +328,12 @@ class CamoufoxFetcher(GitHubDownloader):
15
16 # Fetch the latest zip
17 with tempfile.NamedTemporaryFile() as temp_file:
18- self.download_file(temp_file, self.url)
19- self.extract_zip(temp_file)
20+ #self.download_file(temp_file, self.url)
21+ #self.extract_zip(temp_file)
22 self.set_version()
23
24+ shutil.copytree(STORE_DIR, INSTALL_DIR, dirs_exist_ok=True)
25+
26 # Set permissions on INSTALL_DIR
27 if OS_NAME != 'win':
28 os.system(f'chmod -R 755 {shlex.quote(str(INSTALL_DIR))}') # nosec