Skip to content

Commit

Permalink
fix: fix description parser
Browse files Browse the repository at this point in the history
  • Loading branch information
ABGEO committed Jun 12, 2022
1 parent 4c3a6bd commit 00aebc1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion httpinfo.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ function print_status_code_description() {

ARTICLE_CONTENT=$(echo "$TRIMMED_HTML" | grep -o -P '<article class="main-page-content" lang="en-US">(.*?)<\/article>')
TITLE=$(echo "$ARTICLE_CONTENT" | grep -o -P '(?<=<h1>).*(?=</h1>)')
DESCRIPTION=$(echo "$ARTICLE_CONTENT" | grep -o -P '(?<=<div>).*(?=</div><section aria-labelledby="status">)')
DESCRIPTION=$(echo "$ARTICLE_CONTENT" | grep -o -P '(?<=<div class="section-content">).*(?=</div><section aria-labelledby="status">)')

echo "$TITLE"
repeat_text ${#TITLE} "="
Expand Down

0 comments on commit 00aebc1

Please sign in to comment.