Skip to content

Commit

Permalink
improve docs
Browse files Browse the repository at this point in the history
  • Loading branch information
joamatab committed Jun 8, 2023
1 parent e14b6d2 commit ccc7766
Show file tree
Hide file tree
Showing 4 changed files with 194 additions and 27 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pages.yml
Expand Up @@ -36,7 +36,7 @@ jobs:
SIMCLOUD_APIKEY: ${{ secrets.SIMCLOUD_APIKEY }}
DISPLAY: 1.0
DOCS: True
GDSFACTORY_LAYOUT_PLOTTER: klayout
GDSFACTORY_DISPLAY_TYPE: klayout
KFACTORY_DISPLAY_TYPE: image
AWS_ACCESS_KEY_ID: ${{ secrets.GDSLIB_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.GDSLIB_AWS_SECRET_ACCESS_KEY }}
Expand Down
46 changes: 46 additions & 0 deletions docs/code_of_conduct.md
@@ -0,0 +1,46 @@
# Contributor Code of Conduct

## Our Pledge

In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.

## Our Standards

Examples of behavior that contributes to creating a positive environment include:

* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

* The use of sexualized language or imagery and unwelcome sexual attention or advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a professional setting

## Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.

Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.

## Scope

This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team on [gitter](https://matrix.to/#/#gdsfactory-dev_community:gitter.im). The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.

Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]

[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/
22 changes: 17 additions & 5 deletions docs/contribution.md
@@ -1,10 +1,19 @@
# Contributing

gdsfactory is an open source project that welcomes your contributions. How can you contribute?
We welcome your skills and enthusiasm at the gdsfactory project!. There are numerous opportunities to contribute beyond writing code.
All contributions, including bug reports, bug fixes, documentation improvements, enhancement suggestions, and other ideas are welcome.

If you have any questions on the process or how to fix something feel free to ask us!
The recommended place to ask a question is on [GitHub Discussions](https://github.com/gdsfactory/xarray/discussions), but we also have a [gitter matrix channel](https://matrix.to/#/#gdsfactory-dev_community:gitter.im) that you can use with any matrix client (such as [element](https://element.io/download)) and a [mailing list](https://groups.google.com/g/gdsfactory)

## Where to start?

You can fork the repo, work on a feature, and then create a Pull Request to merge your feature into the `main` branch.
This will benefit other project community members and make you famous :).

How can you help? Take a look at the [open issues](https://github.com/gdsfactory/gdsfactory/issues) or add something you need to gdsfactory:
Take a look at the [open issues](https://github.com/gdsfactory/gdsfactory/issues) to find issues that interest you. Some issues are particularly suited for new contributors by the [good first issue label](https://github.com/gdsfactory/gdsfactory/labels/good first issue) where you could start out. These are well documented issues, that do not require a deep understanding of the internals of gdsfactory.

Here are some other ideas for possible contributions:

- Documentation, tutorials or code improvements. Just find a typo and submit a PR!
- Design/verification/validation improvements.
Expand All @@ -22,15 +31,15 @@ The workflow is:

- Follow [Google Python Style Guide](https://google.github.io/styleguide/pyguide.html) and take a look at existing gdsfactory code.
- Make sure tests pass on GitHub.
- Install pre-commit to get the pre-commit checks passing (autoformat the code, run linter ...). You can also install pre-commit:
- Install pre-commit to get the pre-commit checks passing (autoformat the code, run linter ...).

```
cd gdsfactory
pip install -e . pre-commit
pre-commit install
```

Pre-commit makes sure the code is formatted correctly, runs linter (syntax check), checks docstrings ...
Pre-commit makes sure your code is formatted following black and checks syntax.
If you forgot to `pre-commit install` you can fix pre-commit issues by running

```
Expand All @@ -54,9 +63,12 @@ You can run tests with `pytest`. This will run 3 types of tests:
- when running the test it will do a boolean of the `run_layout` and the `ref_layout` and raise an error for any significant differences.
- you can check out any changes in your library with `gf gds diff ref_layouts/bbox.gds run_layouts/bbox.gds`


If test failed because you modified the geometry you can regenerate the regression tests with:

```
pytest --force-regen -s
```

## Code of Conduct

This project is a community effort, and everyone is welcome to contribute. Everyone within the community is expected to abide by our [code of conduct](https://github.com/gdsfactory/gdsfactory/blob/main/docs/code_of_conduct.md)

0 comments on commit ccc7766

Please sign in to comment.