Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update logging in build-tools and add commit date support in GitRepo #11692

Merged
merged 3 commits into from Aug 29, 2022

Conversation

tylerbutler
Copy link
Member

@tylerbutler tylerbutler commented Aug 25, 2022

This change primarily updates the legacy build-tools to better use a unified logging infrastructure that was added in an earlier PR. It also adds the ability to get a commit date from a git ref, which will be used in an upcoming PR to build release reports.

@github-actions github-actions bot added public api change Changes to a public API base: main PRs targeted against main branch labels Aug 25, 2022
* @returns The commit date of the ref.
*/
public async getCommitDate(gitRef: string) {
const result = (await this.exec(`show -s --format=%cI "${gitRef}"`, `get commit date ${gitRef}`)).trim();

Check warning

Code scanning / CodeQL

Unsafe shell command constructed from library input

[String concatenation](1) based on [library input](2) is later used in [shell command](3).
Copy link
Contributor

Choose a reason for hiding this comment

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

This is pretty cool of Github 😄

@tylerbutler
Copy link
Member Author

Thanks for the review, @alexvy86 !

@tylerbutler tylerbutler merged commit 0c09a21 into microsoft:main Aug 29, 2022
@tylerbutler tylerbutler deleted the cli/part-2 branch August 29, 2022 17:32
@github-actions
Copy link
Contributor

This commit is queued for merging with the next branch! Please ignore this PR for now. Contact @microsoft/fluid-cr-infra for help.

WayneFerrao pushed a commit to WayneFerrao/FluidFramework that referenced this pull request Aug 31, 2022
…icrosoft#11692)

This change primarily updates the legacy build-tools to better use a unified logging infrastructure that was added in an earlier PR. It also adds the ability to get a commit date from a git ref, which will be used in an upcoming PR to build release reports.
tylerbutler added a commit that referenced this pull request Aug 31, 2022
Follow up to #11692.

Adds APIs for:

- Generating branch names.
- Creating release and dep bump branches.
- Checking npm for package updates.
- Checking if a particular version has been released.
- Getting all versions and their dates based on the git tag.
- Sorting versions based on date and semver version.

These APIs will be used heavily in the `release` and `release report` commands (future changes).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
base: main PRs targeted against main branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants