Skip to content

Commit

Permalink
Merge pull request #10 from jpopelka/rc3
Browse files Browse the repository at this point in the history
2.0rc3
  • Loading branch information
jpopelka authored Sep 29, 2023
2 parents 32589fa + 0566086 commit 12b7dcf
Show file tree
Hide file tree
Showing 27 changed files with 1,067 additions and 1,030 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ repos:
hooks:
- id: prettier
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.0.289
rev: v0.0.291
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,7 @@ For development and tests:
## Documentation

- https://fedora-ci.github.io/rpmdeplint

## RPM builds

- https://copr.fedorainfracloud.org/coprs/g/osci/rpmdeplint
15 changes: 15 additions & 0 deletions docs/CHANGES.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,21 @@
Changelog
---------

2.0rc3
~~~~~~

* Repodata cache now works with metalink/mirrorlist
(`RHBZ#1343247 <https://bugzilla.redhat.com/show_bug.cgi?id=1343247#c18>`__).
* Don't leak directories in :file:`/var/tmp/rpmdeplint-*`
(`RHBZ#1343247 <https://bugzilla.redhat.com/show_bug.cgi?id=1343247#c17>`__).
* Allow passing a metalink for --repo instead of baseurl
(`RHBZ#1454525 <https://bugzilla.redhat.com/show_bug.cgi?id=1454525>`__).
* Allow passing only a configured repo name for ``--repo``.
* Modernize deprecated stuff.
* Refactoring.
* Unit and acceptance tests moved to :file:`tests/`.
* Code from :file:`__init__.py` moved to :file:`analyzer.py`.

2.0rc2
~~~~~~

Expand Down
43 changes: 33 additions & 10 deletions docs/rpmdeplint.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,24 +17,35 @@ RPM packages against given repositories.
Options
~~~~~~~

.. option:: --repo NAME,URL, -r NAME,URL
.. option:: --repo NAME[,URL_OR_PATH], -r NAME[,URL_OR_PATH]

Load yum repo from the given URL. You can also specify a local filesystem
path instead of a URL.
Load yum repository specified by name or by URL/path.

The NAME is for descriptive purposes only. It has no impact on dependency
resolution. If rpmdeplint finds a dependency problem relating to a package
in this repo, the NAME will appear in the error message.
If the repo is already configured in :file:`/etc/yum.repos.d/{*}.repo`
you can just specify its name, like::

--repo=fedora

Note that the URL should point at a directory containing
``repodata/repomd.xml``. For example::
Otherwise, specify a name and the baseurl or metalink. The NAME is for
descriptive purposes only in this case. It has no impact on dependency
resolution. If rpmdeplint finds a dependency problem relating to a package
in this repo, the NAME will appear in the error message. Examples::

--repo=fedora,https://download.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/

--repo=fedora,https://mirrors.fedoraproject.org/metalink?repo=rawhide&arch=x86_64

You can also specify a local filesystem path instead of a URL, like::

--repo=myrepo,/home/me/my_repo

Note that the URL/path should point at a directory containing
``repodata/repomd.xml``. Examples::

.. option:: --repos-from-system, -R

Use yum repos from the system-wide configuration in :file:`/etc/yum.conf`
and :file:`/etc/yum.repos.d/{*}.repo`. Repos which are disabled in the
Use yum repos from the system-wide configuration in
:file:`/etc/yum.repos.d/{*}.repo`. Repos which are disabled in the
configuration (``enabled=0``) are ignored.

This option can be combined with one or more :option:`--repo` options.
Expand Down Expand Up @@ -137,6 +148,18 @@ to check if it will cause dependency errors in Fedora::
--repo=fedora,https://download.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/ \
greenwave-0.6.1-0.git.2.2529bfb.fc29.noarch.rpm

You don't have to specify the URLs of the repos if they are already configured in `/etc/yum.repos.d/`::

rpmdeplint check \
--repo=fedora --repo=updates \
greenwave-0.6.1-0.git.2.2529bfb.fc29.noarch.rpm

or use all configured repos::

rpmdeplint check \
--repos-from-system \
greenwave-0.6.1-0.git.2.2529bfb.fc29.noarch.rpm

You can also use a local filesystem path instead of an absolute URL for the
repos to test against. For example, if you are offline you could re-use your
local dnf cache. (Note that rpmdeplint may need to fetch packages for file
Expand Down
2 changes: 1 addition & 1 deletion plans/acceptance.fmf
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ prepare:
- 'glibc-devel*i686'
execute:
script:
- pytest --verbose --showlocals acceptance_tests/
- pytest --verbose --showlocals tests/acceptance/
2 changes: 1 addition & 1 deletion plans/unit.fmf
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ prepare:
- python3-rpmfluff
execute:
script:
- pytest --verbose --showlocals rpmdeplint/
- pytest --verbose --showlocals tests/unit/
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ rpmdeplint = "rpmdeplint.cli:main"

[tool.hatch.version]
source = "vcs"
raw-options.version_scheme = "post-release"
raw-options.version_scheme = "no-guess-dev"

[tool.ruff]
select = [
Expand Down
4 changes: 2 additions & 2 deletions rpmdeplint.spec
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Name: rpmdeplint
Version: 2.0
Version: 2.0rc3
Release: %autorelease
Summary: Tool to find errors in RPM packages in the context of their dependency graph
License: GPL-2.0-or-later
Expand Down Expand Up @@ -54,7 +54,7 @@ mv docs/_build/man/rpmdeplint.1 %{buildroot}%{_mandir}/man1/
%pyproject_save_files rpmdeplint

%check
py.test-3 rpmdeplint -k "not TestDependencyAnalyzer"
%pytest tests/unit/ -k "not TestDependencyAnalyzer"
# Acceptance tests do not work in mock because they require .i686 packages.

%files
Expand Down
Loading

0 comments on commit 12b7dcf

Please sign in to comment.