Skip to main content

Scientific project path utilities (find, split, symlink, versioning)

Project description

scitex-path

Scientific project path utilities for the SciTeX ecosystem.

Provides file/directory finding, path splitting, symlink management, and version incrementing.

Installation

pip install scitex-path

Usage

import scitex_path as sp

# Find files by pattern
matches = sp.find_file("*.csv", root="/data/project")

# Find the nearest git root
git_root = sp.find_git_root()

# Split path into components
parts = sp.split("/home/user/project/data/results.csv")

# Symlink management
sp.symlink("/data/raw", "/project/data/raw")
sp.list_symlinks("/project/data")
sp.fix_broken_symlinks("/project/data")

# Version incrementing
next_ver = sp.increment_version("v1.2.3", part="patch")  # "v1.2.4"
latest = sp.find_latest("/results/experiment_v*")

API

Function Description
find_file Find files matching a glob pattern
find_dir Find directories matching a glob pattern
find_git_root Locate the nearest .git root
split Split a path into structured components
symlink Create a symlink
create_relative_symlink Create a relative symlink
list_symlinks List symlinks under a directory
fix_broken_symlinks Remove or report broken symlinks
resolve_symlinks Resolve all symlinks to real paths
increment_version Bump a version string
find_latest Find the latest versioned path
clean Clean/normalize a path
getsize Get file/directory size
get_spath / mk_spath Session path helpers
this_path / get_this_path Get the path of the calling script

License

AGPL-3.0 -- see LICENSE for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

scitex_path-0.1.1.tar.gz (45.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

scitex_path-0.1.1-py3-none-any.whl (28.1 kB view details)

Uploaded Python 3

File details

Details for the file scitex_path-0.1.1.tar.gz.

File metadata

  • Download URL: scitex_path-0.1.1.tar.gz
  • Upload date:
  • Size: 45.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for scitex_path-0.1.1.tar.gz
Algorithm Hash digest
SHA256 8dd94ba097d9a51a3c1592ec9501a7fc44169efb4d8402d0f697814fd2b1b794
MD5 87ecfffb32b10a65e7ea7f106730c114
BLAKE2b-256 45e843ad26fcf7db6e16761976fc1f900a4d484187f8e46d7b50d6a143acb531

See more details on using hashes here.

Provenance

The following attestation bundles were made for scitex_path-0.1.1.tar.gz:

Publisher: publish-pypi.yml on ywatanabe1989/scitex-path

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file scitex_path-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: scitex_path-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 28.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for scitex_path-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f9f5b294398d712433c477b8005ccbe455800c7d2b6bb91386a9a8366da77703
MD5 8925eeb0c24819dc8e0fa29930fdd138
BLAKE2b-256 93114b4eebad6ac5985d9a45637fdadfa2296ca884321c630b04820588cdc3af

See more details on using hashes here.

Provenance

The following attestation bundles were made for scitex_path-0.1.1-py3-none-any.whl:

Publisher: publish-pypi.yml on ywatanabe1989/scitex-path

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page