跳转到主要内容

杂项路径函数

项目描述

https://img.shields.io/pypi/v/jaraco.path.svg https://img.shields.io/pypi/pyversions/jaraco.path.svg tests Ruff https://img.shields.io/badge/skeleton-2024-informational

隐藏文件检测

jaraco.path 提供跨平台的隐藏文件检测

from jaraco import path
if path.is_hidden('/'):
    print("Your root is hidden")

hidden_dirs = filter(is_hidden, os.listdir('.'))

目录构建器

在测试(以及在可能的情况下),通常需要从字典定义中创建目录/文件的树。此项目提供了一个 build 函数,可以简单地从字典定义中创建这样的目录

from jaraco.path import build
build(
    {
        'foo': 'Content of foo',
        'subdir': {
            'foo': 'Content of subdir/foo',
        },
    },
)

项目详情


下载文件

下载适合您平台的文件。如果您不确定选择哪个,请了解更多关于 安装包 的信息。

源代码分发

jaraco_path-3.7.1.tar.gz (11.8 kB 查看哈希值)

上传时间: 源代码

构建分发

jaraco.path-3.7.1-py3-none-any.whl (6.5 kB 查看哈希值)

上传于 Python 3

由 ... 支持

AWSAWS云计算和安全赞助商DatadogDatadog监控FastlyFastlyCDNGoogleGoogle下载分析MicrosoftMicrosoftPSF赞助商PingdomPingdom监控SentrySentry错误日志StatusPageStatusPage状态页面