Bug 233951 - Tools/scripts/bump-revision.sh fails to handle PORTREVISIONs with a comment
Summary: Tools/scripts/bump-revision.sh fails to handle PORTREVISIONs with a comment
Status: Open
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Ports Framework (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Bartek Rutkowski
URL:
Keywords: needs-patch
Depends on:
Blocks:
 
Reported: 2018-12-12 03:44 UTC by Gerald Pfeifer
Modified: 2018-12-14 05:26 UTC (History)
3 users (show)

See Also:
koobs: merge-quarterly?


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gerald Pfeifer freebsd_committer 2018-12-12 03:44:10 UTC
Found the following way:

  # Tools/scripts/bump-revision.sh multimedia/x264
  ERROR: multimedia/x264 PORTREVISION value is not a number, unable to solve!

Looking at multimedia/x264/Makefile
  PORTREVISION?=  5 # 0 in libx264
it appears the problem is that there's "only" a space between the number
and the comment separator ('#'), where if it were a tab it'd just work.

Now we can update the port, and I plan on doing that, but it's probably
just a question of tweaking a regular expression in bump-revision.sh ?
Comment 1 Adam Weinberger freebsd_committer 2018-12-12 14:46:44 UTC
Yeah, I suspect that line 63 of bump-revision.sh
  case `echo "$revision_str" | awk -F "\t+" '{ print $2 }'` in
could just as easily be
  case `echo "$revision_str" | awk '{ print $2 }'` in

I don't suspect there's much value in caring what sort of whitespace it is.
Comment 2 Mathieu Arnold freebsd_committer 2018-12-12 15:42:52 UTC
over to maintainer