Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/gajim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/.ci
diff options
context:
space:
mode:
authorPhilipp Hörist <philipp@hoerist.com>2023-01-07 18:12:06 +0300
committerPhilipp Hörist <philipp@hoerist.com>2023-01-07 18:12:06 +0300
commit937055b83552cd26087ceff4c6e04a15d5202e1e (patch)
tree70109b8892d5f07ceb8bbccfa4b9e0dc30284b97 /.ci
parent331a233021a03c2fc90e743558d97ebd9efd1ee8 (diff)
ci: Remove obsolete script
Diffstat (limited to '.ci')
-rwxr-xr-x.ci/link-gtk.py55
1 files changed, 0 insertions, 55 deletions
diff --git a/.ci/link-gtk.py b/.ci/link-gtk.py
deleted file mode 100755
index c7c0e7b7c..000000000
--- a/.ci/link-gtk.py
+++ /dev/null
@@ -1,55 +0,0 @@
-#!/usr/bin/env python
-
-# Creates links from gui folder to all files in the gtk folder
-# This is needed for pyright to work correctly with the dynamic gui imports
-
-import logging
-import sys
-from pathlib import Path
-
-IGNORED_FILES = ['__init__.py']
-IGNORED_DIRS = ['__pycache__']
-
-cwd = Path.cwd()
-
-if cwd.name != 'gajim':
- sys.exit('Script needs to be executed from gajim repository '
- 'root directory')
-
-gui_path = cwd / 'gajim' / 'gui'
-gtk_path = cwd / 'gajim' / 'gtk'
-
-
-logging.basicConfig(level='INFO', format='%(levelname)s: %(message)s')
-log = logging.getLogger()
-
-
-def cleanup_dir(target_dir: Path) -> None:
- for path in target_dir.iterdir():
- if path.name in IGNORED_FILES:
- continue
- if path.name in IGNORED_DIRS:
- continue
- path.unlink()
-
-
-def link(target: Path) -> None:
- source = str(target)
- source = source.replace('gajim/gtk', 'gajim/gui')
- source = Path(source)
- source.symlink_to(target)
- log.info('create symlink from %s -> %s', source, target)
-
-
-def link_files(source_dir: Path) -> None:
- for path in source_dir.iterdir():
- if path.is_dir():
- if path.name not in IGNORED_DIRS:
- link(path)
-
- elif path.name not in IGNORED_FILES:
- link(path)
-
-
-cleanup_dir(gui_path)
-link_files(gtk_path)