linerepeat
A small CLI tool for repeating lines from stdin or files. Useful for generating test data, creating separators, duplicating content, or any task where you need to repeat text patterns.
Features:
- Line mode (default): Repeat each input line N times
- Block mode: Repeat groups of lines as blocks
- Custom separators: Add delimiters between input line groups
- Flexible I/O: Read from stdin/files, write to stdout/files
Install
From PyPI
pip install linerepeat
Pre-built Binaries
Download the latest linerepeat binary (Linux) or linerepeat.exe (Windows) from GitHub Releases.
Usage
$ linerepeat [OPTIONS] {count}
Arguments:
count: How many times to repeat. [required]
Options:
-i, --input <file>: Edit this file in place instead of reading stdin.-o, --output <file>: Write here instead of stdout. Can't be used with --input.-s, --separator <str>: Line placed between repeats.-m, --mode <line|block>: Repeat single lines or blocks. [default: line]-t, --till <int>: Lines per block (block mode). [default: 0]--help: Show this message and exit.
Examples
# Repeat each line 3 times (single line - no separator printed)
echo "hello" | linerepeat 3
# hello
# hello
# hello
# With multiple input lines, separator goes BETWEEN lines
echo -e "a\nb" | linerepeat 2 -s "---"
# a
# a
# ---
# b
# b
# Block mode with separator between blocks
echo -e "line1\nline2\nline3\nline4" | linerepeat 2 -m block -t 2 -s "==="
# line1
# line2
# ===
# line1
# line2
# ===
# line3
# line4
# ===
# line3
# line4
# In-place: duplicate every line in a file
linerepeat 2 -i file.txt
License
MIT
Metadata
Release files for linerepeat 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| linerepeat-0.1.0.tar.gz | 4.9 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| linerepeat-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 11.2 kB
Release files / linerepeat-0.1.0.tar.gz
| Download URL | linerepeat-0.1.0.tar.gz |
|---|---|
| Size | 4.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
41153a2d273b34c40b9ad34b867c63af6f718bdba365ae0b80681af340cc58a9
|
|
BLAKE2b-256 checksum How to use checksums |
6c4b9fec82b2e7ef24186d2ad86a54ba0be27c51aa12942a659a2058925bcaa7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.13.4 {"installer":{"name":"uv","version":"0.13.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / linerepeat-0.1.0-py3-none-any.whl
| Download URL | linerepeat-0.1.0-py3-none-any.whl |
|---|---|
| Size | 6.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
17a900496a80f8c0b1b2d05da0158e18346725f1645dc664bf84152f4239daef
|
|
BLAKE2b-256 checksum How to use checksums |
65652d93a0f277562251a62a081efe36c83cfbb60a573dfdf109f09e151f6bc1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.13.4 {"installer":{"name":"uv","version":"0.13.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Arch Linux","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for linerepeat 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.