Defines functions find_first_xml_opening_tag_line

#' Find the line number of the first section's opening tag
#' @param lines the lines of an XML text
#' @param section the name of the XML section
#' @return the line number's index (which is 1 for the first line) if the
#'   opening tag is found, else NA
#' @author Richèl J.C. Bilderbeek
#' @noRd
find_first_xml_opening_tag_line <- function( # nolint beautier functions may be long
) {
  if (!is.character(section)) {
    stop("'section' must be a word")
  find_first_regex_line(lines, paste0("<", section, ".*>")) # nolint beautier function
ropensci/beautier documentation built on March 12, 2019, 8:27 p.m.