Skip to content

Commit f423022

Browse files
add contributing.md (#559)
* add contributing.md Co-authored-by: Courtney Webster <[email protected]>
1 parent c59bcc4 commit f423022

File tree

1 file changed

+89
-0
lines changed

1 file changed

+89
-0
lines changed

contributing.md

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
## Getting Started
2+
3+
Follow the steps below for setup:
4+
```
5+
git clone https://github.com/microsoft/vscode-python-debugger
6+
cd vscode-python-debugger
7+
npm ci
8+
```
9+
10+
Create virtual environment as appropriate for your shell or use the command `Python: Create Environment` in VS Code. Then activate it appropriate for your shell.
11+
```
12+
python3 -m venv .venv
13+
# Activate the virtual environment
14+
# ".venv/Scripts/activate.bat"
15+
# On bash/zsh it's ...
16+
source .venv/bin/activate
17+
```
18+
19+
Install then setup with nox.
20+
```
21+
python3 -m pip install nox
22+
nox --session setup_repo
23+
```
24+
25+
## Reporting Issues
26+
27+
If you encounter any issues, please report them using the [GitHub Issues](https://github.com/microsoft/vscode-python-debugger/issues) page. Provide as much detail as possible, including steps to reproduce the issue and any relevant logs or screenshots. We also recommend using the Report Issue command in VS Code, selecting Python Debugger as the extension. This helps automatically attach crucial information.
28+
29+
## Submitting Pull Requests
30+
31+
1. Fork the repository and create your branch from `main`.
32+
2. If you've added code that should be tested, add tests.
33+
3. Ensure the test suite passes.
34+
4. Make sure your code passes linting and formatting requirements
35+
5. Submit a pull request.
36+
37+
## Running Tests
38+
39+
To run tests, use the following commands:
40+
41+
```
42+
npm run compile-tests
43+
npm run test
44+
```
45+
46+
Ensure all tests pass before submitting your pull request.
47+
48+
## Coding Standards
49+
50+
This project follows the coding standards and guidelines from the [vscode-python](https://github.com/microsoft/vscode-python/wiki/Coding#guidelines) repository. Please ensure your code adheres to these standards.
51+
52+
## Code Formatting & Linting
53+
54+
To check code formatting, run:
55+
56+
```
57+
npm run format-check
58+
```
59+
60+
To automatically fix formatting issues, run:
61+
62+
```
63+
npm run format-fix
64+
```
65+
66+
To lint your code, run:
67+
68+
```
69+
npm run lint
70+
```
71+
72+
Ensure there are no linting errors before submitting your pull request.
73+
74+
## Python Code Linting and Formatting
75+
76+
For Python code, this project uses `ruff` for linting and formatting. To check your Python code for linting and formatting issues, run:
77+
78+
```
79+
ruff check .
80+
```
81+
82+
To automatically fix formatting issues, run:
83+
84+
```
85+
ruff --fix .
86+
```
87+
88+
Ensure there are no linting or formatting errors before submitting your pull request.
89+

0 commit comments

Comments
 (0)