greet-anyone 0.0.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- greet_anyone-0.0.1/LICENSE +21 -0
- greet_anyone-0.0.1/PKG-INFO +52 -0
- greet_anyone-0.0.1/README.md +28 -0
- greet_anyone-0.0.1/greet_anyone/__init__.py +3 -0
- greet_anyone-0.0.1/greet_anyone/cli.py +16 -0
- greet_anyone-0.0.1/greet_anyone/core.py +2 -0
- greet_anyone-0.0.1/greet_anyone.egg-info/PKG-INFO +52 -0
- greet_anyone-0.0.1/greet_anyone.egg-info/SOURCES.txt +12 -0
- greet_anyone-0.0.1/greet_anyone.egg-info/dependency_links.txt +1 -0
- greet_anyone-0.0.1/greet_anyone.egg-info/entry_points.txt +2 -0
- greet_anyone-0.0.1/greet_anyone.egg-info/top_level.txt +2 -0
- greet_anyone-0.0.1/pyproject.toml +37 -0
- greet_anyone-0.0.1/setup.cfg +4 -0
- greet_anyone-0.0.1/tests/test.py +15 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 rotgruengelb
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
|
13
|
+
all copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
21
|
+
THE SOFTWARE.
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: greet_anyone
|
|
3
|
+
Version: 0.0.1
|
|
4
|
+
Summary: A library and cli to greet anyone.
|
|
5
|
+
Author-email: rotgruengelb <daniel+python-package-template@rotgruengelb.net>
|
|
6
|
+
License: MIT
|
|
7
|
+
Project-URL: Homepage, https://github.com/rotgruengelb/python-package-template
|
|
8
|
+
Project-URL: Documentation, https://github.com/rotgruengelb/python-package-template#readme
|
|
9
|
+
Project-URL: Source, https://github.com/rotgruengelb/python-package-template
|
|
10
|
+
Project-URL: Tracker, https://github.com/rotgruengelb/python-package-template/issues
|
|
11
|
+
Keywords: cli,tool
|
|
12
|
+
Classifier: Programming Language :: Python :: 3
|
|
13
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
14
|
+
Classifier: Operating System :: OS Independent
|
|
15
|
+
Classifier: Intended Audience :: Developers
|
|
16
|
+
Classifier: Intended Audience :: End Users/Desktop
|
|
17
|
+
Classifier: Topic :: Utilities
|
|
18
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
19
|
+
Classifier: Environment :: Console
|
|
20
|
+
Requires-Python: >=3.12
|
|
21
|
+
Description-Content-Type: text/markdown
|
|
22
|
+
License-File: LICENSE
|
|
23
|
+
Dynamic: license-file
|
|
24
|
+
|
|
25
|
+
# greet_anyone
|
|
26
|
+
|
|
27
|
+
A library and cli to greet anyone.
|
|
28
|
+
|
|
29
|
+
## Usage
|
|
30
|
+
|
|
31
|
+
### CLI
|
|
32
|
+
|
|
33
|
+
```
|
|
34
|
+
usage: cli.py [-h] [--exited EXITED] who
|
|
35
|
+
|
|
36
|
+
Greet anyone.
|
|
37
|
+
|
|
38
|
+
positional arguments:
|
|
39
|
+
who who to greet
|
|
40
|
+
|
|
41
|
+
options:
|
|
42
|
+
-h, --help show this help message and exit
|
|
43
|
+
--exited EXITED adds a exclamation point at the end
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
#### Examples
|
|
47
|
+
```sh
|
|
48
|
+
greet_anyone Traveler --exited true
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## Features
|
|
52
|
+
- Greet anyone
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# greet_anyone
|
|
2
|
+
|
|
3
|
+
A library and cli to greet anyone.
|
|
4
|
+
|
|
5
|
+
## Usage
|
|
6
|
+
|
|
7
|
+
### CLI
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
usage: cli.py [-h] [--exited EXITED] who
|
|
11
|
+
|
|
12
|
+
Greet anyone.
|
|
13
|
+
|
|
14
|
+
positional arguments:
|
|
15
|
+
who who to greet
|
|
16
|
+
|
|
17
|
+
options:
|
|
18
|
+
-h, --help show this help message and exit
|
|
19
|
+
--exited EXITED adds a exclamation point at the end
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
#### Examples
|
|
23
|
+
```sh
|
|
24
|
+
greet_anyone Traveler --exited true
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Features
|
|
28
|
+
- Greet anyone
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import argparse
|
|
2
|
+
|
|
3
|
+
from greet_anyone.core import greet
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
def main():
|
|
7
|
+
parser = argparse.ArgumentParser(description="Greet anyone.")
|
|
8
|
+
parser.add_argument("who", type=str, help="who to greet")
|
|
9
|
+
parser.add_argument("--exited", type=bool, default=False, help="adds a exclamation point at the end")
|
|
10
|
+
args = parser.parse_args()
|
|
11
|
+
|
|
12
|
+
print(greet(args.output, args.exited))
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
if __name__ == "__main__":
|
|
16
|
+
main()
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: greet_anyone
|
|
3
|
+
Version: 0.0.1
|
|
4
|
+
Summary: A library and cli to greet anyone.
|
|
5
|
+
Author-email: rotgruengelb <daniel+python-package-template@rotgruengelb.net>
|
|
6
|
+
License: MIT
|
|
7
|
+
Project-URL: Homepage, https://github.com/rotgruengelb/python-package-template
|
|
8
|
+
Project-URL: Documentation, https://github.com/rotgruengelb/python-package-template#readme
|
|
9
|
+
Project-URL: Source, https://github.com/rotgruengelb/python-package-template
|
|
10
|
+
Project-URL: Tracker, https://github.com/rotgruengelb/python-package-template/issues
|
|
11
|
+
Keywords: cli,tool
|
|
12
|
+
Classifier: Programming Language :: Python :: 3
|
|
13
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
14
|
+
Classifier: Operating System :: OS Independent
|
|
15
|
+
Classifier: Intended Audience :: Developers
|
|
16
|
+
Classifier: Intended Audience :: End Users/Desktop
|
|
17
|
+
Classifier: Topic :: Utilities
|
|
18
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
19
|
+
Classifier: Environment :: Console
|
|
20
|
+
Requires-Python: >=3.12
|
|
21
|
+
Description-Content-Type: text/markdown
|
|
22
|
+
License-File: LICENSE
|
|
23
|
+
Dynamic: license-file
|
|
24
|
+
|
|
25
|
+
# greet_anyone
|
|
26
|
+
|
|
27
|
+
A library and cli to greet anyone.
|
|
28
|
+
|
|
29
|
+
## Usage
|
|
30
|
+
|
|
31
|
+
### CLI
|
|
32
|
+
|
|
33
|
+
```
|
|
34
|
+
usage: cli.py [-h] [--exited EXITED] who
|
|
35
|
+
|
|
36
|
+
Greet anyone.
|
|
37
|
+
|
|
38
|
+
positional arguments:
|
|
39
|
+
who who to greet
|
|
40
|
+
|
|
41
|
+
options:
|
|
42
|
+
-h, --help show this help message and exit
|
|
43
|
+
--exited EXITED adds a exclamation point at the end
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
#### Examples
|
|
47
|
+
```sh
|
|
48
|
+
greet_anyone Traveler --exited true
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## Features
|
|
52
|
+
- Greet anyone
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
LICENSE
|
|
2
|
+
README.md
|
|
3
|
+
pyproject.toml
|
|
4
|
+
greet_anyone/__init__.py
|
|
5
|
+
greet_anyone/cli.py
|
|
6
|
+
greet_anyone/core.py
|
|
7
|
+
greet_anyone.egg-info/PKG-INFO
|
|
8
|
+
greet_anyone.egg-info/SOURCES.txt
|
|
9
|
+
greet_anyone.egg-info/dependency_links.txt
|
|
10
|
+
greet_anyone.egg-info/entry_points.txt
|
|
11
|
+
greet_anyone.egg-info/top_level.txt
|
|
12
|
+
tests/test.py
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=80.9.0", "wheel"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "greet_anyone"
|
|
7
|
+
description = "A library and cli to greet anyone."
|
|
8
|
+
version = "0.0.1" # set by uv during release
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
requires-python = ">=3.12"
|
|
11
|
+
license = { text = "MIT" }
|
|
12
|
+
authors = [{ name = "rotgruengelb", email = "daniel+python-package-template@rotgruengelb.net" }]
|
|
13
|
+
keywords = ["cli", "tool"]
|
|
14
|
+
dependencies = []
|
|
15
|
+
|
|
16
|
+
classifiers = ["Programming Language :: Python :: 3",
|
|
17
|
+
"License :: OSI Approved :: MIT License",
|
|
18
|
+
"Operating System :: OS Independent",
|
|
19
|
+
"Intended Audience :: Developers",
|
|
20
|
+
"Intended Audience :: End Users/Desktop",
|
|
21
|
+
"Topic :: Utilities",
|
|
22
|
+
"Development Status :: 5 - Production/Stable",
|
|
23
|
+
"Environment :: Console"]
|
|
24
|
+
|
|
25
|
+
[project.scripts]
|
|
26
|
+
cutstitch = "greet_anyone.cli:main"
|
|
27
|
+
|
|
28
|
+
[project.urls]
|
|
29
|
+
Homepage = "https://github.com/rotgruengelb/python-package-template"
|
|
30
|
+
Documentation = "https://github.com/rotgruengelb/python-package-template#readme"
|
|
31
|
+
Source = "https://github.com/rotgruengelb/python-package-template"
|
|
32
|
+
Tracker = "https://github.com/rotgruengelb/python-package-template/issues"
|
|
33
|
+
|
|
34
|
+
[tool.setuptools.packages.find]
|
|
35
|
+
where = ["."]
|
|
36
|
+
exclude = ["tests", "tests.*"]
|
|
37
|
+
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
from pathlib import Path
|
|
2
|
+
|
|
3
|
+
from greet_anyone.core import greet
|
|
4
|
+
|
|
5
|
+
ASSETS = Path(__file__).parent / "assets"
|
|
6
|
+
OUTPUT_DIR = Path(__file__).parent / "outputs"
|
|
7
|
+
OUTPUT_DIR.mkdir(exist_ok=True)
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
def test_greeting(tmp_path):
|
|
11
|
+
assert greet("Tester", False) == "Hello Tester"
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
def test_greeting_exited(tmp_path):
|
|
15
|
+
assert greet("Tester", True) == "Hello Tester!"
|