Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 2 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
blank_issues_enabled: false

30 changes: 30 additions & 0 deletions .github/ISSUE_TEMPLATE/report-issue.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Report an Issue
description: Report a broken link, incorrect information, or other issue
labels: ["bug"]
body:
- type: dropdown
id: type
attributes:
label: Issue Type
options:
- Broken link
- Incorrect information
- Missing information
- Other
validations:
required: true

- type: input
id: entry
attributes:
label: Affected Entry
description: Which resource or section is affected?

- type: textarea
id: description
attributes:
label: Description
description: Describe the issue.
validations:
required: true

58 changes: 58 additions & 0 deletions .github/ISSUE_TEMPLATE/suggest-resource.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Suggest a Resource
description: Suggest a resource to add to this awesome list
title: "[Suggestion] "
labels: ["suggestion"]
body:
- type: input
id: name
attributes:
label: Resource Name
validations:
required: true

- type: input
id: url
attributes:
label: URL
description: Primary project, paper, article, or landing-page URL.
validations:
required: true

- type: input
id: github
attributes:
label: GitHub Repository
description: "GitHub `owner/repo` slug if available. Leave blank for non-GitHub resources."
placeholder: owner/repo

- type: input
id: category
attributes:
label: Category
description: Existing section or subsection where this resource belongs.
validations:
required: true

- type: textarea
id: description
attributes:
label: Description
description: Short factual description.
validations:
required: true

- type: textarea
id: why
attributes:
label: Why should it be included?
description: Explain why this is a strong fit for the list.

- type: checkboxes
id: checklist
attributes:
label: Checklist
options:
- label: Publicly accessible
- label: Not a duplicate of an existing entry
- label: Has a meaningful description

18 changes: 18 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<!--
README.md is generated from YAML data.
PRs that only modify README.md will fail CI.

To suggest a new resource, use the issue template instead:
https://github.com/jslee02/awesome-cpp-python-binding-generator/issues/new?template=suggest-resource.yml
-->

## What does this PR do?

## Checklist

- [ ] I edited YAML/source files, not `README.md` directly
- [ ] Entry added in the correct section or subsection
- [ ] `python3 scripts/validate_entries.py` passes
- [ ] `python3 scripts/generate_readme.py` run and `README.md` committed
- [ ] Commits are signed off (`git commit --signoff`)

7 changes: 7 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"

39 changes: 39 additions & 0 deletions .github/workflows/protect-readme.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Protect README

on:
pull_request:
paths:
- "README.md"

jobs:
check-readme:
runs-on: ubuntu-latest
steps:
- name: Block direct README edits
if: github.event.pull_request.user.type != 'Bot'
uses: actions/github-script@v9
with:
script: |
const files = await github.paginate(github.rest.pulls.listFiles, {
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: context.payload.pull_request.number,
per_page: 100,
});

const hasSourceChanges = files.some(f =>
f.filename === 'awesome-list.yaml' ||
f.filename.startsWith('data/') ||
f.filename.startsWith('scripts/') ||
f.filename.startsWith('schema/')
);

if (!hasSourceChanges) {
core.setFailed(
'README.md must not be edited directly.\n\n' +
'This repository uses a data-first workflow and auto-generates README.md from YAML files.\n\n' +
'To suggest a new resource, open an issue instead:\n' +
`https://github.com/${context.repo.owner}/${context.repo.repo}/issues/new/choose`
);
}

15 changes: 15 additions & 0 deletions .github/workflows/validate-and-generate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Validate Data

on:
pull_request:
paths:
- "awesome-list.yaml"
- "data/**"
- "scripts/**"

jobs:
validate:
uses: jslee02/awesome-list-infra/.github/workflows/validate-data.yml@main
with:
dependencies: "pyyaml git+https://github.com/jslee02/awesome-list-infra.git"

35 changes: 35 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Contribution Guidelines

## Suggesting a New Resource

Please use the GitHub issue form for new suggestions:

- Open `Suggest a Resource`
- Fill in the category, description, and repository fields as completely as you can
- Search existing issues and entries first to avoid duplicates

## Fixing an Existing Entry

This repository uses a data-first workflow:

- YAML files are the source of truth
- `README.md` is generated from YAML data

If you are opening a direct PR:

1. Edit the relevant YAML/source file, not `README.md`
2. Keep entries in the correct section and order
3. Run `python3 scripts/validate_entries.py`
4. Run `python3 scripts/generate_readme.py`
5. Commit the regenerated `README.md`
6. Sign off commits with `git commit --signoff`

## General Rules

- Keep descriptions short, factual, and easy to scan
- Use the appropriate category and subsection
- Check spelling and grammar
- Remove trailing whitespace

Thank you for the contribution.

25 changes: 23 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
# Awesome Python Binding Generators for C++

