From 4a378e4976ff535b7a4a985424cd39e72621c74e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karol=20Jagodzi=C5=84ski?= Date: Mon, 29 Jan 2024 09:26:03 +0100 Subject: [PATCH] Apply changes from code review --- .gitignore | 2 +- README.md | 10 ++++++++-- docs/index.md | 14 +++++++++----- 3 files changed, 18 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index 437035f..734267e 100644 --- a/.gitignore +++ b/.gitignore @@ -157,7 +157,7 @@ cython_debug/ # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore # and can be added to the global gitignore or merged into this file. For a more nuclear # option (not recommended) you can uncomment the following to ignore the entire idea folder. -#.idea/ +.idea/ .vscode .ruff_cache .python-version diff --git a/README.md b/README.md index a802573..009219e 100644 --- a/README.md +++ b/README.md @@ -36,12 +36,16 @@ Install [Hatch](https://hatch.pypa.io/latest/install/#pipx). ### Documentation -You can deploy a local documentation service, it reloads changes and allow for a live preview of how the documentation will look like after publication: +1. Run the below command to start a dev server with the documentation site: ``` hatch run docs:serve ``` +Dev server provides a live reload on changes and lets you preview the site after it's published + + + and navigate to http://127.0.0.1:8000 ### Tests @@ -64,7 +68,9 @@ hatch run lint:all ### Build and deploy -This is done by a CI/CD workflow upon the creation of a release but in case of the need for a manual publication of the packager to PyPI you need to build the package archive and publish it. +To publish a new version to PyPI, update it's version number in the `pyproject/toml` file and create new github release. + +In case whe you need to make a new release without GitHub workflow, use following `hatch` commands: ``` hatch build -c diff --git a/docs/index.md b/docs/index.md index 4eda43a..fc854be 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,14 +1,18 @@ # Introduction -Saleor SDK Python is a Python library which purpose is to contain code that is repeated in different Saleor applications. +Saleor SDK Python is a Python library that implements tools and solutions useful in Saleor application development, including: -You should read [Saleor's Documentation](https://docs.saleor.io/docs/3.x/developer/extending/overview) on the topic to get a grasp on the concepts of the "app framework" Saleor comes with. +- the `saleor_sdk.crypto` package for working with Saleor's auth. -This SDK is agnostic of any framework, which makes it possible to use in all sorts of web (or otherwise) frameworks and even scripts. +Before starting, you should familiarize yourself with Saleor's [Extending Saleor](https://docs.saleor.io/docs/3.x/developer/extending/overview) documentation +and learn basic concepts like apps, webhooks and events. -## What about Python App Framework? -The old [saleor-app-framework-python](https://github.com/mirumee/saleor-app-framework-python) was very opinionated on how an application should be crated. It required FastAPI and in a specific version of it. +This SDK is framework agnostic. It can be used with any Python web framework, or without framework as part of a script. + +## What about the Python App Framework? + +The [saleor-app-framework-python](https://github.com/mirumee/saleor-app-framework-python) has been deprecated and is no longer maintained. ## Installation