Skip to main content

Stupid Simple Pipe

Project description

Stupid Simple Pipe

pip install sspipe then:

  • x | p(f) is equal to f(x)
  • x | p(f).attr[item](arg) + 2 | p(g) is equal to g( f(x).attr[item](arg) + 2 )
  • (x | p(f)) | p(g) is equal to x | (p(f) | p(g))
  • px is equal to p(lambda x: x)

Now, instead of

from pathlib import Path

print(' '.join(list(map(str, filter((lambda x: x.is_dir()), Path('/etc').glob('*'))))))

Write:

from sspipe import p, px
from pathlib import Path

Path('/etc').glob('*') | p.filter(px.is_dir()) | p.map(str) | p(list) | p(' '.join) | p(print)

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

sspipe-0.0.7.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

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

sspipe-0.0.7-py3-none-any.whl (4.2 kB view details)

Uploaded Python 3

File details

Details for the file sspipe-0.0.7.tar.gz.

File metadata

  • Download URL: sspipe-0.0.7.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for sspipe-0.0.7.tar.gz
Algorithm Hash digest
SHA256 2acfe9071518a84aed4639110f1429b83730390e45b3b78076735f9175989ebe
MD5 ab97623e814ebdbfd99a71afa106937d
BLAKE2b-256 2b2bbe684f25200888e0e6bce9127ced2fd3e3f2a185ca9d1d0c0b823585cb94

See more details on using hashes here.

File details

Details for the file sspipe-0.0.7-py3-none-any.whl.

File metadata

File hashes

Hashes for sspipe-0.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 7cc4e37dc8d2e6a94410806e24d50982de111eeffd0a2b80bbd6420fd0e98029
MD5 b704f5c3a51901c2a0001bcec83cc335
BLAKE2b-256 8983944611ff8d1322bab4ffacb1c9673d31574e392d685c804b972d0c7ae91e

See more details on using hashes here.

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