aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIsaac Yu <isaacyu@protonmail.com>2024-02-02 08:13:49 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2024-02-02 10:11:53 +0700
commitf2f939b6745c5aa95e9c6d2da662ca420ac6dbf5 (patch)
tree4a0c870961fd7e1ab1a10b53190b22b14ec596f7
parent619db0381d7ea27f60ad080354b15b3725c7807d (diff)
network/tut: Added (mastodon CLI).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
-rw-r--r--network/tut/README7
-rw-r--r--network/tut/modules.txt90
-rw-r--r--network/tut/slack-desc19
-rw-r--r--network/tut/tut.SlackBuild127
-rw-r--r--network/tut/tut.info68
5 files changed, 311 insertions, 0 deletions
diff --git a/network/tut/README b/network/tut/README
new file mode 100644
index 000000000000..25651bcfc1f6
--- /dev/null
+++ b/network/tut/README
@@ -0,0 +1,7 @@
+Tut is a TUI for Mastodon with vim inspired keys. The program contains
+most of the features from the web client.
+
+Within tut, press "C" (no quotations) to create a new toot and "N" to
+focus on notifications.
+
+Tut also provides mouse support (see the github page for more details).
diff --git a/network/tut/modules.txt b/network/tut/modules.txt
new file mode 100644
index 000000000000..e4f82b433bed
--- /dev/null
+++ b/network/tut/modules.txt
@@ -0,0 +1,90 @@
+# github.com/RasmusLindroth/go-mastodon v0.0.21
+## explicit
+github.com/RasmusLindroth/go-mastodon
+# github.com/adrg/xdg v0.4.0
+## explicit
+github.com/adrg/xdg
+# github.com/atotto/clipboard v0.1.4
+## explicit
+github.com/atotto/clipboard
+# github.com/gdamore/tcell/v2 v2.5.4
+## explicit
+github.com/gdamore/tcell/v2
+# github.com/gen2brain/beeep v0.0.0-20220909211152-5a9ec94374f6
+## explicit
+github.com/gen2brain/beeep
+# github.com/gobwas/glob v0.2.3
+## explicit
+github.com/gobwas/glob
+# github.com/icza/gox v0.0.0-20230117093757-93f961aa2755
+## explicit
+github.com/icza/gox/timex
+# github.com/microcosm-cc/bluemonday v1.0.21
+## explicit
+github.com/microcosm-cc/bluemonday
+# github.com/pelletier/go-toml/v2 v2.0.6
+## explicit
+github.com/pelletier/go-toml/v2
+# github.com/rivo/tview v0.0.0-20230104153304-892d1a2eb0da
+## explicit
+github.com/rivo/tview
+# github.com/rivo/uniseg v0.4.3
+## explicit; go 1.18
+github.com/rivo/uniseg
+# github.com/spf13/pflag v1.0.5
+## explicit
+github.com/spf13/pflag
+# golang.org/x/exp v0.0.0-20230125214544-b3c2aaf6208d
+## explicit; go 1.18
+golang.org/x/exp/slices
+# golang.org/x/net v0.5.0
+## explicit
+golang.org/x/net/html
+# mvdan.cc/xurls/v2 v2.4.0
+## explicit
+mvdan.cc/xurls/v2
+# github.com/aymerick/douceur v0.2.0
+## explicit
+github.com/aymerick/douceur/parser
+# github.com/gdamore/encoding v1.0.0
+## explicit
+github.com/gdamore/encoding
+# github.com/go-toast/toast v0.0.0-20190211030409-01e6764cf0a4
+## explicit
+github.com/go-toast/toast
+# github.com/godbus/dbus/v5 v5.1.0
+## explicit
+github.com/godbus/dbus/v5
+# github.com/gorilla/css v1.0.0
+## explicit
+github.com/gorilla/css/scanner
+# github.com/gorilla/websocket v1.5.0
+## explicit
+github.com/gorilla/websocket
+# github.com/lucasb-eyer/go-colorful v1.2.0
+## explicit
+github.com/lucasb-eyer/go-colorful
+# github.com/mattn/go-runewidth v0.0.14
+## explicit
+github.com/mattn/go-runewidth
+# github.com/nu7hatch/gouuid v0.0.0-20131221200532-179d4d0c4d8d
+## explicit
+github.com/nu7hatch/gouuid
+# github.com/tadvi/systray v0.0.0-20190226123456-11a2b8fa57af
+## explicit
+github.com/tadvi/systray
+# github.com/tomnomnom/linkheader v0.0.0-20180905144013-02ca5825eb80
+## explicit
+github.com/tomnomnom/linkheader
+# golang.org/x/sys v0.4.0
+## explicit; go 1.17
+golang.org/x/sys/unix
+golang.org/x/sys/windows/
+golang.org/x/sys/windows/registry
+# golang.org/x/term v0.4.0
+## explicit
+golang.org/x/term
+# golang.org/x/text v0.6.0
+## explicit
+golang.org/x/text/encoding
+golang.org/x/text/transform
diff --git a/network/tut/slack-desc b/network/tut/slack-desc
new file mode 100644
index 000000000000..33288d18f2a4
--- /dev/null
+++ b/network/tut/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description.
+# Line up the first '|' above the ':' following the base package name, and
+# the '|' on the right side marks the last column you can put a character in.
+# You must make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':' except on otherwise blank lines.
+
+ |-----handy-ruler------------------------------------------------------|
+tut: tut (a Mastodon TUI)
+tut:
+tut: tut is a TUI for Mastodon with vim inspired keys.
+tut:
+tut:
+tut:
+tut:
+tut:
+tut:
+tut:
+tut:
diff --git a/network/tut/tut.SlackBuild b/network/tut/tut.SlackBuild
new file mode 100644
index 000000000000..1f285068cc32
--- /dev/null
+++ b/network/tut/tut.SlackBuild
@@ -0,0 +1,127 @@
+#!/bin/bash
+
+# Slackware build script for tut
+
+# Copyright 2024 Isaac Yu <isaacyu@protonmail.com>
+# All rights reserved.
+#
+# Redistribution and use of this script, with or without modification, is
+# permitted provided that the following conditions are met:
+#
+# 1. Redistributions of this script must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED
+# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+cd $(dirname $0) ; CWD=$(pwd)
+
+PRGNAM=tut
+VERSION=${VERSION:-2.0.1}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i586 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "i686" ]; then
+ SLKCFLAGS="-O2 -march=i686 -mtune=i686"
+ LIBDIRSUFFIX=""
+elif [ "$ARCH" = "x86_64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
+else
+ SLKCFLAGS="-O2"
+ LIBDIRSUFFIX=""
+fi
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+rm -rf $PRGNAM-$VERSION
+tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
+cd $PRGNAM-$VERSION
+chown -R root:root .
+
+mkdir -p vendor
+cat $CWD/modules.txt > vendor/modules.txt
+for DIR in $(grep -o "^# .* " vendor/modules.txt | cut -d' ' -f2)
+do
+ NAME=$(echo $DIR | sed 's/[./]v[0-9]\+$//' | xargs basename)
+ DIR=vendor/$DIR
+ tar xvf $CWD/$NAME-*.tar.gz
+ mkdir -p $(dirname $DIR)
+ mv $NAME-* $DIR
+done
+
+find -L . \
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+
+CGO_CFLAGS="$SLKCFLAGS" \
+CGO_CXXFLAGS="$SLKCFLAGS" \
+go build -mod vendor
+
+# Install tut
+install -Dm755 $PRGNAM $PKG/usr/bin/$PRGNAM
+
+# Install config files
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp config.example.toml $PKG/usr/doc/$PRGNAM-$VERSION/config.example.toml
+cp config/toot.tmpl $PKG/usr/doc/$PRGNAM-$VERSION/toot.tmpl
+cp config/user.tmpl $PKG/usr/doc/$PRGNAM-$VERSION/user.tmpl
+
+# Install themes
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION/themes
+cp config/themes/* $PKG/usr/doc/$PRGNAM-$VERSION/themes
+
+# Install and compress man pages
+for i in {1,5,7};
+do
+ mkdir -p $PKG/usr/man/man$i
+ cp -r docs/man/tut.$i $PKG/usr/man/man$i/tut.$i
+done
+gzip -9 $PKG/usr/man/man[0-9]/$PRGNAM.[0-9]
+
+find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
+ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a LICENSE README.md $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE
diff --git a/network/tut/tut.info b/network/tut/tut.info
new file mode 100644
index 000000000000..a44535b3585e
--- /dev/null
+++ b/network/tut/tut.info
@@ -0,0 +1,68 @@
+PRGNAM="tut"
+VERSION="2.0.1"
+HOMEPAGE="https://github.com/RasmusLindroth/tut"
+DOWNLOAD="https://github.com/RasmusLindroth/tut/archive/refs/tags/2.0.1/tut-2.0.1.tar.gz \
+ https://github.com/RasmusLindroth/go-mastodon/archive/v0.0.21/go-mastodon-0.0.21.tar.gz \
+ https://github.com/adrg/xdg/archive/v0.4.0/xdg-0.4.0.tar.gz \
+ https://github.com/atotto/clipboard/archive/v0.1.4/clipboard-0.1.4.tar.gz \
+ https://github.com/gdamore/tcell/archive/v2.5.4/tcell-2.5.4.tar.gz \
+ https://github.com/gen2brain/beeep/archive/5a9ec94/beeep-5a9ec94374f60b2b12acc4b615be802c8563a157.tar.gz \
+ https://github.com/gobwas/glob/archive/v0.2.3/glob-0.2.3.tar.gz \
+ https://github.com/icza/gox/archive/93f961a/gox-93f961aa27557b111564e0889e52eb9dd94b81a9.tar.gz \
+ https://github.com/microcosm-cc/bluemonday/archive/v1.0.21/bluemonday-1.0.21.tar.gz \
+ https://github.com/pelletier/go-toml/archive/v2.0.6/go-toml-2.0.6.tar.gz \
+ https://github.com/rivo/tview/archive/892d1a2/tview-892d1a2eb0daab1296492b2087fff46240799382.tar.gz \
+ https://github.com/rivo/uniseg/archive/v0.4.3/uniseg-0.4.3.tar.gz \
+ https://github.com/spf13/pflag/archive/v1.0.5/pflag-1.0.5.tar.gz \
+ https://github.com/golang/exp/archive/b3c2aaf/exp-b3c2aaf6208dd245d356334775d544edb2fa3040.tar.gz \
+ https://github.com/golang/net/archive/v0.5.0/net-0.5.0.tar.gz \
+ https://github.com/mvdan/xurls/archive/v2.4.0/xurls-2.4.0.tar.gz \
+ https://github.com/aymerick/douceur/archive/v0.2.0/douceur-0.2.0.tar.gz \
+ https://github.com/gdamore/encoding/archive/v1.0.0/encoding-1.0.0.tar.gz \
+ https://github.com/go-toast/toast/archive/01e6764/toast-01e6764cf0a44209189b7981cdc34284936f6891.tar.gz \
+ https://github.com/godbus/dbus/archive/v5.1.0/dbus-5.1.0.tar.gz \
+ https://github.com/gorilla/css/archive/v1.0.0/css-1.0.0.tar.gz \
+ https://github.com/gorilla/websocket/archive/v1.5.0/websocket-1.5.0.tar.gz \
+ https://github.com/lucasb-eyer/go-colorful/archive/v1.2.0/go-colorful-1.2.0.tar.gz \
+ https://github.com/mattn/go-runewidth/archive/v0.0.14/go-runewidth-0.0.14.tar.gz \
+ https://github.com/nu7hatch/gouuid/archive/179d4d0/gouuid-179d4d0c4d8d407a32af483c2354df1d2c91e6c3.tar.gz \
+ https://github.com/tadvi/systray/archive/11a2b8f/systray-11a2b8fa57afff744b2e66a9b05f173c78f20dc6.tar.gz \
+ https://github.com/tomnomnom/linkheader/archive/02ca582/linkheader-02ca5825eb8097f10d9cc53da78481a85ad84e04.tar.gz \
+ https://github.com/golang/sys/archive/v0.4.0/sys-0.4.0.tar.gz \
+ https://github.com/golang/term/archive/v0.4.0/term-0.4.0.tar.gz \
+ https://github.com/golang/text/archive/v0.6.0/text-0.6.0.tar.gz"
+MD5SUM="7192cf56bfeb294fad290eb98e0a1e64 \
+ 910805b0bcbc402c021ab9e90dfe3dbe \
+ 8bc50248d26e66e5e29e65f3f051342a \
+ 9020b8bb980f0b59e12f7c4e0dc53a88 \
+ 0c62c60df9d5def197b42b03455ae530 \
+ 0e254919fc79e73a4ff09c45689e1ab8 \
+ 5d6cceb33b2e69ec12b5fb8c1f57cafe \
+ 938a1fbb88141d94d356a447025dd242 \
+ bc87b962386014b2ebffefcf19958f58 \
+ 2a91e4190a1d0bb7348c83e29e26e03e \
+ 4e785a105923de0b560cefe68794e28c \
+ 5fb9fa6f45d1bd701f0eca1e699d3c1d \
+ b31b2da1e91e337f3afdd49c8851b1a0 \
+ 5567341126e060622851745978b5397c \
+ cea041eef3f83f69cef05835fe23c4e2 \
+ 0ce250780135f41fcb4d84123c1582fe \
+ 48d2b40c0bc69a5c19b5fad8a8d1ab1b \
+ fbadc383bc1ace79fa769fe2de36b87b \
+ c8b7381250dc50b40879d08a3bfea178 \
+ d456df1207b7ba6a073d9ab1dd82ad2d \
+ adb82396cd821ca82a8d96b68552e748 \
+ 11f202db2e908f83270784cf85032b4b \
+ 191fe5cfcb58e480ff4045c82a06091a \
+ c41abbf9dc5def08ef8e6999efbe2c8c \
+ 3c71dda45c74b210d6b86cdcaebd3ed6 \
+ aa33e322338a67f3b3950bc0f77397e4 \
+ 972d6a64ac3a22ae16ac80447bccd06f \
+ 2450b5e79ce8b41cb65a6d99af8bf89f \
+ 44d06b8aa75102668295863b1f94632e \
+ 0811ecc6a90a1a52ed96a0ff843bd343"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+REQUIRES="google-go-lang"
+MAINTAINER="Isaac Yu"
+EMAIL="isaacyu@protonmail.com"