Skip to content

Latest commit

 

History

History
82 lines (54 loc) · 1.8 KB

File metadata and controls

82 lines (54 loc) · 1.8 KB

Python Scripts

Python License: MIT Pylint, Pytest and Build

A collection of small Python scripts including:

📥 Installation

Mac with Pyenv

See this guide on StackOverflow

Install modules with pip

pip install .

🧹 Lint

pylint $(git ls-files '*.py')

🧪 Test

pytest tests --junitxml=junit/test-results.xml --html=junit/test-results.html

🛠️ Build

python -m build

🧾 Scripts

check_urls.py

This script checks URLs defined in a JSON file. For each URL, it verifies if the response contains a specific string and prints the result using emojis to indicate success or failure.

Usage check_url

scripts/check_urls.py data/urls.json

filter_lambda.py

lambda function within filter to select fruits starting with "A" from a list

Usage filter_lambda

scripts/filter_lambda.py

hello_world.py

simple hello world

Usage hello_world

scripts/hello_world.py

🌐 Related Links

Tool / Topic Link
Pyenv https://github.com/pyenv/pyenv
Build module https://pypi.org/project/build/
Pytest https://docs.pytest.org/
Pylint https://pylint.pycqa.org/