Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Incorrect DeprecatedInsinto for non-menu items in /usr/share/applications #726

Open
1 task done
thesamesam opened this issue Jan 25, 2025 · 2 comments
Open
1 task done
Labels

Comments

@thesamesam
Copy link
Member

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

See ef042cf60b50500d364675af5961808eb8941298 for an example.

pkgcheck emits DeprecatedInsinto for non-menu items installed into /usr/share/applications with this snippet:

	insinto /usr/share/applications/
	newins "${FILESDIR}"/mimeapps.list kde-mimeapps.list
 kde-plasma/plasma-mimeapps-list
  DeprecatedInsinto: version 3: deprecated insinto usage (use domenu or newmenu from desktop.eclass instead), line 26: insinto /usr/share/applications/

Expected Behavior

No bogus warning.

pkgcheck version

pkgcheck 0.10.3

pkgcore version

pkgcore 0.12.29

@arthurzam
Copy link
Member

Hmm, changing the code of DeprecatedInsinto is non trivial, since it uses regex to detect just calls to insint ${DIR}. It means I would detect next lines if they attempt to install "*.desktop".

On the other hand, while somewhat ugly, would using newmenu "${FILESDIR}"/mimeapps.list kde-mimeapps.list work "by mistake"?

@thesamesam
Copy link
Member Author

I think that would work by mistake, yeah. @parona-source points out maybe this is a good case for a suppression instead and to keep the check as-is?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants