Fead
Fead a tool for advertising other blogs you like on your own by embedding the summary of their latest post(s) extracted from their web feed. It is a rewrite of openring with (rejected) concurrency support in Python without any third-party library.
Installation
On POSIX systems, run the usual make install with configurable PREFIX.
The following programs are needed for building and installation:
- make
- help2man
- install
Python 3.11+ is also required, both for generating the manual and at runtime.
On other systems, a package installer specific for Python might be preferred.
Usage
$ fead --help
Usage: fead [OPTION]...
Generate adverts from web feeds.
Options:
-h, --help show this help message and exit
-v, --version show program's version number and exit
-F PATH, --feeds PATH
file containing newline-separated web feed URLs
-f URL, --feed URL addtional web feed URL (multiple use)
-s, --strict abort when fail to fetch or parse a web feed
-n N, --count N maximum number of ads in total (default to 3)
-p N, --per-feed N maximum number of ads per feed (default to 1)
-l N, --length N maximum summary length (default to 256)
-t PATH, --template PATH
template file (default to stdin)
-o PATH, --output PATH
output file (default to stdout)
Any use of -f before -F is ignored.
Template
The template is used by Python str.format to generate each advert.
It can contain the following fields, delimited by braces ({ and }).
source_title: title of the web feedsource_link: URL to the feed's websitetitle: title of the feed itemlink: URL to the itemtime: publication timesummary: truncated content or description
The publication time is a Python datetime.datetime object,
which supports at least C89 format codes, e.g. {time:%Y-%m-%d}.
Examples
Given the these URLs in a feeds file:
https://adol.pw/index.xml
https://cnx.gdn/feed.xml
https://xrvs.net/index.xml
Advertisement of the two latest blogs among them, along with articles by Drew DeVault, can be generated via the following command.
echo "<article>
<h3><a href='{link}'>{title}</a></h3>
{summary}—<a href='{source_link}'>{source_title}</a>, {time:%F}
</article>" | fead -F feeds -f https://drewdevault.com/blog/index.xml -n 2
Contributing
Development happens on https://chim.loan/fead. Bug reports should be filed as tickets, and feedbacks and patches are welcomed in the forum.
Copying
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
Metadata
Release files for fead 1.0.1
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 | |
|---|---|---|---|---|
| fead-1.0.1.tar.gz | 17.5 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| fead-1.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 36.1 kB
Release files / fead-1.0.1.tar.gz
| Download URL | fead-1.0.1.tar.gz |
|---|---|
| Size | 17.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a98b97325a73bd59059c4af346b7a43b21fb93e5c517c17cc5a71b4aa3d129a4
|
|
BLAKE2b-256 checksum How to use checksums |
56fbe96caf000c2e8b407a0902910c029a563dcb1bbd3368a7a273a759a377ad
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-requests/2.32.5
|
Release files / fead-1.0.1-py3-none-any.whl
| Download URL | fead-1.0.1-py3-none-any.whl |
|---|---|
| Size | 18.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
805a849a88ab0ad101569d7340ab7dd70c32b8473a930a58fba778ffb2a7e579
|
|
BLAKE2b-256 checksum How to use checksums |
c0e596d9e71665fdaa64a22a338dee992d782d9e0aa74fd709f6c33ae72f2361
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-requests/2.32.5
|
Security for fead 1.0.1
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.