## C/C++ to Python
[![Awesome](https://awesome.re/badge.svg)](https://awesome.re)

A curated list of resources for Python Binding Generators for C++.

## Contents

- [C/C++ to Python](#cc-to-python)
- [Boost.Python](#boostpython)
- [pybind11](#pybind11)
- [ETC](#etc)
- [C/C++ to other languages](#cc-to-other-languages)
- [Crystal](#crystal)

## [C/C++ to Python](#contents)

### Boost.Python

Expand All @@ -19,8 +32,16 @@
* Cpp2Py - Reflection tools based on clang [[github](https://github.com/TRIQS/cpp2py) ![TRIQS/cpp2py](https://img.shields.io/github/stars/TRIQS/cpp2py.svg?style=social&label=Star&maxAge=2592000)]
* [cppyy](https://cppyy.readthedocs.io) - Python-C++ bindings interface based on Cling/LLVM [[bitbucket](https://bitbucket.org/wlav/cppyy)]

## C/C++ to other languages
## [C/C++ to other languages](#contents)

### Crystal

* Bindgen - Binding and wrapper generator for C/C++ libraries [[github](https://github.com/Papierkorb/bindgen) ![Papierkorb/bindgen](https://img.shields.io/github/stars/Papierkorb/bindgen.svg?style=social&label=Star&maxAge=2592000)]

## [Contributing](#contents)

Contributions are very welcome. Please read the [contribution guidelines](CONTRIBUTING.md) first. Also, please feel free to report any error.

## [License](#contents)

[![CC0](https://licensebuttons.net/p/zero/1.0/88x31.png)](http://creativecommons.org/publicdomain/zero/1.0/)
3 changes: 3 additions & 0 deletions awesome-list.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
title: Awesome Python Binding Generators for C++
description: A curated list of resources for Python Binding Generators for C++.
repository: jslee02/awesome-cpp-python-binding-generator
47 changes: 47 additions & 0 deletions data/readme.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
sections:
- title: C/C++ to Python
content:
- ''
sections:
- title: Boost.Python
content:
- ''
- '* [AutoWIG](https://autowig.readthedocs.io) - Automatic wrapper and interface
generator [[github](https://github.com/StatisKit/AutoWIG) ![StatisKit/AutoWIG](https://img.shields.io/github/stars/StatisKit/AutoWIG.svg?style=social&label=Star&maxAge=2592000)]'
- '* chimera - Utility for generating Boost.Python and pybind11 bindings from
C/C++ code [[github](https://github.com/personalrobotics/chimera) ![personalrobotics/chimera](https://img.shields.io/github/stars/personalrobotics/chimera.svg?style=social&label=Star&maxAge=2592000)]'
- ''
sections: []
- title: pybind11
content:
- ''
- '* [Binder](http://cppbinder.readthedocs.io/en/latest/) - Binder, tool for automatic
generation of Python bindings [[github](https://github.com/RosettaCommons/binder)
![RosettaCommons/binder](https://img.shields.io/github/stars/RosettaCommons/binder.svg?style=social&label=Star&maxAge=2592000)]'
- '* cppwg - An automatic wrapper generator for C++ [[github](https://github.com/jmsgrogan/cppwg)
![jmsgrogan/cppwg](https://img.shields.io/github/stars/jmsgrogan/cppwg.svg?style=social&label=Star&maxAge=2592000)]'
- '* [Py++](http://pypp11.readthedocs.io/en/latest/) (deprecated) - Py++ for generating
pybind11 code [[github](https://github.com/ISoirar/pypp11) ![ISoirar/pypp11](https://img.shields.io/github/stars/ISoirar/pypp11.svg?style=social&label=Star&maxAge=2592000)]'
- ''
sections: []
- title: ETC
content:
- ''
- '* clif - Wrapper generator foundation to wrap C++ for Python and other languages
using LLVM [[github](https://github.com/google/clif) ![google/clif](https://img.shields.io/github/stars/google/clif.svg?style=social&label=Star&maxAge=2592000)]'
- '* Cpp2Py - Reflection tools based on clang [[github](https://github.com/TRIQS/cpp2py)
![TRIQS/cpp2py](https://img.shields.io/github/stars/TRIQS/cpp2py.svg?style=social&label=Star&maxAge=2592000)]'
- '* [cppyy](https://cppyy.readthedocs.io) - Python-C++ bindings interface based
on Cling/LLVM [[bitbucket](https://bitbucket.org/wlav/cppyy)]'
- ''
sections: []
- title: C/C++ to other languages
content:
- ''
sections:
- title: Crystal
content:
- ''
- '* Bindgen - Binding and wrapper generator for C/C++ libraries [[github](https://github.com/Papierkorb/bindgen)
![Papierkorb/bindgen](https://img.shields.io/github/stars/Papierkorb/bindgen.svg?style=social&label=Star&maxAge=2592000)]'
sections: []
5 changes: 5 additions & 0 deletions scripts/generate_readme.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/env python3
from awesome_list_infra.readme import generate_main

raise SystemExit(generate_main())

5 changes: 5 additions & 0 deletions scripts/validate_entries.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/env python3
from awesome_list_infra.readme import validate_main

raise SystemExit(validate_main())

Loading