Skip to content
This repository has been archived by the owner on Jun 5, 2024. It is now read-only.

ci: Updated prepare-release to use conventional commit based releases. #232

Merged
merged 2 commits into from
Dec 21, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 15 additions & 7 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,22 @@ This code is leveraged to monitor critical services. Please consider the followi
* Performance matters.
* Features that are specific to just your app are unlikely to make it in.

Please fill out the relevant sections as follows:
* Proposed Release Notes: Bulleted list of recommended release notes for the change(s).
* Links: Any relevant links for the change.
* Details: In-depth description of changes, other technical notes, etc.
Ensure that your Pull Request title adheres to our Conventional Commit standards
as described in CONTRIBUTING.md
jsumners-nr marked this conversation as resolved.
Show resolved Hide resolved

Please update the Pull Request description to add relevant context or documentation about
the submitted change.
-->
## Description

Please provide a brief description of the changes introduced in this pull request.
What problem does it solve? What is the context of this change?

## How to Test

## Proposed Release Notes
Please describe how you have tested these changes. Have you run the code against an example application?
What steps did you take to ensure that the changes are working correctly?

## Links
## Related Issues

## Details
Please include any related issues or pull requests in this section, using the format `Closes #<issue number>` or `Fixes #<issue number>` if applicable.
13 changes: 13 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: 2
updates:
- package-ecosystem: "npm"
# Disable version updates for npm dependencies, security updates don't use this configuration
# See: https://docs.github.com/en/code-security/dependabot/dependabot-security-updates/configuring-dependabot-security-updates
open-pull-requests-limit: 0
directory: "/"
schedule:
interval: "daily"
commit-message:
prefix: "security"
prefix-development: "chore"
include: "scope"
6 changes: 6 additions & 0 deletions .github/workflows/prepare-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,17 @@ on:
release_type:
description: Type of release. patch or minor (major if breaking)
required: true
type: choice
default: patch
options:
- patch
- minor
- major

jobs:
release-notes:
uses: newrelic/node-newrelic/.github/workflows/prep-release.yml@main
with:
release_type: ${{ github.event.inputs.release_type }}
use_new_relase: ${{ vars.USE_NEW_RELEASE }}
Copy link
Member Author

Choose a reason for hiding this comment

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

i set this in the actions variables to true

changelog_file: CHANGELOG.md
53 changes: 53 additions & 0 deletions .github/workflows/validate-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Validate Pull Request

permissions:
pull-requests: write

on:
pull_request:
types:
- opened
- edited
- synchronize

jobs:
validate-pr:
runs-on: ubuntu-latest
steps:
- name: Pull Request Title is Conventional
id: lint_pr_title
uses: amannn/action-semantic-pull-request@v5
with:
# Recommended Prefixes from https://github.com/conventional-changelog/commitlint/blob/master/%40commitlint/config-conventional/README.md#type-enum
types: |
build
chore
ci
docs
feat
fix
perf
refactor
revert
security
style
test
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- if: failure()
name: Add PR comment if failed
uses: marocchino/sticky-pull-request-comment@v2
with:
header: pr-title-lint-error
message: |
Thank you for your contribution! We require all PR titles to follow the [Conventional Commits specification](https://www.conventionalcommits.org/en/v1.0.0/).
Please update your PR title with the appropriate type and we'll try again!
```
${{ steps.lint_pr_title.outputs.error_message}}
```
- if: success()
name: Remove PR comment if valid
uses: marocchino/sticky-pull-request-comment@v2
with:
header: pr-title-lint-error
delete: true
5 changes: 5 additions & 0 deletions changelog.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"repository": "newrelic/node-newrelic-aws-sdk",
"entries": []
}