Skip to main content utilities module

Project description

jgutils: A Python Utility Module

This package is currently targeting Python3.7+ but it *should work with Python3.6+.


pip install jgutils

Get Files (getfiles)

  • todo: add wild-card support
  • todo: tests

File listing utility. Basic matching and sorting.

Natural Sort (naturalsort)

  • todo: more tests

Sorting for Humans; Two Modes

mylist = ['elm0', 'elm1', 'Elm2', 'elm9', 'elm10', 'Elm11', 'Elm12', 'elm13', 'elm']
mode1 =  ['elm', 'elm0', 'elm1', 'Elm2', 'elm9', 'elm10', 'Elm11', 'Elm12', 'elm13']
mode2 =  ['elm', 'elm0', 'elm1', 'Elm2', 'elm9', 'elm10', 'Elm11', 'Elm12', 'elm13']

mylist1 = ['e0lm', 'e1lm', 'E2lm', 'e9lm', 'e10lm', 'E12lm', 'e13lm', 'elm', 'e01lm']
mode1 =   ['e0lm', 'e1lm', 'e01lm', 'E2lm', 'e9lm', 'e10lm', 'E12lm', 'e13lm', 'elm']
mode2 =   ['elm', 'e0lm', 'e1lm', 'E2lm', 'e9lm', 'e01lm', 'e10lm', 'E12lm', 'e13lm']

Persistent Dictionary (persistentdict)

  • todo: more tests

In-Memory dictionary with transparent disk-based backing.

Replace (replace)

Based on the built-in replace. Accepts a list of 'old' substrings to be replaced by a single 'new' substring.

Varprint (varprint)

Prints the name of the variable and the value.

[<variable_name>] (<variable_length>): <variable_content>
[a] (8): some_var


Project details

Download files

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

Files for jgutils, version
Filename, size File type Python version Upload date Hashes
Filename, size jgutils- (20.2 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page