public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Anna Vyalkova" <cyber+gentoo@sysrq.in>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/proj/guru:dev commit in: net-im/mastoposter/, net-im/mastoposter/files/
Date: Wed, 10 May 2023 02:07:41 +0000 (UTC)	[thread overview]
Message-ID: <1683684453.75d79c8c37bbf4a90156030018a5e4d5dc76717c.cybertailor@gentoo> (raw)

commit:     75d79c8c37bbf4a90156030018a5e4d5dc76717c
Author:     Anna (cybertailor) Vyalkova <cyber+gentoo <AT> sysrq <DOT> in>
AuthorDate: Wed May 10 02:07:33 2023 +0000
Commit:     Anna Vyalkova <cyber+gentoo <AT> sysrq <DOT> in>
CommitDate: Wed May 10 02:07:33 2023 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=75d79c8c

net-im/mastoposter: new package, add 0.1

Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo <AT> sysrq.in>

 net-im/mastoposter/Manifest                  |  1 +
 net-im/mastoposter/files/mastoposter.confd   |  2 ++
 net-im/mastoposter/files/mastoposter.initd   | 16 ++++++++++++
 net-im/mastoposter/files/mastoposter.service | 15 +++++++++++
 net-im/mastoposter/mastoposter-0.1.ebuild    | 38 ++++++++++++++++++++++++++++
 net-im/mastoposter/metadata.xml              | 12 +++++++++
 6 files changed, 84 insertions(+)

diff --git a/net-im/mastoposter/Manifest b/net-im/mastoposter/Manifest
new file mode 100644
index 000000000..e32696a75
--- /dev/null
+++ b/net-im/mastoposter/Manifest
@@ -0,0 +1 @@
+DIST mastoposter-0.1.tar.gz 36352 BLAKE2B e0710ce461f3d2b21ea7e3aee0e698a9db90523f9ab598868b602f028951251e6ac69cca9f1dfe9b6a66432a8c0f01d32871327b4e064eed2c3b530ae3c4c153 SHA512 77d834503e25f41b4c92ef2538ee8b3a1143d4927e5f96c0ce53d3a3f5c4a004f05c3392d43d8c4af187fc91a044ccec22f9083ccffb31ba5902f254723577ec

diff --git a/net-im/mastoposter/files/mastoposter.confd b/net-im/mastoposter/files/mastoposter.confd
new file mode 100644
index 000000000..1458da339
--- /dev/null
+++ b/net-im/mastoposter/files/mastoposter.confd
@@ -0,0 +1,2 @@
+# Configuration file
+#MASTOPOSTER_CONFIG_FILE="/etc/mastoposter/config.ini"

diff --git a/net-im/mastoposter/files/mastoposter.initd b/net-im/mastoposter/files/mastoposter.initd
new file mode 100644
index 000000000..0057cddc4
--- /dev/null
+++ b/net-im/mastoposter/files/mastoposter.initd
@@ -0,0 +1,16 @@
+#!/sbin/openrc-run
+# Copyright 2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+# shellcheck shell=sh
+
+command="/usr/bin/mastoposter"
+command_args="${MASTOPOSTER_CONFIG_FILE:=/etc/mastoposter/config.ini}"
+command_background=1
+pidfile="/run/${RC_SVCNAME}.pid"
+output_log="/var/log/${RC_SVCNAME}.log"
+error_log="${output_log}"
+
+depend() {
+	need net
+}

diff --git a/net-im/mastoposter/files/mastoposter.service b/net-im/mastoposter/files/mastoposter.service
new file mode 100644
index 000000000..095626e7b
--- /dev/null
+++ b/net-im/mastoposter/files/mastoposter.service
@@ -0,0 +1,15 @@
+[Unit]
+Description=Configurable reposter from Mastodon-compatible Fediverse servers
+After=network.target
+Wants=network-online.target
+
+[Service]
+Type=simple
+ExecStart=/usr/bin/mastoposter /etc/mastoposter/config.ini
+Restart=always
+RestartSec=5
+StandardOutput=journal
+StandardError=inherit
+
+[Install]
+WantedBy=multi-user.target

diff --git a/net-im/mastoposter/mastoposter-0.1.ebuild b/net-im/mastoposter/mastoposter-0.1.ebuild
new file mode 100644
index 000000000..c490eae74
--- /dev/null
+++ b/net-im/mastoposter/mastoposter-0.1.ebuild
@@ -0,0 +1,38 @@
+# Copyright 2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..11} )
+DISTUTILS_USE_PEP517=flit
+inherit distutils-r1 pypi systemd
+
+DESCRIPTION="Configurable reposter from Mastodon-compatible Fediverse servers"
+HOMEPAGE="
+	https://pypi.org/project/mastoposter/
+	https://github.com/hatkidchan/mastoposter
+"
+
+LICENSE="GPL-3+"
+SLOT="0"
+KEYWORDS="~amd64"
+
+RDEPEND="
+	dev-python/beautifulsoup4[${PYTHON_USEDEP}]
+	dev-python/emoji[${PYTHON_USEDEP}]
+	dev-python/httpx[${PYTHON_USEDEP}]
+	dev-python/jinja[${PYTHON_USEDEP}]
+	dev-python/websockets[${PYTHON_USEDEP}]
+"
+
+src_install() {
+	distutils-r1_src_install
+
+	systemd_dounit "${FILESDIR}"/mastoposter.service
+	newinitd "${FILESDIR}"/mastoposter.initd mastoposter
+	newconfd "${FILESDIR}"/mastoposter.confd mastoposter
+
+	insinto /etc/mastoposter
+	insopts --mode 600
+	doins config.ini
+}

diff --git a/net-im/mastoposter/metadata.xml b/net-im/mastoposter/metadata.xml
new file mode 100644
index 000000000..c23e04d78
--- /dev/null
+++ b/net-im/mastoposter/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+	<maintainer type="person">
+		<email>cyber+gentoo@sysrq.in</email>
+		<name>Anna</name>
+	</maintainer>
+	<upstream>
+		<remote-id type="pypi">mastoposter</remote-id>
+		<remote-id type="github">hatkidchan/mastoposter</remote-id>
+	</upstream>
+</pkgmetadata>


             reply	other threads:[~2023-05-10  2:07 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-10  2:07 Anna Vyalkova [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-05-14  2:31 [gentoo-commits] repo/proj/guru:dev commit in: net-im/mastoposter/, net-im/mastoposter/files/ Anna Vyalkova

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1683684453.75d79c8c37bbf4a90156030018a5e4d5dc76717c.cybertailor@gentoo \
    --to=cyber+gentoo@sysrq.in \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox