File tree Expand file tree Collapse file tree 2 files changed +14
-3
lines changed
Expand file tree Collapse file tree 2 files changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -18,15 +18,18 @@ void AptCache::loadCacheFiles()
1818 const QString arch = getArch ();
1919
2020 // Define include and exclude regex patterns
21- const QRegularExpression includeRegex (QString (R"( ^.*binary-%1_Packages$)" ).arg (arch));
22- const QRegularExpression secondaryRegex (R"( ^.*_Packages$)" );
21+ const QRegularExpression allBinaryArchRegex (QString (R"( ^.*binary-%1_Packages$)" ).arg (arch));
22+ const QRegularExpression allBinaryAnyRegex (R"( ^.*binary-[a-z0-9]+_Packages$)" );
23+ const QRegularExpression allRegex (R"( ^.*_Packages$)" );
24+
2325 const QRegularExpression excludeRegex (
2426 R"( (debian_.*-backports_.*_Packages)|(mx_testrepo.*_test_.*_Packages)|(mx_repo.*_temp_.*_Packages))" );
2527
2628 QDirIterator it (dir.path (), QDir::Files);
2729 while (it.hasNext ()) {
2830 const QString fileName = it.next ();
29- if ((includeRegex.match (fileName).hasMatch () || secondaryRegex.match (fileName).hasMatch ())
31+ if ((allBinaryArchRegex.match (fileName).hasMatch () ||
32+ (!allBinaryAnyRegex.match (fileName).hasMatch () && allRegex.match (fileName).hasMatch ()))
3033 && !excludeRegex.match (fileName).hasMatch ()) {
3134 if (!readFile (fileName)) {
3235 qWarning () << " Error reading cache file:" << fileName;
Original file line number Diff line number Diff line change 1+ mx-packageinstaller (24.12.04) mx; urgency=medium
2+
3+ * Adjust regex to read binary-packages for current arch only and
4+ add all flat-repo Packages without binary-arch in filename
5+
6+ -- fehlix <fehlix@mxlinux.org> Tue, 31 Dec 2024 11:12:36 -0500
7+
18mx-packageinstaller (24.12.03) mx; urgency=medium
29
310 * adjust secondary regex to pick up more package lists
@@ -9,6 +16,7 @@ mx-packageinstaller (24.12.02) mx; urgency=medium
916 * Set the application name to fix the Qt translation domain and
1017 window icon name based on the application name instead of the
1118 executable file or symlink name
19+ * Adjust regex for Packages filenames without binary-arch from flat-repo
1220
1321 -- fehlix <fehlix@mxlinux.org> Tue, 31 Dec 2024 10:19:35 -0500
1422
You can’t perform that action at this time.
0 commit comments