-
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(discordsh): python files for the discordsh
- Loading branch information
Showing
11 changed files
with
146 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
[flake8] | ||
exclude = | ||
.git, | ||
__pycache__, | ||
build, | ||
dist, | ||
.tox, | ||
venv, | ||
.venv, | ||
.pytest_cache | ||
max-line-length = 120 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
3.9.5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# pydiscordsh | ||
|
||
Project description here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
[virtualenvs] | ||
in-project = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
{ | ||
"name": "pydiscordsh", | ||
"$schema": "../node_modules/nx/schemas/project-schema.json", | ||
"projectType": "application", | ||
"sourceRoot": "pydiscordsh/pydiscordsh", | ||
"targets": { | ||
"lock": { | ||
"executor": "@nxlv/python:run-commands", | ||
"options": { | ||
"command": "poetry lock --no-update", | ||
"cwd": "pydiscordsh" | ||
} | ||
}, | ||
"add": { | ||
"executor": "@nxlv/python:add", | ||
"options": {} | ||
}, | ||
"update": { | ||
"executor": "@nxlv/python:update", | ||
"options": {} | ||
}, | ||
"remove": { | ||
"executor": "@nxlv/python:remove", | ||
"options": {} | ||
}, | ||
"build": { | ||
"executor": "@nxlv/python:build", | ||
"outputs": ["{projectRoot}/dist"], | ||
"options": { | ||
"outputPath": "pydiscordsh/dist", | ||
"publish": false, | ||
"lockedVersions": true, | ||
"bundleLocalDependencies": true | ||
}, | ||
"cache": true | ||
}, | ||
"install": { | ||
"executor": "@nxlv/python:install", | ||
"options": { | ||
"silent": false, | ||
"args": "", | ||
"cacheDir": ".cache/pypoetry", | ||
"verbose": false, | ||
"debug": false | ||
} | ||
}, | ||
"lint": { | ||
"executor": "@nxlv/python:flake8", | ||
"outputs": ["{workspaceRoot}/reports/pydiscordsh/pylint.txt"], | ||
"options": { | ||
"outputFile": "reports/pydiscordsh/pylint.txt" | ||
}, | ||
"cache": true | ||
}, | ||
"test": { | ||
"executor": "@nxlv/python:run-commands", | ||
"outputs": [ | ||
"{workspaceRoot}/reports/pydiscordsh/unittests", | ||
"{workspaceRoot}/coverage/pydiscordsh" | ||
], | ||
"options": { | ||
"command": "poetry run pytest tests/", | ||
"cwd": "pydiscordsh" | ||
}, | ||
"cache": true | ||
} | ||
}, | ||
"tags": [], | ||
"release": { | ||
"version": { | ||
"generator": "@nxlv/python:release-version" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
"""Automatically generated by Nx.""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
"""Sample Hello World application.""" | ||
|
||
|
||
def hello(): | ||
"""Return a friendly greeting.""" | ||
return "Hello pydiscordsh" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
[tool.coverage.run] | ||
branch = true | ||
source = [ "pydiscordsh" ] | ||
|
||
[tool.coverage.report] | ||
exclude_lines = ['if TYPE_CHECKING:'] | ||
show_missing = true | ||
|
||
[tool.pytest.ini_options] | ||
addopts = "--cov --cov-report html:'../coverage/pydiscordsh/html' --cov-report xml:'../coverage/pydiscordsh/coverage.xml' --html='../reports/pydiscordsh/unittests/html/index.html' --junitxml='../reports/pydiscordsh/unittests/junit.xml'" | ||
|
||
[tool.poetry] | ||
name = "pydiscordsh" | ||
version = "1.0.0" | ||
description = "Automatically generated by Nx." | ||
authors = [ ] | ||
license = 'Proprietary' | ||
readme = 'README.md' | ||
|
||
[[tool.poetry.packages]] | ||
include = "pydiscordsh" | ||
|
||
[tool.poetry.dependencies] | ||
python = ">=3.9,<3.11" | ||
|
||
[tool.poetry.group.dev.dependencies] | ||
autopep8 = "2.3.1" | ||
flake8 = "7.1.1" | ||
pytest = "8.3.4" | ||
pytest-sugar = "1.0.0" | ||
pytest-cov = "6.0.0" | ||
pytest-html = "4.1.1" | ||
|
||
[build-system] | ||
requires = ["poetry-core"] | ||
build-backend = "poetry.core.masonry.api" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
"""unit tests.""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
"""Unit tests configuration module.""" | ||
|
||
pytest_plugins = [] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
"""Hello unit test module.""" | ||
|
||
from pydiscordsh.hello import hello | ||
|
||
|
||
def test_hello(): | ||
"""Test the hello function.""" | ||
assert hello() == "Hello pydiscordsh" |