~nabijaczleweli/klapki

33471409440115055ffd5bd888cf4ac265259134 — наб 1 year, 11 days ago
Initial commit
6 files changed, 260 insertions(+), 0 deletions(-)

A .build.yml
A .gitignore
A LICENSE
A README.md
A klapki.md
A klapki.sublime-project
A  => .build.yml +20 -0
@@ 1,20 @@
#image: debian/bullseye
#packages:
#  - ronn
#  - curl
#secrets:
#  - 8d4dfb87-e056-4f68-abae-0da7ba5d4398
#tasks:
#  - build: |
#      cd html-readme
#      awk '/BUILD_YML_PLACEHOLDER/ {print "_PRE"; while(getline < ".build.yml") print; print "__PRE"; next}  //' html-readme.md | \
#      ronn -f | \
#      sed -e 's;^__PRE$;</pre>;' -e 's;^_PRE$;<pre>;' > ~/README.html
#  - readme: |
#      set +x  # Avoid echoing the token
#      curl -H "Content-Type: text/html"                      \
#           -H "Authorization: Bearer $(cat ~/.readme-token)" \
#           -XPUT                                             \
#           --data-binary @README.html                        \
#           'https://git.sr.ht/api/repos/html-readme/readme' &&
#      echo "README set"

A  => .gitignore +17 -0
@@ 1,17 @@
*
!.git*
!.git*/**
!.build.yml
!.travis.yml
!gh_rsa.enc
!LICENSE
!.clang-format
!*Makefile
!*.sublime-project
!*.md
!src
!src/**
!tests
!tests/**
!test-data
!test-data/**

A  => LICENSE +21 -0
@@ 1,21 @@
The MIT License (MIT)

Copyright (c) 2020 наб <nabijaczleweli@nabijaczleweli.xyz>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

A  => README.md +46 -0
@@ 1,46 @@
# klapki [![Licence](//img.shields.io/badge/license-MIT-blue.svg?style=flat)](LICENSE)
EFI boot manager; or, well, an EFI bootorder [compiler](//twitter.com/nabijaczleweli/status/1306144037070569472).

## [Manpage](//rawcdn.githack.com/nabijaczleweli/feembox/man/feembox.1.html)
<!-- TODO: put something on man.sr.ht -->

### Installation

dunno yet

#### probably a building sexion here


#### From Debian repository

The following line in `/etc/apt/sources.list` or equivalent:
```apt
deb //debian.nabijaczleweli.xyz stable main
```

With [my PGP key](//nabijaczleweli.xyz/pgp.txt) (the two URLs are interchangeable):
```sh
wget -O- //debian.nabijaczleweli.xyz/nabijaczleweli.gpg.key | sudo apt-key add
# or
sudo wget -O/etc/apt/trusted.gpg.d/nabijaczleweli.asc //keybase.io/nabijaczleweli/pgp_keys.asc
```

Then the usual
```sh
sudo apt update
sudo apt install feembox
```
will work on x86_64 and i686.

See the [repository README](//debian.nabijaczleweli.xyz/README) for more information.

## Contributing

Send a patch inline, as an attachment, or a git link and a ref to pull to [the list](//lists.sr.ht/~nabijaczleweli/klapki). I'm not picky.

## Special thanks

To all who support further development on Patreon, in particular:

  * ThePhD
  * Embark Studios

A  => klapki.md +110 -0
@@ 1,110 @@
feembox(1) -- What if a feed, but it's a mailbox?
=================================================

## SYNOPSIS

`feembox` [-v] [-t FROM:TO:HOW]... [-f MIME] [MAILDIR] [FEED]<br />
`feembox` [-v] [-t FROM:TO:HOW]... [-f MIME] [MAILDIR] < feed.xml

## DESCRIPTION

`feembox` represents an (RSS/Atom/JSON) feed as a mailbox in the [maildir](https://cr.yp.to/proto/maildir.html) format.

## OPTIONS

  [MAILDIR]

    Deliver to the specified directory instead of the CWD

    Parents must exist, all directory and its subdirs will be created as necessary

  [FEED]

    Read the feed from the specified file instead of stdin

    If "-" use stdin, otherwise must exist and be a file

  -v --verbose

    Print what's happening to the standard output,
    if specified twice: print parse debugging information.

  -t --transfrom <FROM:TO:HOW|FROM;TO;HOW>...

    Define an alternative transformation invocation HOW
    from the mime-type FROM to the mime-type TO.

    If the post content type matches FROM, "/bin/sh -c HOW" ("cmd /C HOW" on NT)
    is executed, its standard input tied thereto, and standard output
    to the buffer for the new multipart/alternative part TO.

    The separator between FROM, TO, and HOW is the platform's path list separator
    (i.e. ";" on NT and ":" elsewhere).

    Can be specified multiple times, in which case each transformation is invoked once,
    in order, on the current set of parts.

  -f --force <MIME>

    Force the post content type to be MIME, overriding what's specified therein.

    This is done before any transformations.

    Some feeds specify they're text/plain but are HTML,
    this can be used to massage them right.

## EXIT VALUES

    1 - option parse error
    2 - feed file open failed
    3 - feed parse failed
    4 - maildir subdirectory read failed
    5 - existing mail open(2)/mmap(2) failed
    6 - creating a MAILDIR/tmp or MAILDIR/new failed
    7 - formatting mail failed
    8 - creating/writing/delivering mail failed

## EXAMPLES

  Turndown (here: https://github.com/domchristie/turndown/pull/209 lightly patched to always read from stdin),
  can be used to turn HTML feeds (i.e. most of them) into usually pretty readable plaintext:

    P:\Rust\feembox>cat test-data/util-linux-newer.atom |   target\debug\feembox -vt text/html;text/plain;turndown feedir
    ~/code/feembox$ cat test-data/util-linux-newer.atom | ./target/debug/feembox -vt 'text/html:text/plain;charset=utf-8:~/code/turndown/bin/turndown.js' feedir
    <stdin>: feed ID mailto:util-linux@vger.kernel.org, title "Util-Linux Archive on lore.kernel.org", updated 2020-05-18T11:41:20+00:00
    25 entries:
        entry ID                                       title                                                                    updated                    published
        urn:uuid:d2c69230-d7ba-e4cf-ee51-2b25d53119a1  "Re: [PATCH] util-linux: Some minor fixes in some manuals"               2020-05-18T11:40:38+00:00  N/A
        urn:uuid:d9e31d9a-5d6c-8403-9661-2d303e6fb24a  "Re: [PATCH] Fix dead references to kernel documentation"                2020-05-18T11:39:59+00:00  N/A
        urn:uuid:dccd47a2-d327-df9b-7ad1-9218d08a8349  "Re: Consistency fixes in util-linux man pages"                          2020-05-18T10:36:15+00:00  N/A
        urn:uuid:ba1cf039-280f-f33d-199d-86f5a9c1bb1b  "Re: Consistency fixes in util-linux man pages"                          2020-05-18T08:28:25+00:00  N/A
        urn:uuid:98e3d4cd-17c1-ac1d-3dd9-7bbe87f6402e  "[PATCH] Fix dead references to kernel documentation"                    2020-05-17T15:13:35+00:00  N/A
        urn:uuid:68946069-8d16-0362-57e6-feba21ebbecb  "Consistency fixes in util-linux man pages"                              2020-05-16T08:25:11+00:00  N/A
        urn:uuid:94158972-3786-e3c6-7e0a-dec2988cd32b  "[PATCH] ipcs.1: ipcs no longer needs read permission on IPC resources"  2020-05-16T08:10:32+00:00  N/A
        urn:uuid:37f8f0a9-d285-b8f9-5269-6eeb2475f9ba  "plan for v2.35.2"                                                       2020-05-15T13:05:16+00:00  N/A

    Delivering urn:uuid:ba1cf039-280f-f33d-199d-86f5a9c1bb1b to feedir/new/1591610344.M981513P12500Q1.nabuter
    Delivering urn:uuid:d2c69230-d7ba-e4cf-ee51-2b25d53119a1 to feedir/new/1591610346.M86312P12500Q2.nabuter
    Delivering urn:uuid:d9e31d9a-5d6c-8403-9661-2d303e6fb24a to feedir/new/1591610347.M339148P12500Q3.nabuter
    Delivering urn:uuid:dccd47a2-d327-df9b-7ad1-9218d08a8349 to feedir/new/1591610348.M505433P12500Q4.nabuter

## AUTHOR

Written by наб &lt;<nabijaczleweli@nabijaczleweli.xyz>&gt;

## SPECIAL THANKS

To all who support further development, in particular:

  * ThePhD
  * Embark Studios

## REPORTING BUGS

&lt;<https://github.com/nabijaczleweli/feembox/issues>&gt;

## SEE ALSO

&lt;<https://github.com/nabijaczleweli/feembox>&gt;

&lt;<https://cr.yp.to/proto/maildir.html>&gt;

A  => klapki.sublime-project +46 -0
@@ 1,46 @@
{
	"build_systems":
	[
		{
			"working_dir": "$project_path",
			"shell_cmd": "make -j10",
			"name": "Build klapki",

			"target": "ansi_color_build",
			"syntax": "Packages/ANSIescape/ANSI.sublime-syntax"
		},
		{
			"working_dir": "$project_path",
			"shell_cmd": "cargo doc --color always",
			"name": "Document klapki",

			"target": "ansi_color_build",
			"syntax": "Packages/ANSIescape/ANSI.sublime-syntax"
		}
	],
	"folders":
	[
		{
			"follow_symlinks": true,
			"name": "Source",
			"path": "src"
		},
		{
			"follow_symlinks": true,
			"name": "Tests",
			"path": "tests"
		},
		{
			"follow_symlinks": true,
			"name": "Test data",
			"path": "test-data"
		},
		{
			"follow_symlinks": true,
			"name": "Build scripts",
			"path": ".",
			"file_include_patterns": [".build.yml", "*Makefile"],
			"folder_exclude_patterns": ["*"]
		},
	]
}