Compare commits

...

2 Commits

5 changed files with 18 additions and 4 deletions

View File

@ -1,14 +1,14 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<!-- Generated by graphviz version 5.0.0 (0)
<!-- Generated by graphviz version 5.0.1 (0)
-->
<!-- Title: G Pages: 1 -->
<svg width="13233pt" height="4186pt"
viewBox="0.00 0.00 13232.57 4185.79" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(4 4181.79)">
<title>G</title><style>.edge>path:hover{stroke-width:8}</style>
<polygon fill="white" stroke="transparent" points="-4,4 -4,-4181.79 13228.57,-4181.79 13228.57,4 -4,4"/>
<polygon fill="white" stroke="none" points="-4,4 -4,-4181.79 13228.57,-4181.79 13228.57,4 -4,4"/>
<!-- ahriman_application_ahriman -->
<g id="node1" class="node">
<title>ahriman_application_ahriman</title><style>.edge>path:hover{stroke-width:8}</style>

Before

Width:  |  Height:  |  Size: 537 KiB

After

Width:  |  Height:  |  Size: 537 KiB

View File

@ -1,7 +1,7 @@
# Maintainer: Evgeniy Alekseev
pkgname='ahriman'
pkgver=2.2.1
pkgver=2.2.2
pkgrel=1
pkgdesc="ArcH linux ReposItory MANager"
arch=('any')

View File

@ -57,6 +57,8 @@ class Sources(LazyLogging):
return
architectures = Package.supported_architectures(sources_dir)
if "any" in architectures: # makepkg does not like when there is any other arch except for any
return
architectures.add(architecture)
patch = PkgbuildPatch("arch", list(architectures))
patch.write(pkgbuild_path)

View File

@ -17,4 +17,4 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
__version__ = "2.2.1"
__version__ = "2.2.2"

View File

@ -23,6 +23,18 @@ def test_extend_architectures(mocker: MockerFixture) -> None:
write_mock.assert_called_once_with(Path("local") / "PKGBUILD")
def test_extend_architectures_any(mocker: MockerFixture) -> None:
"""
must skip architecture patching in case if there is any architecture
"""
mocker.patch("pathlib.Path.is_file", return_value=True)
mocker.patch("ahriman.models.package.Package.supported_architectures", return_value={"any"})
write_mock = mocker.patch("ahriman.models.pkgbuild_patch.PkgbuildPatch.write")
Sources.extend_architectures(Path("local"), "i686")
write_mock.assert_not_called()
def test_extend_architectures_skip(mocker: MockerFixture) -> None:
"""
must skip extending list of the architectures in case if no PKGBUILD file found