mirror of
https://github.com/arsenetar/dupeguru.git
synced 2026-03-11 19:21:39 +00:00
Compare commits
1 Commits
f26b515286
...
2714c2dc56
| Author | SHA1 | Date | |
|---|---|---|---|
|
2714c2dc56
|
@@ -96,8 +96,6 @@ class FilenameCategory(CriterionCategory):
|
||||
DOESNT_END_WITH_NUMBER = 1
|
||||
LONGEST = 2
|
||||
SHORTEST = 3
|
||||
LONGEST_PATH = 4
|
||||
SHORTEST_PATH = 5
|
||||
|
||||
def format_criterion_value(self, value):
|
||||
return {
|
||||
@@ -105,8 +103,6 @@ class FilenameCategory(CriterionCategory):
|
||||
self.DOESNT_END_WITH_NUMBER: tr("Doesn't end with number"),
|
||||
self.LONGEST: tr("Longest"),
|
||||
self.SHORTEST: tr("Shortest"),
|
||||
self.LONGEST_PATH: tr("Longest Path"),
|
||||
self.SHORTEST_PATH: tr("Shortest Path"),
|
||||
}[value]
|
||||
|
||||
def extract_value(self, dupe):
|
||||
@@ -120,10 +116,6 @@ class FilenameCategory(CriterionCategory):
|
||||
return 0 if ends_with_digit else 1
|
||||
else:
|
||||
return 1 if ends_with_digit else 0
|
||||
elif crit_value == self.LONGEST_PATH:
|
||||
return len(str(dupe.folder_path)) * -1
|
||||
elif crit_value == self.SHORTEST_PATH:
|
||||
return len(str(dupe.folder_path))
|
||||
else:
|
||||
value = len(value)
|
||||
if crit_value == self.LONGEST:
|
||||
@@ -138,8 +130,6 @@ class FilenameCategory(CriterionCategory):
|
||||
self.DOESNT_END_WITH_NUMBER,
|
||||
self.LONGEST,
|
||||
self.SHORTEST,
|
||||
self.LONGEST_PATH,
|
||||
self.SHORTEST_PATH,
|
||||
]
|
||||
]
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
[build-system]
|
||||
requires = ["setuptools >= 75.3.1"]
|
||||
requires = ["setuptools >= 61.0.0"]
|
||||
build-backend = "setuptools.build_meta"
|
||||
|
||||
[project]
|
||||
@@ -9,12 +9,13 @@ authors = [
|
||||
{name = "Andrew Senetar", email = "arsenetar@voltaicideas.net"}
|
||||
]
|
||||
readme = "README.md"
|
||||
license = "GPL-3.0-or-later"
|
||||
license-files = ["LICENSE"]
|
||||
requires-python = ">=3.7, <3.13"
|
||||
keywords = ["deduplication"]
|
||||
license = {text = "GPLv3"}
|
||||
classifiers = [
|
||||
"Development Status :: 5 - Production/Stable",
|
||||
"Intended Audience :: End Users/Desktop",
|
||||
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
|
||||
"Operating System :: MacOS :: MacOS X",
|
||||
"Operating System :: Microsoft :: Windows",
|
||||
"Operating System :: POSIX",
|
||||
@@ -27,7 +28,6 @@ classifiers = [
|
||||
"Programming Language :: Python :: 3.12",
|
||||
"Topic :: Desktop Environment :: File Managers",
|
||||
]
|
||||
requires-python = ">=3.7, <3.13"
|
||||
|
||||
dynamic = ["version"]
|
||||
|
||||
@@ -38,7 +38,7 @@ dependencies = [
|
||||
"PyQt5 >=5.15.0,<6.0; sys_platform != 'linux'",
|
||||
"pywin32>=304; sys_platform == 'win32'",
|
||||
"semantic-version>=2.0.0,<3.0.0",
|
||||
"Send2Trash>=1.8.2",
|
||||
"Send2Trash>=1.8.2,<2.0.0",
|
||||
"xxhash>=3.0.0,<4.0.0",
|
||||
]
|
||||
|
||||
@@ -57,7 +57,7 @@ build = [
|
||||
[project.urls]
|
||||
Homepage = "https://dupeguru.voltaicideas.net/"
|
||||
Documentation = "https://dupeguru.voltaicideas.net/help/en/"
|
||||
Repository = "https://github.com/arsenetar/dupeguru.git"
|
||||
Repository = "https://github.com/arsenetar/dupeguru/"
|
||||
Issues = "https://github.com/arsenetar/dupeguru/issues"
|
||||
Releases = "https://github.com/arsenetar/dupeguru/releases"
|
||||
|
||||
@@ -77,10 +77,3 @@ include = ["core", "hscommon", "qt"]
|
||||
|
||||
[tool.setuptools.dynamic]
|
||||
version = {attr = "core.__version__"}
|
||||
|
||||
[tool.setuptools]
|
||||
ext-modules = [
|
||||
{name = "core.pe._block", sources = ["core/pe/modules/block.c", "core/pe/modules/common.c"], include-dirs = ["core/pe/modules"]},
|
||||
{name = "core.pe._cache", sources = ["core/pe/modules/cache.c", "core/pe/modules/common.c"], include-dirs = ["core/pe/modules"]},
|
||||
{name = "qt.pe._block_qt", sources = ["qt/pe/modules/block.c"]},
|
||||
]
|
||||
|
||||
26
setup.py
Normal file
26
setup.py
Normal file
@@ -0,0 +1,26 @@
|
||||
from setuptools import setup, Extension
|
||||
from pathlib import Path
|
||||
|
||||
exts = [
|
||||
Extension(
|
||||
"core.pe._block",
|
||||
[
|
||||
str(Path("core", "pe", "modules", "block.c")),
|
||||
str(Path("core", "pe", "modules", "common.c")),
|
||||
],
|
||||
include_dirs=[str(Path("core", "pe", "modules"))],
|
||||
),
|
||||
Extension(
|
||||
"core.pe._cache",
|
||||
[
|
||||
str(Path("core", "pe", "modules", "cache.c")),
|
||||
str(Path("core", "pe", "modules", "common.c")),
|
||||
],
|
||||
include_dirs=[str(Path("core", "pe", "modules"))],
|
||||
),
|
||||
Extension("qt.pe._block_qt", [str(Path("qt", "pe", "modules", "block.c"))]),
|
||||
]
|
||||
|
||||
headers = [str(Path("core", "pe", "modules", "common.h"))]
|
||||
|
||||
setup(ext_modules=exts, headers=headers)
|
||||
Reference in New Issue
Block a user