@@ -149,9 +149,11 @@ def __init__(
149149 self ,
150150 attrs_per_system : dict [str , list [Attr ]],
151151 extra_nixpkgs_config : str ,
152+ show_header : bool = True ,
152153 * ,
153154 checkout : Literal ["merge" , "commit" ] = "merge" ,
154155 ) -> None :
156+ self .show_header = show_header
155157 self .attrs = attrs_per_system
156158 self .checkout = checkout
157159
@@ -198,17 +200,19 @@ def json(self, pr: int | None) -> str:
198200 )
199201
200202 def markdown (self , pr : int | None ) -> str :
201- msg = "## `nixpkgs-review` result\n \n "
202- msg += "Generated using [`nixpkgs-review`](https://github.com/Mic92/nixpkgs-review).\n \n "
203-
204- cmd = "nixpkgs-review"
205- if pr is not None :
206- cmd += f" pr { pr } "
207- if self .extra_nixpkgs_config :
208- cmd += f" --extra-nixpkgs-config '{ self .extra_nixpkgs_config } '"
209- if self .checkout != "merge" :
210- cmd += f" --checkout { self .checkout } "
211- msg += f"Command: `{ cmd } `\n "
203+ msg = ""
204+ if self .show_header :
205+ msg += "## `nixpkgs-review` result\n \n "
206+ msg += "Generated using [`nixpkgs-review`](https://github.com/Mic92/nixpkgs-review).\n \n "
207+
208+ cmd = "nixpkgs-review"
209+ if pr is not None :
210+ cmd += f" pr { pr } "
211+ if self .extra_nixpkgs_config :
212+ cmd += f" --extra-nixpkgs-config '{ self .extra_nixpkgs_config } '"
213+ if self .checkout != "merge" :
214+ cmd += f" --checkout { self .checkout } "
215+ msg += f"Command: `{ cmd } `\n "
212216
213217 for system , report in self .system_reports .items ():
214218 msg += "\n ---\n "
0 commit comments