Skip to main content

streaming text processing

Project description

[![Build Status](https://travis-ci.org/geowurster/pyin.svg?branch=master)](https://travis-ci.org/geowurster/pyin) [![Coverage Status](https://coveralls.io/repos/geowurster/pyin/badge.svg?branch=master)](https://coveralls.io/r/geowurster/pyin?branch=master)

Perform Python operations on every line read from stdin. Every line is evaluated individually and available via a variable called line.

Installing

Via pip:

$ pip install git+https://github.com/geowurster/pyin.git

From master branch:

$ git clone https://github.com/geowurster/pyin $ pip install -e .

Examples

Change newline character in a CSV.

$ more sample-data/csv-with-header.csv | pyin “line.replace(’n’, ‘rn’)” > output.csv

Developing

Install:

$ pip install virtualenv $ git clone https://github.com/geowurster/pyin $ cd pyin $ virtualenv venv $ source venv/bin/activate $ pip install -r requirements-dev.txt $ pip install -e .

Test:

$ nosetests

Coverage:

$ nosetests –with-coverage

Lint:

$ pep8 –max-line-length=120 pyin.py

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

pyin-0.1.0.tar.gz (4.3 kB view details)

Uploaded Source

File details

Details for the file pyin-0.1.0.tar.gz.

File metadata

  • Download URL: pyin-0.1.0.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for pyin-0.1.0.tar.gz
Algorithm Hash digest
SHA256 17faf5a1d4e0099d692c8f1de6678831b6d6ecdec7f0c7b14189d42132f286e0
MD5 114b9a8eda6fe86ca40a8398b1f077ff
BLAKE2b-256 680fe083cc49fe7e2fda80291f006bf28631319f45aa896bc2c784fd12bb89e5

See more details on using hashes here.

Supported by

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