Skip to content

Commit c5e7dce

Browse files
ijemmysaragerion
andauthored
docs(all): add toc to README.md and CONTRIBUTING.md (#623)
* Add table of contents to CONTRIBUTING.md * Add ToC to README.md and update typo in CONTRIBUTING.md * doc: Reorder contribution guide to have Getting started before cretaing PR + Limit toc to 3 levels instead of 6 * Remove table of content link * Update CONTRIBUTING.md Co-authored-by: Sara Gerion <[email protected]> * Update CONTRIBUTING.md Co-authored-by: Sara Gerion <[email protected]> * Update CONTRIBUTING.md Co-authored-by: Sara Gerion <[email protected]> * Update README.md Co-authored-by: Sara Gerion <[email protected]> Co-authored-by: Sara Gerion <[email protected]>
1 parent 800424b commit c5e7dce

File tree

2 files changed

+119
-84
lines changed

2 files changed

+119
-84
lines changed

Diff for: CONTRIBUTING.md

+109-84
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,31 @@ documentation, we greatly value feedback and contributions from our community.
66
Please read through this document before submitting any issues or pull requests to ensure we have all the necessary
77
information to effectively respond to your bug report or contribution.
88

9+
## Table of contents
10+
11+
- [Security issue notifications](#security-issue-notifications)
12+
- [Code of Conduct](#code-of-conduct)
13+
- [Reporting Bugs/Feature Requests](#reporting-bugsfeature-requests)
14+
- [Contributing via Pull Requests](#contributing-via-pull-requests)
15+
- [Summary](#summary)
16+
- [Step 1: Find something to work on](#step-1-find-something-to-work-on)
17+
- [Step 2: Design](#step-2-design)
18+
- [Step 3: Work your Magic](#step-3-work-your-magic)
19+
- [Step 4: Pull Request](#step-4-pull-request)
20+
- [Step 5: Merge](#step-5-merge)
21+
- [Getting Started](#getting-started)
22+
- [Setup](#setup)
23+
- [Repo Layout](#repo-layout)
24+
- [Tests](#tests)
25+
- [Unit tests](#unit-tests)
26+
- [e2e tests](#e2e-tests)
27+
- [Examples](#examples)
28+
- [Local documentation](#local-documentation)
29+
- [API reference](#api-reference)
30+
- [Docs website](#docs-website)
31+
- [Conventions](#conventions)
32+
- [Licensing](#licensing)
33+
934
## Security issue notifications
1035

1136
If you discover a potential security issue in this project, we ask that you notify AWS/Amazon Security via our [vulnerability reporting page](http://aws.amazon.com/security/vulnerability-reporting/). Please do **not** create a public GitHub issue.
@@ -27,90 +52,6 @@ reported the issue. Please try to include as much information as you can. Detail
2752
* Any modifications you've made relevant to the bug
2853
* Anything unusual about your environment or deployment
2954

30-
## Contributing via Pull Requests
31-
32-
Contributions via pull requests are much appreciated.
33-
34-
### Summary
35-
36-
* This project uses `[email protected]` and `[email protected]` for development (see [Setup](#setup)).
37-
* Before opening a Pull Request, please find the existing related issue or open a new one to discuss the proposed changes. A PR without a related issue or discussion has a high risk of being rejected. We are very appreciative and thankful for your time and efforts, and we want to make sure they are not wasted.
38-
* After your proposal has been reviewed and accepted by at least one of the project's maintainers, you can submit a pull request.
39-
* When opening a PR, make sure to follow the checklist inside the pull request template.
40-
41-
### Step 1: Find something to work on
42-
43-
If you want to contribute a specific feature or fix you have in mind, look at active [pull
44-
requests](https://github.com/awslabs/aws-lambda-powertools-typescript/pulls) to see if someone else is already working on it. If not, you can start designing your changes.
45-
46-
On the other hand, if you are here looking for an issue to work on, check out our [backlog of
47-
issues](https://github.com/awslabs/aws-lambda-powertools-typescript/issues) and find something that piques your interest. Our project, by default, uses the default GitHub issue labels (enhancement/bug/help wanted/invalid/question/documentation), looking at any issue labeled as 'help wanted' or 'good-first-issue' is a great place to start.
48-
49-
It's a good idea to keep the priority of issues in mind when deciding what to
50-
work on. If we have labelled an issue as `priority:medium` or `priority:low`, it means it's something we won't
51-
get to soon while `priority:high` issues have a bigger impact, so we are much more likely to give a PR for those issues prompt attention.
52-
53-
### Step 2: Design
54-
55-
You can start by checking the project's tenets [here](https://awslabs.github.io/aws-lambda-powertools-typescript/latest/#tenets).
56-
57-
We ask you to seek feedback and consensus on your proposed change by iterating on a design document. This is especially useful when you plan a big change or feature, or you want advice on what would be the best path forward.
58-
59-
If you're picking up an existing issue, you can simply post your comment and discuss your proposed changes. If instead you're proposing a new feature, you can start by creating a new [RFC issue](https://github.com/awslabs/aws-lambda-powertools-typescript/issues/new?assignees=&labels=RFC%2C+triage&template=rfc.md&title=RFC%3A+) and discuss your proposed change with the maintainers.
60-
61-
This is a great way to get feedback on your proposed change and make sure that it is in line with the project's direction and community needs. You can start working on the change when you've gotten approved by at least one maintainer - we would hate for your time to be wasted.
62-
63-
### Step 3: Work your Magic
64-
65-
Work your magic. Before starting, make sure to check the [Getting Started](#Getting-Started) section to setup your dev environment and familiarize yourself with the project's structure and design. Here are some additional guidelines:
66-
67-
* Working against the latest source on the **main** branch.
68-
* Try to maintain a single feature/bugfix per pull request. It's okay to introduce a little bit of housekeeping
69-
changes along the way, but try to avoid conflating multiple features. Eventually, all these are going to go into a
70-
single commit, so you can use that to frame your scope.
71-
* Try to add [unit tests](#Tests) that test your changes when applicable. This is especially important for new features and bug fixes, as it helps you to make sure that your changes are working as intended.
72-
* Lint and test the code. When you've setup the repository with `npm run init-environment`, pre-commit and push-hooks will automatically lint and test the code. Pull request builds will run the same checks as well.
73-
74-
### Step 4: Pull Request
75-
76-
* Create a commit with your changes and push them to a
77-
[fork](https://docs.github.com/en/get-started/quickstart/fork-a-repo).
78-
> Note: Core members can push directly to a branch on the AWS Lambda Powertools for TypeScript repo (following the same conventions detailed below).
79-
* Create a [pull request on GitHub](https://docs.github.com/en/github/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request-from-a-fork).
80-
81-
* Pull request title and message (and PR title and description) must adhere to
82-
[conventionalcommits](https://www.conventionalcommits.org).
83-
* The title must begin with `feat(module): title`, `fix(module): title`, `refactor(module): title` or
84-
`chore(module): title`, etc.
85-
* Title should be lowercase.
86-
* No period at the end of the title.
87-
88-
* Pull request message should describe _motivation_ and follow the template provided as closely as possible. Think about your code reviewers and what information they need in order to understand what you did. If it's a big commit (hopefully not), try to provide some good entry points so it will be easier to follow.
89-
90-
* Pull request message should indicate which issue or RFC it relates to in the "Related issues, RFCs" section.
91-
92-
* Shout out to collaborators.
93-
94-
* If not obvious (i.e. from unit tests), describe how you verified that your change works.
95-
96-
* If this PR includes breaking changes, they must be listed at the end in the "Breaking change checklist" section.
97-
98-
* Once the pull request is submitted, a reviewer will be assigned by the maintainers.
99-
100-
* Discuss review comments and iterate until you get at least one "Approve". When iterating, push new commits to the
101-
same branch. Usually, all these are going to be squashed when the maintainers merge to `main`. The commit messages should be hints
102-
for you when you finalize your merge commit message.
103-
104-
* Make sure to update the PR title/description if things change. The PR title/description are going to be used as the
105-
commit title/message and will appear in the CHANGELOG and Release Notes, so maintain them all the way throughout the process.
106-
107-
* Do not remove the legal notice at the end of the PR message. This is a requirement for any pull request to be
108-
reviewed & accepted.
109-
110-
### Step 5: Merge
111-
112-
* Once approved and tested, one of the maintainers will squash-merge to `main` and will use your PR title/description will be used as the commit message. Your name will be also added to the Release Notes of the next release.
113-
11455
## Getting Started
11556

11657
The following steps describe how to set up the AWS Lambda Powertools for TypeScript repository on your local machine.
@@ -301,6 +242,90 @@ Category | Convention
301242
**Git commits** | We follow [conventional commits](https://www.conventionalcommits.org/en/v1.0.0/). These are not enforced as we squash and merge PRs, but PR titles are enforced during CI.
302243
**Documentation** | API reference docs are generated from docstrings which should have an Examples section to allow developers to have what they need within their own IDE. Documentation website covers the wider usage, tips, and strives to be concise.
303244
245+
## Contributing via Pull Requests
246+
247+
Contributions via pull requests are much appreciated.
248+
249+
### Summary
250+
251+
* This project uses `[email protected]` and `[email protected]` for development (see [Setup](#setup)).
252+
* Before opening a Pull Request, please find the existing related issue or open a new one to discuss the proposed changes. A PR without a related issue or discussion has a high risk of being rejected. We are very appreciative and thankful for your time and efforts, and we want to make sure they are not wasted.
253+
* After your proposal has been reviewed and accepted by at least one of the project's maintainers, you can submit a pull request.
254+
* When opening a PR, make sure to follow the checklist inside the pull request template.
255+
256+
### Step 1: Find something to work on
257+
258+
If you want to contribute a specific feature or fix you have in mind, look at active [pull
259+
requests](https://github.com/awslabs/aws-lambda-powertools-typescript/pulls) to see if someone else is already working on it. If not, you can start designing your changes.
260+
261+
On the other hand, if you are here looking for an issue to work on, check out our [backlog of
262+
issues](https://github.com/awslabs/aws-lambda-powertools-typescript/issues) and find something that piques your interest. Our project, by default, uses the default GitHub issue labels (enhancement/bug/help wanted/invalid/question/documentation), looking at any issue labeled as 'help wanted' or 'good-first-issue' is a great place to start.
263+
264+
It's a good idea to keep the priority of issues in mind when deciding what to
265+
work on. If we have labelled an issue as `priority:medium` or `priority:low`, it means it's something we won't
266+
get to soon while `priority:high` issues have a bigger impact, so we are much more likely to give a PR for those issues prompt attention.
267+
268+
### Step 2: Design
269+
270+
You can start by checking the project's tenets [here](https://awslabs.github.io/aws-lambda-powertools-typescript/latest/#tenets).
271+
272+
We ask you to seek feedback and consensus on your proposed change by iterating on a design document. This is especially useful when you plan a big change or feature, or you want advice on what would be the best path forward.
273+
274+
If you're picking up an existing issue, you can simply post your comment and discuss your proposed changes. If instead you're proposing a new feature, you can start by creating a new [RFC issue](https://github.com/awslabs/aws-lambda-powertools-typescript/issues/new?assignees=&labels=RFC%2C+triage&template=rfc.md&title=RFC%3A+) and discuss your proposed change with the maintainers.
275+
276+
This is a great way to get feedback on your proposed change and make sure that it is in line with the project's direction and community needs. You can start working on the change when you've gotten approved by at least one maintainer - we would hate for your time to be wasted.
277+
278+
### Step 3: Work your Magic
279+
280+
Work your magic. Before starting, make sure to check the [Getting Started](#Getting-Started) section to setup your dev environment and familiarize yourself with the project's structure and design. Here are some additional guidelines:
281+
282+
* Working against the latest source on the **main** branch.
283+
* Try to maintain a single feature/bugfix per pull request. It's okay to introduce a little bit of housekeeping
284+
changes along the way, but try to avoid conflating multiple features. Eventually, all these are going to go into a
285+
single commit, so you can use that to frame your scope.
286+
* Try to add [unit tests](#Tests) that test your changes when applicable. This is especially important for new features and bug fixes, as it helps you to make sure that your changes are working as intended.
287+
* Lint and test the code. When you've setup the repository with `npm run init-environment`, pre-commit and push-hooks will automatically lint and test the code. Pull request builds will run the same checks as well.
288+
289+
### Step 4: Pull Request
290+
291+
* Create a commit with your changes and push them to a
292+
[fork](https://docs.github.com/en/get-started/quickstart/fork-a-repo).
293+
> Note: Core members can push directly to a branch on the AWS Lambda Powertools (TypeScript) repo (following the same conventions detailed below).
294+
* Create a [pull request on GitHub](https://docs.github.com/en/github/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/creating-a-pull-request-from-a-fork).
295+
296+
* Pull request title and message (and PR title and description) must adhere to
297+
[conventionalcommits](https://www.conventionalcommits.org).
298+
* The title must begin with `feat(module): title`, `fix(module): title`, `refactor(module): title` or
299+
`chore(module): title`, etc.
300+
* Title should be lowercase.
301+
* No period at the end of the title.
302+
303+
* Pull request message should describe _motivation_ and follow the template provided as closely as possible. Think about your code reviewers and what information they need in order to understand what you did. If it's a big commit (hopefully not), try to provide some good entry points so it will be easier to follow.
304+
305+
* Pull request message should indicate which issue or RFC it relates to in the "Related issues, RFCs" section.
306+
307+
* Shout out to collaborators.
308+
309+
* If not obvious (i.e. from unit tests), describe how you verified that your change works.
310+
311+
* If this PR includes breaking changes, they must be listed at the end in the "Breaking change checklist" section.
312+
313+
* Once the pull request is submitted, a reviewer will be assigned by the maintainers.
314+
315+
* Discuss review comments and iterate until you get at least one "Approve". When iterating, push new commits to the
316+
same branch. Usually, all these are going to be squashed when the maintainers merge to `main`. The commit messages should be hints
317+
for you when you finalize your merge commit message.
318+
319+
* Make sure to update the PR title/description if things change. The PR title/description are going to be used as the
320+
commit title/message and will appear in the CHANGELOG and Release Notes, so maintain them all the way throughout the process.
321+
322+
* Do not remove the legal notice at the end of the PR message. This is a requirement for any pull request to be
323+
reviewed & accepted.
324+
325+
### Step 5: Merge
326+
327+
* Once approved and tested, one of the maintainers will squash-merge to `main` and will use your PR title/description will be used as the commit message. Your name will be also added to the Release Notes of the next release.
328+
304329
## Licensing
305330
306331
See the [LICENSE](LICENSE) file for our project's licensing. We will ask you to confirm the licensing of your contribution.

Diff for: README.md

+10
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,16 @@ A suite of TypeScript utilities for AWS Lambda functions to ease adopting best p
1010

1111
> **An AWS Developer Acceleration (DevAx) initiative by Specialist Solution Architects | [email protected]**
1212
13+
## Table of contents
14+
15+
- [Features](#features)
16+
- [Getting started](#getting-started)
17+
- [Installation](#installation)
18+
- [Examples](#examples)
19+
- [Credits](#credits)
20+
- [Connect](#connect)
21+
- [License](#license)
22+
1323
## Features
1424

1525
* **[Tracer](https://awslabs.github.io/aws-lambda-powertools-typescript/latest/core/tracer/)** - Utilities to trace Lambda function handlers, and both synchronous and asynchronous functions

0 commit comments

Comments
 (0)