setuptools-generate
Generate shell completions and man page when building a python package.
Science Score: 54.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
○Academic publication links
-
✓Committers with academic emails
1 of 1 committers (100.0%) from academic institutions -
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (6.1%) to scientific vocabulary
Keywords
Repository
Generate shell completions and man page when building a python package.
Basic Info
- Host: GitHub
- Owner: Freed-Wu
- License: gpl-3.0
- Language: Python
- Default Branch: main
- Homepage: https://setuptools-generate.readthedocs.io/
- Size: 85 KB
Statistics
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 3
- Releases: 6
Topics
Metadata Files
README.md
setuptools-generate
Generate shell completions and man page when building a python package.
Usage
Add this package to your build requires:
```toml [build-system] requires = [ "setuptools-generate >= 0.0.6",] build-backend = "setuptools.build_meta"
[project] name = "demo" version = "0.0.1"
[project.scripts] demo = "demo:main"
[tool.setuptools.data-files] "share/application" = [ "assets/desktop/demo.desktop",] "share/icons/hicolor/256x256/apps" = [ "src/demo/assets/images/demo.png",] "share/man/man1" = [ "sdist/demo.1",] "share/bash-completion/completions" = [ "sdist/demo",] "share/zsh/site-functions" = [ "sdist/_demo",] ```
Build your package:
sh
python -m build
console
$ tree sdist
sdist
├── _demo # zsh completion script
├── demo # bash completion script
├── demo.1 # man page
└── demo.fish # fish completion script
$ tree dist
dist
├── demo-0.0.1-py3-none-any.whl # wheel file
└── demo-0.0.1.tar.gz # source distribution file
You got them.
Now pip install --prefix=/the/root/of/usr dist/*.whl, you will see:
sh
$ tree /the/root/of/usr
/the/root/of/usr
├── bin
│ └── trans
├── lib
│ └── python3.10
│ └── site-packages
│ ├── foo
│ │ └── ...
│ └── foo-0.0.1.dist-info
│ └── ...
└── share
~ ├── application
~ │ └── foo.desktop
~ ├── bash-completion
~ │ └── completions
~ │ └── foo
~ ├── icons
~ │ └── hicolor
~ │ └── 256x256
~ │ └── apps
~ │ └── foo.png
~ ├── man
~ │ └── man1
~ │ └── foo.1
~ └── zsh
~ └── site-functions
~ └── _foo
For linux package (deb, rpm, pkg.zst, ...), it will be very easy.
Example projects:
- demo for click
- demo for shtab
- See more on wiki.
See document to know more.
Owner
- Name: wzy
- Login: Freed-Wu
- Kind: user
- Location: $HOME
- Company: @ustc-ivclab
- Website: https://freed-wu.github.io/
- Twitter: FreedWu
- Repositories: 267
- Profile: https://github.com/Freed-Wu
An adherent of hacker culture and open source.
Citation (CITATION.cff)
---
cff-version: 1.2.0
message: If you use this software, please cite it as below.
authors:
- family-names: Wu
given-names: Zhenyu
orcid: https://orcid.org/0000-0001-6478-9993
title: "setuptools-generate: Generate shell completions and man page when building a python package."
date-released: 2022-12-03
url: "https://github.com/Freed-Wu/setuptools-generate"
GitHub Events
Total
- Push event: 66
Last Year
- Push event: 66
Committers
Last synced: 7 months ago
Top Committers
| Name | Commits | |
|---|---|---|
| Wu Zhenyu | w****u@u****u | 28 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 7 months ago
All Time
- Total issues: 1
- Total pull requests: 2
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Total issue authors: 1
- Total pull request authors: 2
- Average comments per issue: 1.0
- Average comments per pull request: 1.5
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 2
Past Year
- Issues: 1
- Pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Issue authors: 1
- Pull request authors: 0
- Average comments per issue: 1.0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- dbarnett (1)
Pull Request Authors
- pre-commit-ci[bot] (1)
- renovate[bot] (1)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 1
-
Total downloads:
- pypi 1,581 last-month
- Total dependent packages: 0
- Total dependent repositories: 0
- Total versions: 6
- Total maintainers: 1
pypi.org: setuptools-generate
Generate shell completions and man page when building a python package.
- Homepage: https://setuptools-generate.readthedocs.io
- Documentation: https://setuptools-generate.readthedocs.io/
- License: GPL v3
-
Latest release: 0.0.6
published almost 3 years ago
Rankings
Maintainers (1)
Dependencies
- actions/checkout v3 composite
- actions/setup-python v4 composite
- actions/upload-artifact v3 composite
- codecov/codecov-action v3 composite
- pypa/gh-action-pypi-publish release/v1 composite
- softprops/action-gh-release v1 composite
- myst-parser *
- sphinxcontrib-eval *
- tomli *
- pre-commit * development
- pytest-cov * development
- tomli * development
- click *
- help2man *
- setuptools *
- shtab *
- tomli >=1.0.0