From 85f867e5eeea9553fbd02bb8fc0b1a61ead9bc9f Mon Sep 17 00:00:00 2001 From: Jakob Pinterits Date: Wed, 10 Apr 2024 23:00:47 +0200 Subject: [PATCH] breaking update to new revel version --- pyproject.toml | 4 ++-- rio/cli/__init__.py | 11 +++++++---- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index d5fb7747..b2ee9cba 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -5,7 +5,7 @@ build-backend = "poetry.core.masonry.api" [tool.poetry] license = "LGPL-3.0" # TODO name = "rio-ui" -version = "0.5.2" +version = "0.5.3" description = "Build modern Websites and Apps just with Python" authors = ["Jakob Pinterits ", "Paul Pinterits"] readme = "README.md" @@ -62,7 +62,7 @@ python-levenshtein = "^0.23.0" python-multipart = "^0.0.6" pytz = "^2024.1" pywebview = { version = "^4.2.2", optional = true } -revel = "0.8.19" +revel = "^0.9.0" timer-dict = "^1.0.0" tomlkit = "^0.12.3" typing-extensions = "^4.5.0" diff --git a/rio/cli/__init__.py b/rio/cli/__init__.py index bf26340a..eb2fd16b 100644 --- a/rio/cli/__init__.py +++ b/rio/cli/__init__.py @@ -1,9 +1,9 @@ -import logging from typing import Literal +import imy.package_metadata import introspection import revel -from revel import error, fatal, print, success, warning +from revel import * # type: ignore import rio.snippets @@ -17,7 +17,9 @@ revel.GLOBAL_STYLES.add_alias("primary", ["cyan"]) revel.GLOBAL_STYLES.add_alias("bg-primary", ["bg-cyan"]) app = revel.App( - summary="An easy to use, app & web framework for Python", + nicename="Rio", + command_name="rio", + summary="An easy to use, web & app framework for Python", details=""" Rio is a framework for building reactive apps and websites in Python. It's designed to be easy to use, and to get out of your way as much as possible. @@ -25,6 +27,7 @@ designed to be easy to use, and to get out of your way as much as possible. This is the command line interface for Rio. You can use it to easily create new projects, run them, and more. """, + version=imy.package_metadata.get_package_version("rio-ui"), ) @@ -192,7 +195,7 @@ class {class_name}(rio.Component): def build(self) -> rio.Component: return rio.Markdown(''' ## This is a sample component - + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. ''') """