Finish initial content

This commit is contained in:
Wesley Moore 2024-03-10 14:31:33 +10:00
parent d84aec9435
commit af016fb99a
No known key found for this signature in database
19 changed files with 565 additions and 114 deletions

10
Makefile Normal file
View file

@ -0,0 +1,10 @@
list:
@echo "Available targets:"
@echo "- build"
@echo "- deploy"
build:
zola build
deploy: build
rsync -avzhP --delete public/ hardforze.binarytrance.com:infrastructure/volumes/www/rsspls.7bit.org/

View file

@ -1,3 +1,5 @@
title = "RSS Please"
# The URL the site will be built for # The URL the site will be built for
base_url = "https://rsspls.7bit.org" base_url = "https://rsspls.7bit.org"
@ -16,11 +18,13 @@ theme = "juice"
# Whether to do syntax highlighting # Whether to do syntax highlighting
# Theme can be customised by setting the `highlight_theme` variable to a theme supported by Zola # Theme can be customised by setting the `highlight_theme` variable to a theme supported by Zola
highlight_code = true highlight_code = true
highlight_theme = "OneHalfLight"
smart_punctuation = true smart_punctuation = true
[extra] [extra]
email = "wes@wezm.net" email = "wes@wezm.net"
author = "Wesley Moore" author = "Wesley Moore"
homepage = "https://www.wezm.net/"
juice_logo_name = "RSS Please" juice_logo_name = "RSS Please"
juice_logo_path = "feed-icon.svg" juice_logo_path = "feed-icon.svg"
juice_extra_menu = [ juice_extra_menu = [

View file

@ -1,17 +1,11 @@
+++ +++
title = "Home" title = "RSS Please"
description = "Generate RSS feeds from web pages"
sort_by = "weight" sort_by = "weight"
#paginate_by = 10 #paginate_by = 10
+++ +++
<div align="center"> <div class="text-center">
<strong>A small tool (<code>rsspls</code>) to generate RSS feeds from web pages that lack them.
It runs on BSD, Linux, macOS, Windows, and more.</strong>
</div>
<br>
<div align="center">
<a href="https://cirrus-ci.com/github/wezm/rsspls"> <a href="https://cirrus-ci.com/github/wezm/rsspls">
<img src="https://api.cirrus-ci.com/github/wezm/rsspls.svg" alt="Build Status"></a> <img src="https://api.cirrus-ci.com/github/wezm/rsspls.svg" alt="Build Status"></a>
<a href="https://crates.io/crates/rsspls"> <a href="https://crates.io/crates/rsspls">
@ -22,7 +16,11 @@ sort_by = "weight"
<br> <br>
`rsspls` generates RSS feeds from web pages. Example use cases: About
-----
`rsspls` generates RSS feeds from web pages using [CSS selectors][selectors] to extracts
parts of the page to turn into a feed. Example use cases:
* Create a feed for a blog that does not have one so that you will know when * Create a feed for a blog that does not have one so that you will know when
there are new posts. there are new posts.
@ -33,13 +31,28 @@ sort_by = "weight"
* Create a feed of the product page for a company, so you know when new * Create a feed of the product page for a company, so you know when new
products are added. products are added.
The idea is that you will then subscribe to the generated feeds in your feed You can subscribe to the generated feeds in your feed reader, either by
reader. This will typically require the feeds to be hosted via a web server. referring to them locally or by publishing them on a web server.
Credits <div class="text-center">
------- <a href="/install/" class="link-button">Install</a>
<a href="/documentation/" class="link-button">Documentation</a>
</div>
* [RSS feed icon](http://www.feedicons.com/) by The Mozilla Foundation FAQ
---
Frequently anticipated questions:
* _Does `rsspls` require a runtime or dependencies?_<br>
No. It's implemented in Rust and is a single-file native binary.
* _The screenshot at the top of the page looks like classic Mac OS.
Does it run on this system?_<br>
No. The screenshot _is_ from Mac OS 8 but it shows a [ssheven] window
logged in to a Linux system running `rsspls`.
* _Why did you use a screenshot from Mac OS 8?_<br>
I didn't want the screenshot to look like it was from any particular
modern system, so I picked an old one with a great design.
Licence Licence
------- -------
@ -51,8 +64,11 @@ This project is dual licenced under either of:
at your option. at your option.
[rustup]: https://www.rust-lang.org/tools/install Credits
[toml]: https://toml.io/ -------
* [RSS feed icon](http://www.feedicons.com/) by The Mozilla Foundation
* Website theme based on [Juice](https://github.com/huhu/juice) by HuHu
[selectors]: https://developer.mozilla.org/en-US/docs/Learn/CSS/Building_blocks/Selectors [selectors]: https://developer.mozilla.org/en-US/docs/Learn/CSS/Building_blocks/Selectors
[cron]: https://en.wikipedia.org/wiki/Cron [ssheven]: https://github.com/cy384/ssheven
[timers]: https://wiki.archlinux.org/title/Systemd/Timers

View file

@ -4,7 +4,49 @@ description = "Documentation"
weight = 2 weight = 2
+++ +++
### Configuration ## How it Works
`rsspls` fetches each page specified by the configuration and extracts elements
from the page using [CSS selectors][selectors]. For example elements are matched
to determine the title and content of the feed entry. The generated feeds are
written to an output directory. HTTP caching is used to only update the feed
when the source page changes.
## Supported Platforms
`rsspls` should work on all [platforms supported by the Rust compiler][platforms]
including Linux, macOS, Windows, and BSD. Pre-compiled binaries are available
for common platforms. See [the install page](@/install.md) for details.
## Usage
```
rsspls [OPTIONS] -o OUTPUT_DIR
OPTIONS:
-h, --help
Prints this help information
-c, --config
Specify the path to the configuration file.
$XDG_CONFIG_HOME/rsspls/feeds.toml is used if not supplied.
-o, --output
Directory to write generated feeds to.
-V, --version
Prints version information
FILES:
~/$XDG_CONFIG_HOME/rsspls/feeds.toml rsspls configuration file.
~/$XDG_CONFIG_HOME/rsspls Configuration directory.
~/XDG_CACHE_HOME/rsspls Cache directory.
Note: XDG_CONFIG_HOME defaults to ~/.config, XDG_CACHE_HOME
defaults to ~/.cache.
```
## Configuration
Unless specified via the `--config` command line option `rsspls` reads its Unless specified via the `--config` command line option `rsspls` reads its
configuration from one of the following paths: configuration from one of the following paths:
@ -20,7 +62,7 @@ The configuration file is in [TOML][toml] format.
The parts of the page to extract for the feed are specified using [CSS The parts of the page to extract for the feed are specified using [CSS
selectors][selectors]. selectors][selectors].
#### Annotated Sample Configuration ### Annotated Sample Configuration
The sample file below demonstrates all the parts of the configuration. The sample file below demonstrates all the parts of the configuration.
@ -135,49 +177,172 @@ The first example above (for my blog WezM.net) matches HTML that looks like this
</section> </section>
``` ```
#### More Detail on Date Handling ### output
The `date` key in the configuration can be a string or a table. If it's a Optional output directory to write the feeds to. If not specified it must be
string then it's used as selector to find the element containing the date and supplied via the `--output` command line option. Directory will be created if
`rsspls` will attempt to automatically parse the value. If automatic parsing it does not exist.
fails you can manually specify the format using the table form of `date`:
### proxy
Optional proxy address. If specified, all requests will be routed through it.
The address needs to be in the format: `protocol://ip_address:port`
The supported protocols are: http, https, socks and socks5h.
The proxy for http and https requests can also be specified with the
environment variables `http_proxy` and `HTTPS_PROXY` respectively.
The config file takes precedence over environment variables.
### feed.title
The title of the channel in the generated feed.
### feed.filename
The output filename to write this feed to. Note: this is a filename only, not a
path. It should not contain slashes. It will be written to the [output](#output)
directory.
### feed.config.url
The URL of the web page to generate the feed from. The page at this address
will be fetched processed to turn it into a feed.
### feed.config.item
A CSS selector to select elements on the page that represent items in the feed.
The other CSS selectors match elements inside the elements that this selector
matches.
### feed.config.heading
A CSS selector relative to `item` to an element that will supply the title for
the item in the feed.
### feed.config.link
CSS selector relative to `item` to an element that will supply the
link for the item in the feed.
**Note:** This element must have a `href` attribute.
**Note:** If not supplied `rsspls` will attempt to use the
`feed.config.heading` selector as the `link` element for backwards compatibility
with earlier versions. A warning message will be emitted in this case. It is
recommended to specify the `link` selector explicitly.
### feed.config.summary
Optional CSS selector relative to `item` that will supply the content of the RSS item.
### feed.config.date
The optional `date` key in the configuration can be a string or a table. If it's a
string then it's used as CSS selector relative to `item` to find the element
containing the date and `rsspls` will attempt to automatically parse the value.
If automatic parsing fails you can manually specify the format using the table
form of `date`, which looks like this:
```toml ```toml
[feed.config.date] [feed.config.date]
selector = "time" # required selector = "time" # required
type = "Date" type = "Date"
format = "[day padding:none]/[month padding:none]/[year]" format = "[day padding:none]/[month padding:none]/[year]" # will parse 1/2/1934 style dates
``` ```
* `type` is `Date` when you want to parse just a date. Use `DateTime` if you're
parsing a date and time with the format. Defaults to `DateTime`.
* `format` is a format description using the syntax described on this page:
<https://time-rs.github.io/book/api/format-description.html>.
If the element matched by the `date` selector is a `<time>` element then If the element matched by the `date` selector is a `<time>` element then
`rsspls` will first try to parse the value in the `datetime` attribute if `rsspls` will first try to parse the value in the `datetime` attribute if
present. If the attribute is missing or the element is not a `time` element present. If the attribute is missing or the element is not a `time` element
then `rsspls` will use the supplied format or attempt automatic parsing of the then `rsspls` will use the supplied format or attempt automatic parsing of the
text content of the element. text content of the element.
### Hosting #### feed.config.date.selector
It is expected that `rsspls` will be run on a web server that is serving the CSS selector relative to `item` that supples the publication date of
directory the feeds are written to. `rsspls` just generates the feeds, it's not the RSS item.
a server. In order to have the feeds update you will need to arrange for
#### feed.config.date.type
Optional type of value being parsed. Either `Date` or `DateTime`.
`type` is `Date` when you want to parse just a date. Use `DateTime` if you're
parsing a date and time with the format. Defaults to `DateTime`.
#### feed.config.date.format
Format description using the syntax described on this page:
<https://time-rs.github.io/book/api/format-description.html>
of how to parse the date.
### feed.config.media
Optional CSS selector relative to `item` that supplies media content (audio,
video, image) to be added as an RSS enclosure.
**Note:** The media URL must be given by the `src` or `href` attribute of the
selected element.
**Note:** Currently if the item does not match the media selector then it will
be skipped.
## Hosting, Updating, and Subscribing
In order to have the feeds update you will need to arrange for
`rsspls` to be run periodically. You might do this with [cron], [systemd `rsspls` to be run periodically. You might do this with [cron], [systemd
timers][timers], or the Windows equivalent. timers][timers], or the Windows equivalent.
### Caveats To subscribe to feeds you can run `rsspls` locally and use a feed reader that
supports local file feeds. Or, more likely it is expected that `rsspls` will be
run on a web server that is serving the directory the feeds are written to.
## Logging
`rsspls` logs messages to `stderr`. Logging can be controlled by the
`RSSPLS_LOG` environment variable. Log level and target module can controlled
according to the [env_logger documentation][env_logger]. For example, to enable
debug logging for `rsspls` you would use:
`RSSPLS_LOG=rsspls=debug`
The supported log levels are:
* `error`
* `warn`
* `info`
* `debug`
* `trace`
* `off` (disable logging)
The default log level is `info`.
## Caveats & Error Handling
`rsspls` just fetches and parses the HTML of the web page you specify. It does `rsspls` just fetches and parses the HTML of the web page you specify. It does
not run JavaScript. If the website is entirely generated by JavaScript (such as not run JavaScript. If the website is entirely generated by JavaScript (such as
Twitter) then `rsspls` will not work. Twitter) then `rsspls` will not work.
### Caching If errors are encountered processing the page due to invalid selectors, or
missing elements an error message will be logged. If the error is non-recoverable
`rsspls` will exit with a non-zero exit status.
If an error is encountered processing an item for the feed a warning will by
logged and processing will continue with the next item. `rsspls` will still
exit with success (0) in this case.
## Caching
When websites respond with cache headers `rsspls` will make a conditional When websites respond with cache headers `rsspls` will make a conditional
request on subsequent runs and will not regenerate the feed if the server request on subsequent runs and will not regenerate the feed if the server
responds with 304 Not Modified. Cache data is stored in responds with 304 Not Modified. Cache data is stored in
`$XDG_CACHE_HOME/rsspls`, which defaults to `~/.cache/rsspls` on UNIX-like `$XDG_CACHE_HOME/rsspls`, which defaults to `~/.cache/rsspls` on UNIX-like
systems or `C:\Users\You\AppData\Local\rsspls` on Windows. systems or `C:\Users\You\AppData\Local\rsspls` on Windows.
[cron]: https://en.wikipedia.org/wiki/Cron
[env_logger]: https://docs.rs/env_logger/latest/env_logger/#enabling-logging
[platforms]: https://doc.rust-lang.org/stable/rustc/platform-support.html
[selectors]: https://developer.mozilla.org/en-US/docs/Learn/CSS/Building_blocks/Selectors
[timers]: https://wiki.archlinux.org/title/Systemd/Timers
[toml]: https://toml.io/

View file

@ -7,10 +7,21 @@ weight = 1
`rsspls` can be installed via one of the following methods: `rsspls` can be installed via one of the following methods:
* [Package Manager](#package-manager) * [Package Manager](#package-manager)
* [Pre-compiled Binary](#pre-compiled-binary) * [Download Pre-compiled Binary](#download)
* [Build From Source](#build-from-source) * [Build From Source](#build-from-source)
### Package Manager Download
--------
Pre-compiled binaries are available for a number of platforms.
They require no additional dependencies on your computer.
{{ downloads() }}
This will result in the `rsspls` binary in the current directory.
Package Manager
---------------
`rsspls` is packaged in these package managers: `rsspls` is packaged in these package managers:
@ -18,21 +29,6 @@ weight = 1
* Homebrew: `brew install wezm/taps/rsspls` * Homebrew: `brew install wezm/taps/rsspls`
* MacPorts: [rsspls](https://ports.macports.org/port/rsspls/summary/) * MacPorts: [rsspls](https://ports.macports.org/port/rsspls/summary/)
### Pre-compiled Binary
Pre-compiled binaries are available for a number of platforms.
They require no additional dependencies on your computer.
* [FreeBSD 13 amd64](https://releases.wezm.net/rsspls/0.8.1/rsspls-0.8.1-amd64-unknown-freebsd.tar.gz)
* [Linux x86\_64](https://releases.wezm.net/rsspls/0.8.1/rsspls-0.8.1-x86_64-unknown-linux-musl.tar.gz)
* [MacOS Universal](https://releases.wezm.net/rsspls/0.8.1/rsspls-0.8.1-universal-apple-darwin.tar.gz)
* [Windows x86\_64](https://releases.wezm.net/rsspls/0.8.1/rsspls-0.8.1-x86_64-pc-windows-msvc.zip)
Example to download and extract a binary:
curl https://releases.wezm.net/rsspls/0.7.1/rsspls-0.7.1-x86_64-unknown-linux-musl.tar.gz | tar zxf -
This will result in the `rsspls` binary in the current directory.
Build From Source Build From Source
----------------- -----------------
@ -50,3 +46,5 @@ Build the binary with `cargo build --release --locked`. The binary will be in
### From crates.io ### From crates.io
`cargo install rsspls` `cargo install rsspls`
[rustup]: https://www.rust-lang.org/tools/install

View file

@ -6,4 +6,4 @@ paginate_by = 10
weight = 3 weight = 3
+++ +++
News [RSS feed](/index.xml)

View file

@ -1,21 +0,0 @@
+++
title = "Version 0.8.1 and Website"
date = 2024-03-08T21:30:39+10:00
#[extra]
#updated = 2024-02-20T22:57:15+10:00
+++
RSS Please now has it's own website.
Of course it has an RSS feed: <https://rsspls.7bit.org/index.xml>
## Version 0.8.1
Many thanks to @Lcchy for all the new features in this release:
* Add per feed user-agent option to config file https://github.com/wezm/rsspls/pull/27
* Add a media selector to include as RSS enclosure https://github.com/wezm/rsspls/pull/29
* Add option to proxy requests https://github.com/wezm/rsspls/pull/32
* Recover from item parsing error and continue https://github.com/wezm/rsspls/pull/35
**Full Changelog**: https://github.com/wezm/rsspls/compare/0.7.1...0.8.1

View file

@ -0,0 +1,42 @@
+++
title = "Version 0.8.1 and Website"
date = 2024-03-08T21:30:39+10:00
#[extra]
#updated = 2024-02-20T22:57:15+10:00
+++
The [0.8.1 release has been published][release] and RSS Please now has its own website.
<!-- more -->
## Version 0.8.1
Many thanks to [Lcchy on GitHub][Lcchy] for these new features:
* Add per feed user-agent option to config file [#27](https://github.com/wezm/rsspls/pull/27)
* Add a media selector to include as RSS enclosure [#29](https://github.com/wezm/rsspls/pull/29)
* Add option to proxy requests [#32](https://github.com/wezm/rsspls/pull/32)
* Recover from item parsing error and continue [#35](https://github.com/wezm/rsspls/pull/35)
[Full Changelog](https://github.com/wezm/rsspls/compare/0.7.1...0.8.1)
If you find `rsspls` useful you can [sponsor me on GitHub][sponsor].
## Website
RSS Please now has it's own website. Of course it has an RSS feed:
<https://rsspls.7bit.org/index.xml>. The website is built with [Zola] and uses
a modified version of the [Juice theme][Juice]. I've moved a lot of the content
that was in the README to the website. This also allowed me to expand on things
like the configuration file.
The source of [the website is also open-source][source]. If you'd like to
update the content or fix an issue contributions are welcome.
[Juice]: https://github.com/huhu/juice
[Lcchy]: https://github.com/Lcchy
[Zola]: https://www.getzola.org/
[release]: https://github.com/wezm/rsspls/releases/tag/0.8.1
[source]: https://forge.wezm.net/wezm/rsspls.7bit.org
[sponsor]: https://github.com/sponsors/wezm

BIN
content/screenshot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

BIN
static/fonts/Firava.woff2 Normal file

Binary file not shown.

Binary file not shown.

92
static/home.css Normal file
View file

@ -0,0 +1,92 @@
@font-face {
font-family: "Firava";
src: url(/fonts/Firava.woff2) format("woff2");
font-display: swap;
font-weight: 100 900;
font-style: normal;
}
@font-face {
font-family: "Firava";
src: url(/fonts/FiravaItalic.woff2) format("woff2");
font-display: swap;
font-weight: 100 900;
font-style: italic;
}
a.link-button {
box-sizing: border-box;
display: inline-block;
letter-spacing: 1px;
text-transform: uppercase;
font-size: 13px;
border-radius: 5px;
padding: 2px 2em 0;
margin: 0.5em 2em;
height: 32px;
line-height: 30px;
text-decoration: none;
font-weight: 550;
color: white;
background: cornflowerblue;
}
a.link-button:hover {
background: hsl(218.5, 79.2%, 50%);
text-decoration: none;
}
a.install-button {
font-size: 18px;
padding: 0.5em 1.5em;
height: auto;
border-radius: 7px;
font-weight: 500;
}
h1 {
font-size: 32px;
font-weight: 600;
border: none;
margin: 0;
padding: 0;
}
h3 {
font-size: 18px;
}
h4 {
font-size: 16px;
}
time {
font-size: smaller;
}
article h2 {
margin-bottom: 0;
}
p {
margin: 0.5em 0;
}
.logo {
font-family: var(--header-font-family), sans-serif;
font-weight: 900;
font-style: italic;
}
.nav-item {
font-weight: 600;
}
.content code {
padding: 0;
}
.hero section {
padding: 0 5rem;
}
@media screen and (max-width: 950px) {
.hero {
flex-direction: column;
}
.hero section {
padding: 0 2rem;
}
}
@media screen and (max-width: 450px) {
.hero-image {
width: 222px;
}
}

38
static/home.js Normal file
View file

@ -0,0 +1,38 @@
const installButton = document.querySelector(".install-button");
const version = installButton ? installButton.dataset.version : null;
if (installButton && version) {
const baseUrl = "https://releases.wezm.net/rsspls/"+version+"/";
const agent = window.navigator.userAgent;
let file = null;
let os = null;
let arch = null;
if (agent.indexOf("Windows") >= 0) {
file = "rsspls-"+version+"-x86_64-pc-windows-msvc.zip";
os = "Windows";
arch = "x86_64";
}
else if (agent.indexOf("Mac OS X") >= 0 || agent.indexOf("macOS") >= 0) {
file = "rsspls-"+version+"-universal-apple-darwin.tar.gz";
os = "macOS";
arch = "universal";
}
else if (agent.indexOf("FreeBSD") >= 0 && x64(agent)) {
file = "rsspls-"+version+"-amd64-unknown-freebsd.tar.gz";
os = "FreeBSD";
arch = "amd64";
}
else if (agent.indexOf("Linux") >= 0 && x64(agent)) {
file = "rsspls-"+version+"-x86_64-unknown-linux-musl.tar.gz";
os = "Linux";
arch = "x86_64";
}
if (file !== null && os != null && arch != null) {
installButton.href = baseUrl + file;
installButton.innerText = "Download for "+os;
installButton.title = "rsspls "+version+" for "+os+" "+arch;
}
}
function x64(agent) {
return (agent.indexOf("x86_64") >= 0 || agent.indexOf("amd64") >= 0);
}

26
static/syntax.css Normal file
View file

@ -0,0 +1,26 @@
pre {
padding: 1rem;
overflow: auto;
}
// The line numbers already provide some kind of left/right padding
pre[data-linenos] {
padding: 1rem 0;
}
pre table td {
padding: 0;
}
// The line number cells
pre table td:nth-of-type(1) {
text-align: center;
user-select: none;
}
pre mark {
// If you want your highlights to take the full width.
display: block;
// The default background colour of a mark is bright yellow
background-color: rgba(254, 252, 232, 0.9);
}
pre table {
width: 100%;
border-collapse: collapse;
}

24
templates/_variables.html Normal file
View file

@ -0,0 +1,24 @@
<style>
:root {
/* Primary theme color */
--primary-color: #DDFFFC;
/* Primary theme text color */
--primary-text-color: #4f4442;
--primary-text-color-over: #000;
/* Primary theme link color */
--primary-link-color: #d46e13;;
/* Secondary color: the background body color */
--secondary-color: #fcfaf6;
--secondary-text-color: #303030;
/* Highlight text color of table of content */
--toc-highlight-text-color: #d46e13;
--toc-background-color: white;
--code-color: initial;
--code-background-color: initial;
--shadow-color: #ddd;
/* Font used for headers (h1 & h2) */
--header-font-family: Firava, "Fira Sans", sans-serif;
/* Font used for text */
--text-font-family: Firava, "Fira Sans", sans-serif;
}
</style>

View file

@ -1,51 +1,56 @@
{% extends "juice/templates/index.html" %} {% extends "juice/templates/index.html" %}
{% block hero %} {% block title %}{{ section.title }} - {{ section.description }} {% endblock title %}
{# <script async defer src="https://buttons.github.io/buttons.js"></script> #}
<section class="text-center">
<h1 class="heading-text" style="font-size: 50px">
Generate RSS feeds from web pages
</h1>
<h3 class="title-text">
<b>Juice</b> is an intuitive, elegant, and lightweight Zola theme for product websites.
</h3>
{# <div> #}
{# <a class="github-button" href="https://github.com/huhu/juice" data-size="large" data-show-count="true" #}
{# aria-label="Star huhu/juice on GitHub">Star</a> #}
{# <a class="github-button" href="https://github.com/huhu/juice/fork" data-size="large" #}
{# data-show-count="true" aria-label="Fork huhu/juice on GitHub">Fork</a> #}
{# </div> #}
</section>
<img class="hero-image" style="width: 50%" src="{{ get_url(path="juice.svg") }}">
<div class="explore-more text" {% block hero %}
<section class="text-center">
<h1 class="heading-text" style="font-size: 50px">{{ section.description }}</h1>
<h3 class="title-text">
RSS Please is a command line tool that runs on Linux, macOS, Windows, BSD, and more.
</h3>
<div class="text">
{% set releases = load_data(url="https://github.com/wezm/rsspls/releases.atom", format="xml") %}
{% set latest_release = releases.feed.entry | first %}
{% set latest_version = latest_release.link['@href'] | split(pat="/") | last %}
<a href="/install/" class="link-button install-button" style="margin-top: 2em" data-version="{{ latest_version }}">Install</a>
</div>
</section>
<div class="text-center">
<img class="hero-image" style="image-rendering: pixelated;" src="{{ get_url(path="screenshot.png") }}" alt="Screenshot of two invocations of rsspls in a terminal. The first fetches and generates the feeds, the second does not change anything as the source pages are unmodifed." title="Screenshot of rsspls running on a Linux system over an SSH connection in ssheven on Mac OS 8.">
</div>
<div class="explore-more text text-center"
onclick="document.getElementById('features').scrollIntoView({behavior: 'smooth'})"> onclick="document.getElementById('features').scrollIntoView({behavior: 'smooth'})">
Explore More ⇩ Explore More ⇩
</div> </div>
<style>
.hero section {
padding: 0 5rem;
}
@media screen and (max-width: 768px) {
.hero section {
padding: 0 2rem;
}
.hero-image {
display: none
}
}
</style>
{% endblock hero %} {% endblock hero %}
{% block head %} {% block head %}
<link rel="stylesheet" href="{{ get_url(path="home.css") }}">
<link rel="stylesheet" href="{{ get_url(path="syntax.css") }}">
<link rel="alternate" type="application/rss+xml" title="RSS" href="{{ get_url(path="index.xml", trailing_slash=false) }}"> <link rel="alternate" type="application/rss+xml" title="RSS" href="{{ get_url(path="index.xml", trailing_slash=false) }}">
{% endblock %} {% endblock %}
{% block fonts %}
{% endblock %}
{% block favicon %}
<link rel="icon" href="{{ get_url(path="feed-icon.svg") }}">
{% endblock %}
{% block content %}
<div id="features" class="heading-text">Overview</div>
{{ section.content | safe }}
{% endblock content %}
{% block footer %} {% block footer %}
<footer> <footer>
<small class="subtext"> <small class="subtext">
© 2024 <a href="https://www.wezm.net/">Wesley Moore</a> Copyright © {#2024 &ndash;#} {{ now() | date(format="%Y") }}
<a href="{{ config.extra.homepage }}">{{ config.extra.author }}</a>
&mdash; <a href="https://forge.wezm.net/wezm/rsspls.7bit.org">Website Source</a>
&mdash; <a href="https://github.com/sponsors/wezm">Sponsor on GitHub</a>
</small> </small>
</footer> </footer>
<script src="{{ get_url(path="home.js") }}" type="text/javascript"></script>
{% endblock %} {% endblock %}

15
templates/page.html Normal file
View file

@ -0,0 +1,15 @@
{% extends "juice/templates/page.html" %}
{% block title %}{{ page.title }} - {{ config.title }} {% endblock title %}
{% block content %}
{% if page.description %}
<h1 class="heading-text">{{ page.description }}</h1>
{% else %}
<h1 class="heading-text">{{ page.title }}</h1>
{% endif %}
{% if page.date %}
<time datetime="{{ page.date }}">{{ page.date | date(format="%d %B %Y") }}</time>
{% endif %}
{{ page.content | safe }}
{% endblock content %}

View file

@ -1,7 +1,7 @@
{% import "_macros.html" as macros %} {% import "_macros.html" as macros %}
{% extends "index.html" %} {% extends "index.html" %}
{% block title %}{{ section.title }} | {{ super() }} {% endblock title %} {% block title %}{{ section.title }} - {{ config.title }} {% endblock title %}
{% block header %} {% block header %}
<header class="box-shadow"> <header class="box-shadow">
@ -10,7 +10,27 @@
{% endblock header %} {% endblock header %}
{% block content %} {% block content %}
<div class="heading-text">{{ section.description }}</div> <h1 class="heading-text">{{ section.description }}</h1>
{{ section.content | safe }} {{ section.content | safe }}
{% for page in paginator.pages %}
<article>
<h2><a href="{{ page.permalink }}">{{ page.title }}</a></h2>
<time datetime="{{ page.date }}">{{ page.date | date(format="%d %B %Y") }}</time>
<div>
{{ page.summary | safe }}
</div>
</article>
{% endfor %}
<nav class="pagination">
{% if paginator.previous %}
<a class="previous" href="{{ paginator.previous }}"> Previous</a>
{% endif %}
{% if paginator.next %}
<a class="next" href="{{ paginator.next }}">Next </a>
{% endif %}
</nav>
{% endblock content %} {% endblock content %}

View file

@ -0,0 +1,17 @@
{% set releases = load_data(url="https://github.com/wezm/rsspls/releases.atom", format="xml") %}
{% set latest_release = releases.feed.entry | first %}
{% set_global latest_version = latest_release.link['@href'] | split(pat="/") | last %}
<ul>
<li><a href="https://releases.wezm.net/rsspls/{{ latest_version }}/rsspls-{{ latest_version }}-amd64-unknown-freebsd.tar.gz">FreeBSD 13+ amd64</a></li>
<li><a href="https://releases.wezm.net/rsspls/{{ latest_version }}/rsspls-{{ latest_version }}-x86_64-unknown-linux-musl.tar.gz">Linux x86_64</a>
<ul>
<li>Runs on glibc and Musl based distributions including Alpine, Arch, Chimera, Debian, Fedora, and Ubuntu.</li>
</ul>
</li>
<li><a href="https://releases.wezm.net/rsspls/{{ latest_version }}/rsspls-{{ latest_version }}-universal-apple-darwin.tar.gz">MacOS Universal</a></li>
<li><a href="https://releases.wezm.net/rsspls/{{ latest_version }}/rsspls-{{ latest_version }}-x86_64-pc-windows-msvc.zip">Windows x86_64</a></li>
</ul>
<p>Example to download and extract a binary:</p>
<pre>curl https://releases.wezm.net/rsspls/{{ latest_version }}/rsspls-{{ latest_version }}-x86_64-unknown-linux-musl.tar.gz | tar zxf -</pre>