A python lib created from Difficult Rocket development
Project description
lib-not-dr
A python lib came from Difficult Rocket development
一个在 Difficult Rocket 开发中 分离出来的 python 库
Information/信息
- Version / 版本: 0.3.11
- Author / 作者: shenjackyuanjie 3695888@qq.com
License/许可证
安装/Install
pip install lib-not-dr
pip install lib-not-dr[nuitka]
# install with nuitka support
# 安装支持 nuitka 的版本
使用/Usage
Logger
WIP 等待 0.4.0
from lib_not_dr import loggers
logger = loggers.get_logger("test")
logger.fine('Hello World!')
logger.debug('Hello World!')
logger.trace('Hello tracing!')
logger.info('Hello World!') # info!
logger.warn('warnnnnnnn')
logger.error('Hello World!')
logger.fatal('good bye world')
# tag
logger.info('this message if from tag', tag='test')
logger.debug('this debug log if from admin', tag='admin')
# end
logger.debug('and this message ends with none', end=' ')
logger.trace('so this message will be in the same line', tag='same line!')
Nuitka pyproject paser
pyproject.toml
内的配置Config in
pyproject.toml
前往 example/nuitka 查看更多例子
[tool.lndl.nuitka.cli]
main = "main.py"
# --main=main.py
standalone = true
onefile = false
[tool.lndl.nuitka]
script = "xxx.py"
通过
lndl_nuitka
命令行工具使用Use with
lndl_nuitka
command line tool
建议使用
pip install lib-not-dr[nuitka]
安装 lib-not-dr
lndl_nuitka .
lndl_nuitka . -- --onefile
# add --onefile to nuitka
lndl_nuitka . -y
# run without confirmation
lndl_nuitka . -n
# do not run
通过
lib_not_dr.nuitka.reader
模块使用Use with
lib_not_dr.nuitka.reader
from tomli import loads
from lib_not_dr.nuitka.reader import main, run_nuitka
pyproject_toml = loads(open("pyproject.toml", "r").read())
nuitka_config = pyproject_toml["tool"]["lndl"]["nuitka"]
nuitka_config["product_version"] = "0.1.0"
command = main(nuitka_config)
run_nuitka(command)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
lib-not-dr-0.3.11.tar.gz
(37.4 kB
view details)
Built Distribution
File details
Details for the file lib-not-dr-0.3.11.tar.gz
.
File metadata
- Download URL: lib-not-dr-0.3.11.tar.gz
- Upload date:
- Size: 37.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: pdm/2.10.4 CPython/3.8.18+
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 255fa8bb40bc2404191c100c209fbccf81d8afe333ee4bee964054dd87132553 |
|
MD5 | f1e7505f43c69bf5a10c1541dd1f2db2 |
|
BLAKE2b-256 | 14b16ed959e4ac285694d7de805b178f8fbfc70922a007b47578d72f12209548 |
File details
Details for the file lib_not_dr-0.3.11-py3-none-any.whl
.
File metadata
- Download URL: lib_not_dr-0.3.11-py3-none-any.whl
- Upload date:
- Size: 43.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: pdm/2.10.4 CPython/3.8.18+
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a4ccd9a0194a41efa86501243baeb1cb36091c71d6d2e53a6173b9b030c2d6a4 |
|
MD5 | e5d5b62c74ae2b7fd37715de490d7a3d |
|
BLAKE2b-256 | d20b8eb595c9aa365db5c5c62a85bdaf274df7ae2c1e5bcfa2e99f71402c687b |