Skip to content

Commit d468a3e

Browse files
authored
chore(ci): add org-wide GitHub Actions CLA workflow (#2150)
## PR Checklist - [x] The PR title follows our guidelines: https://github.com/NativeScript/NativeScript/blob/main/tools/notes/CONTRIBUTING.md#commit-messages. - [x] You have read and signed the [CLA](https://github.com/NativeScript/.github/blob/master/CLA.md). - [x] All existing tests are passing. ## Summary - Adds `.github/workflows/cla.yml` calling the centralized `NativeScript/.github` `✍️ CLA` workflow (NativeScript/.github#5) for instant in-PR comment signing (`I have read the CLA and I hereby sign the CLA`) and shared org-wide signer records. - Updates CLA links/instructions in `CONTRIBUTING.md`. > **Merge order:** Merge NativeScript/.github#5 first before merging this PR. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> <!-- coderabbit-ai-generated:v1 --> ## Summary by CodeRabbit * **Contributor Guidance** * Updated contribution instructions with the NativeScript Contributor License Agreement and steps for first-time contributors to sign it on their pull request. * Pull requests without a signed agreement cannot be accepted. * **Workflow** * Added automated checks for contributor agreement status on pull requests, including when contributors sign by commenting. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
1 parent 56c7b0b commit d468a3e

2 files changed

Lines changed: 43 additions & 1 deletion

File tree

‎.github/workflows/cla.yml‎

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: ✍️ CLA
2+
3+
on:
4+
pull_request_target:
5+
types:
6+
- opened
7+
- reopened
8+
- synchronize
9+
- closed
10+
issue_comment:
11+
types:
12+
- created
13+
- edited
14+
- deleted
15+
workflow_dispatch:
16+
17+
permissions:
18+
contents: read
19+
20+
jobs:
21+
cla:
22+
name: CLA
23+
if: >-
24+
github.event_name == 'pull_request_target' ||
25+
github.event_name == 'workflow_dispatch' ||
26+
(
27+
github.event_name == 'issue_comment' &&
28+
github.event.issue.pull_request != null &&
29+
github.event.comment.user.type == 'User' &&
30+
(
31+
contains(github.event.comment.body, 'I hereby sign the CLA') ||
32+
(
33+
github.event.action == 'edited' &&
34+
contains(github.event.changes.body.from, 'I hereby sign the CLA')
35+
)
36+
)
37+
)
38+
uses: NativeScript/.github/.github/workflows/cla.yml@master
39+
permissions:
40+
contents: write
41+
pull-requests: write
42+
actions: write

‎CONTRIBUTING.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
## Before You Start
44

5-
Anyone wishing to contribute to the NativeScript project MUST read & sign the [NativeScript Contribution License Agreement](http://www.nativescript.org/cla). The NativeScript team cannot accept pull requests from users who have not signed the CLA first.
5+
Anyone wishing to contribute to the NativeScript project MUST read & sign the [NativeScript Contributor License Agreement (CLA)](https://github.com/NativeScript/.github/blob/master/CLA.md) (first-time contributors can sign directly on their pull request by commenting `I have read the CLA and I hereby sign the CLA`). The NativeScript team cannot accept pull requests without a signed CLA.
66

77
## Introduction
88

0 commit comments

Comments
 (0)