cockpit-project / cockpit

Cockpit is a web-based graphical interface for servers.
http://www.cockpit-project.org/
GNU Lesser General Public License v2.1
11.19k stars 1.11k forks source link

Clickable BZ links in update changelog #17748

Open supakeen opened 2 years ago

supakeen commented 2 years ago

On the updates page the last item from the changelog is shown, this is super nice. Often times RHBZ tickets are listed in these changelogs or other metadata. It'd be super nice if #\d+ could be replaced with a link to the relevant issue.

supakeen commented 2 years ago

I'd be happy to provide a PR if someone could point me in the right direction, I'm not that knowledgeable on the entire ecosystem surrounding cockpit :)

garrett commented 2 years ago

Good idea!

It would need to be limited to distributions using the RH bugzilla (RHEL, Fedora, CentOS, etc.). That is, it probably shouldn't link to redhat.bugzilla.com in Debian, Ubuntu, SUSE, Arch, etc. distros.

marusak commented 2 years ago

It might be around here: https://github.com/cockpit-project/cockpit/blob/main/pkg/packagekit/updates.jsx#L320

If you need help how to run and test cockpit please feel free to reach out!

supakeen commented 2 years ago

Thank you @marusak I'll take a look, @garrett is also absolutely right on the distro-conditional.

ayeankit commented 1 year ago

Is this still open? I would like to work on this issue.

supakeen commented 1 year ago

Since I don't have any spare time at the moment feel free @ayeankit.

Deeppjp116 commented 1 year ago

Hello,

I'm Deep. I'm interested in working on this issue. Could you please explain the problem and guide me on setting up the repository on my computer? I'm eager to contribute and give my best effort to resolve this. This will be my first valuable contribution. Thank you for giving me this opportunity.

garrett commented 1 year ago

As explained above: Links in changelogs that go to bugzilla numbers should be linked to the distribution's bugzilla. This is different for each distribution... and not all use Bugzilla.

Setting up Cockpit for development is detailed on our website:

ashutosh7i commented 10 months ago

Can i work on this issue?

martinpitt commented 10 months ago

@ashutosh7i sure, please do, thanks! This should be relatively easy to do. Note that these days, RHEL actually primarily uses https://issues.redhat.com , but changelogs could still refer to bugzilla. It usually looks like "rhbz#12345" or "jira#12345".

ashutosh7i commented 10 months ago

ok so i was wondering how to reproduce the changelogs?

as the modification has to be done with changelogs or other metadata. in my cockpit dashboard i am not having any, is there any way to reproduce these or anything else i am missing?

output2

martinpitt commented 10 months ago

Our tests mock the metadata, e.g. here: https://github.com/cockpit-project/cockpit/blob/main/test/verify/check-packagekit#L740 I suggest to add a testlib.sit() at the relevant point, and run the test with TEST_SHOW_BROWSER=1 TEST_BROWSER=firefox, then you can interactively work with that (including ./build.js -w -r c)

kh-ac commented 10 months ago

@martinpitt Hello, Can i work on this issue ?

martinpitt commented 10 months ago

@kh-ac sure, please do!

chiteshbansal commented 9 months ago

@supakeen I am new to this project , can you explain little bit more about the issue,I would love to work on it.

supakeen commented 9 months ago

@chiteshbansal In the packages listing in Cockpit (forgive me if I get terminology wrong) you often see references to Bugzilla tickets by their number usually in the format of BZ#1234 or RHBZ#1234, JIRA#1234 or such. I'd like those to be clickable so I can go directly to the issue.

Note that RHBZ links to the RedHat Bugzilla and JIRA links to the RedHat JIRA.

mega-bots commented 9 months ago

@martinpitt

Our tests mock the metadata, e.g. here: https://github.com/cockpit-project/cockpit/blob/main/test/verify/check-packagekit#L740 I suggest to add a testlib.sit() at the relevant point, and run the test with TEST_SHOW_BROWSER=1 TEST_BROWSER=firefox, then you can interactively work with that (including ./build.js -w -r c)

I am a beginner, so this question might be dumb . Can you give some more details about this,on how to generate those changelogs?