Internal helper function, based on `unheadr::regex_valign``

align_annotations(
  annot_string,
 
    regex_ai = "(?!\\))(?!\\s)(?=\\#\\sCR|\\#\\sBio|\\#\\snot i|\\#\\s\\[)",
  sep_str = ""
)

Arguments

annot_string

Character vector with annotated package calls.

regex_ai

Custom regular expression to match lines with package annotations.

sep_str

Whitespace separator.

Value

A character vector with vertically aligned package calls.