File tree Expand file tree Collapse file tree
src/python_package_template Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- # python-package-template
1+ # python_package_template
2+
23🐍 Python package template
4+
5+ ## Development
6+
7+ Create virtual environment:
8+
9+ ``` sh
10+ python3 -m venv .venv
11+ ```
12+
13+ Activate virtual environment:
14+
15+ ``` sh
16+ source .venv/bin/activate
17+ ```
18+
19+ Install PyPA's [ build] ( https://github.com/pypa/build ) :
20+
21+ ``` sh
22+ python3 -m pip install --upgrade build
23+ ```
24+
25+ Generate distribution packages:
26+
27+ ``` sh
28+ python3 -m build
29+ ```
30+
31+ Install [ Twine] ( https://github.com/pypa/twine ) :
32+
33+ ``` sh
34+ python3 -m pip install --upgrade twine
35+ ```
36+
37+ Upload all of the archives under ` dist ` :
38+
39+ ``` sh
40+ python3 -m twine upload --repository testpypi dist/*
41+ ```
42+
43+ ## License
44+
45+ [ MIT] ( LICENSE )
Original file line number Diff line number Diff line change 1+ [project ]
2+ name = " python_package_template"
3+ version = " 1.0.0-alpha"
4+ authors = [
5+ { name =" Mark" , email =" mark@remarkablemark.org" },
6+ ]
7+ description = " Python package template"
8+ readme = " README.md"
9+ requires-python = " >=3.8"
10+ classifiers = [
11+ " Programming Language :: Python :: 3" ,
12+ " Operating System :: OS Independent" ,
13+ ]
14+ license = " MIT"
15+ license-files = [" LICEN[CS]E*" ]
16+
17+ [project .urls ]
18+ Homepage = " https://github.com/remarkablemark/python_package_template"
19+ Issues = " https://github.com/remarkablemark/python_package_template/issues"
Original file line number Diff line number Diff line change 1+ def hello (name : str = "World" ) -> str :
2+ """
3+ Greet a name.
4+
5+ Args:
6+ name (str): The optional name.
7+
8+ Returns:
9+ greeting (str): The greeting.
10+ """
11+ return f"Hello, { name } !"
You can’t perform that action at this time.
0 commit comments