Skip to content

[webkitscmpy] Generalize pull-request title generation.#28

Closed
JonWBedard wants to merge 1 commit into
WebKit:mainfrom
JonWBedard:eng/title-generation
Closed

[webkitscmpy] Generalize pull-request title generation.#28
JonWBedard wants to merge 1 commit into
WebKit:mainfrom
JonWBedard:eng/title-generation

Conversation

@JonWBedard

@JonWBedard JonWBedard commented Oct 28, 2021

Copy link
Copy Markdown
Member

5473ad2

[webkitscmpy] Generalize pull-request title generation.
https://bugs.webkit.org/show_bug.cgi?id=232463
<rdar://problem/84784354 >

Reviewed by Dewei Zhu.

* Scripts/libraries/webkitscmpy/setup.py: Bump version.
* Scripts/libraries/webkitscmpy/webkitscmpy/__init__.py: Ditto.
* Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/pull_request.py:
(PullRequest.title_for): Compute pull-request title for a set of commits.
(PullRequest.main): Generalize pull-request title generation.

@JonWBedard JonWBedard self-assigned this Oct 28, 2021

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is O(n^2) way to calculate common-prefix [note str.startswith is O(n)], where can we directly implement it with O(n).

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turns out, os implements this anyways, so we can just use that.

@JonWBedard
JonWBedard force-pushed the eng/title-generation branch 2 times, most recently from 8c77ddd to 12bb007 Compare October 29, 2021 17:15
https://bugs.webkit.org/show_bug.cgi?id=232463
<rdar://problem/84784354>

Reviewed by Dewei Zhu.

* Scripts/libraries/webkitscmpy/setup.py: Bump version.
* Scripts/libraries/webkitscmpy/webkitscmpy/__init__.py: Ditto.
* Tools/Scripts/libraries/webkitscmpy/webkitscmpy/program/pull_request.py:
(PullRequest.title_for): Compute pull-request title for a set of commits.
(PullRequest.main): Generalize pull-request title generation.
@JonWBedard
JonWBedard force-pushed the eng/title-generation branch from 12bb007 to 5473ad2 Compare November 2, 2021 14:41
@JonWBedard

Copy link
Copy Markdown
Member Author

@JonWBedard JonWBedard closed this Nov 2, 2021
@JonWBedard
JonWBedard deleted the eng/title-generation branch November 2, 2021 17:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants