fix(ci): add merge result pipeline support to glab ci status trace and glab ci trace <job_name>

Summary

This MR unifies the way how we handle merge result pipelines across glab ci commands, namely status, get, and trace

The main fix is that trace command now uses the logic to get merge result pipeline as a fallback, but the MR also unifies the way how get command gets the pipeline (removes custom fallback logic).

Testing this locally

run make install in this project to build the glab and install it

Check out a branch with merge result pipelines

glab ci trace <job name>

before after

before, the command would show latest job on main, after it shows the job from the branch

glab ci status trace

before after

before getting the trace from glab ci status would fail

Edited by Tomas Vik

Merge request reports

Loading