git: aceb6548dd20 - main - textproc/sttr: add new port
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sun, 02 Jun 2024 14:25:12 UTC
The branch main has been updated by se: URL: https://cgit.FreeBSD.org/ports/commit/?id=aceb6548dd206012b330e47676d97bf3333a6af7 commit aceb6548dd206012b330e47676d97bf3333a6af7 Author: Stefan Eßer <se@FreeBSD.org> AuthorDate: 2024-06-02 14:23:35 +0000 Commit: Stefan Eßer <se@FreeBSD.org> CommitDate: 2024-06-02 14:23:35 +0000 textproc/sttr: add new port This port adds a command line tool that offers a huge number of text conversions. --- textproc/Makefile | 1 + textproc/sttr/Makefile | 59 +++++++++++++++++++++++++++++ textproc/sttr/distinfo | 81 ++++++++++++++++++++++++++++++++++++++++ textproc/sttr/files/patch-go.mod | 10 +++++ textproc/sttr/pkg-descr | 21 +++++++++++ 5 files changed, 172 insertions(+) diff --git a/textproc/Makefile b/textproc/Makefile index f3906a207ff4..1fb9a8f4dd33 100644 --- a/textproc/Makefile +++ b/textproc/Makefile @@ -2017,6 +2017,7 @@ SUBDIR += stardict-dictd_mova SUBDIR += stardict-rptts SUBDIR += stardict3 + SUBDIR += sttr SUBDIR += sv-aspell SUBDIR += sv-hunspell SUBDIR += sv-mythes diff --git a/textproc/sttr/Makefile b/textproc/sttr/Makefile new file mode 100644 index 000000000000..fca7829b3ce8 --- /dev/null +++ b/textproc/sttr/Makefile @@ -0,0 +1,59 @@ +PORTNAME= sttr +DISTVERSIONPREFIX= v +DISTVERSION= 0.2.21 +CATEGORIES= textproc + +MAINTAINER= se@FreeBSD.org +COMMENT= Quickly run various transformations on strings +WWW= https://github.com/abhimanyu003/sttr + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/LICENSE + +USES= go:modules +USE_GITHUB= yes +GH_ACCOUNT= abhimanyu003 +GH_TUPLE= atotto:clipboard:v0.1.4:atotto_clipboard/vendor/github.com/atotto/clipboard \ + aymanbagabas:go-osc52:v2.0.1:aymanbagabas_go_osc52_v2/vendor/github.com/aymanbagabas/go-osc52/v2 \ + charmbracelet:bubbles:v0.18.0:charmbracelet_bubbles/vendor/github.com/charmbracelet/bubbles \ + charmbracelet:bubbletea:v0.25.0:charmbracelet_bubbletea/vendor/github.com/charmbracelet/bubbletea \ + charmbracelet:lipgloss:v0.10.0:charmbracelet_lipgloss/vendor/github.com/charmbracelet/lipgloss \ + containerd:console:v1.0.4:containerd_console/vendor/github.com/containerd/console \ + cpuguy83:go-md2man:v2.0.4:cpuguy83_go_md2man_v2/vendor/github.com/cpuguy83/go-md2man/v2 \ + ghodss:yaml:v1.0.0:ghodss_yaml/vendor/github.com/ghodss/yaml \ + go-yaml:yaml:v2.4.0:go_yaml_yaml/vendor/gopkg.in/yaml.v2 \ + go-yaml:yaml:v3.0.1:go_yaml_yaml_1/vendor/gopkg.in/yaml.v3 \ + golang:crypto:v0.22.0:golang_crypto/vendor/golang.org/x/crypto \ + golang:net:v0.24.0:golang_net/vendor/golang.org/x/net \ + golang:sync:v0.7.0:golang_sync/vendor/golang.org/x/sync \ + golang:sys:v0.19.0:golang_sys/vendor/golang.org/x/sys \ + golang:term:v0.19.0:golang_term/vendor/golang.org/x/term \ + golang:text:v0.14.0:golang_text/vendor/golang.org/x/text \ + iancoleman:strcase:v0.3.0:iancoleman_strcase/vendor/github.com/iancoleman/strcase \ + inconshreveable:mousetrap:v1.1.0:inconshreveable_mousetrap/vendor/github.com/inconshreveable/mousetrap \ + lucasb-eyer:go-colorful:v1.2.0:lucasb_eyer_go_colorful/vendor/github.com/lucasb-eyer/go-colorful \ + mattn:go-isatty:v0.0.20:mattn_go_isatty/vendor/github.com/mattn/go-isatty \ + mattn:go-localereader:v0.0.1:mattn_go_localereader/vendor/github.com/mattn/go-localereader \ + mattn:go-runewidth:v0.0.15:mattn_go_runewidth/vendor/github.com/mattn/go-runewidth \ + mcnijman:go-emailaddress:v1.1.1:mcnijman_go_emailaddress/vendor/github.com/mcnijman/go-emailaddress \ + muesli:ansi:276c6243b2f6:muesli_ansi/vendor/github.com/muesli/ansi \ + muesli:cancelreader:v0.2.2:muesli_cancelreader/vendor/github.com/muesli/cancelreader \ + muesli:reflow:v0.3.0:muesli_reflow/vendor/github.com/muesli/reflow \ + muesli:termenv:v0.15.2:muesli_termenv/vendor/github.com/muesli/termenv \ + mvdan:xurls:v2.5.0:mvdan_xurls/vendor/mvdan.cc/xurls/v2 \ + rivo:uniseg:v0.4.7:rivo_uniseg/vendor/github.com/rivo/uniseg \ + russross:blackfriday:v2.1.0:russross_blackfriday_v2/vendor/github.com/russross/blackfriday/v2 \ + sahilm:fuzzy:v0.1.1:sahilm_fuzzy/vendor/github.com/sahilm/fuzzy \ + spf13:cobra:v1.8.0:spf13_cobra/vendor/github.com/spf13/cobra \ + spf13:pflag:v1.0.5:spf13_pflag/vendor/github.com/spf13/pflag \ + stretchr:testify:v1.9.0:stretchr_testify/vendor/github.com/stretchr/testify \ + vmihailenco:msgpack:v5.4.1:vmihailenco_msgpack_v5/vendor/github.com/vmihailenco/msgpack/v5 \ + vmihailenco:tagparser:v2.0.0:vmihailenco_tagparser_v2/vendor/github.com/vmihailenco/tagparser/v2 \ + yuin:goldmark:v1.7.1:yuin_goldmark/vendor/github.com/yuin/goldmark + +USE_GITLAB= yes +GL_TUPLE= abhimanyusharma003:go-ordered-json:7ef32eef8eade06db2cd5b92cb95fac45ae7831c:abhimanyusharma003_go_ordered_json/vendor/gitlab.com/abhimanyusharma003/go-ordered-json + +PLIST_FILES= bin/sttr + +.include <bsd.port.mk> diff --git a/textproc/sttr/distinfo b/textproc/sttr/distinfo new file mode 100644 index 000000000000..bf15be09f649 --- /dev/null +++ b/textproc/sttr/distinfo @@ -0,0 +1,81 @@ +TIMESTAMP = 1717334687 +SHA256 (abhimanyu003-sttr-v0.2.21_GH0.tar.gz) = d1d1f8c3577e3b9013c71f7f613068a1f394d20500f464c378830e4e14cbff3f +SIZE (abhimanyu003-sttr-v0.2.21_GH0.tar.gz) = 1231567 +SHA256 (atotto-clipboard-v0.1.4_GH0.tar.gz) = cafd64dc78f293c1e774386186f3f817461a1a8940ef86d5d9e9524b58aa791e +SIZE (atotto-clipboard-v0.1.4_GH0.tar.gz) = 5017 +SHA256 (aymanbagabas-go-osc52-v2.0.1_GH0.tar.gz) = dad92f43db3cd17e7395db59533283b5888c2780fa1b2cb67344a9feaa3291e0 +SIZE (aymanbagabas-go-osc52-v2.0.1_GH0.tar.gz) = 5875 +SHA256 (charmbracelet-bubbles-v0.18.0_GH0.tar.gz) = d7b079b4cd29f5788f59f6e62647e884837648d3e1d27feafdb90186ff528d44 +SIZE (charmbracelet-bubbles-v0.18.0_GH0.tar.gz) = 66820 +SHA256 (charmbracelet-bubbletea-v0.25.0_GH0.tar.gz) = e598ae7b918ec1d7bbdf882f8c0cfda6d177e14bd6c77ce6276df5ca2ea2ab9b +SIZE (charmbracelet-bubbletea-v0.25.0_GH0.tar.gz) = 2182577 +SHA256 (charmbracelet-lipgloss-v0.10.0_GH0.tar.gz) = 813aa969cc073c03b6801b6aa16ad50faa22cabad0f83d08b9c252248eccf771 +SIZE (charmbracelet-lipgloss-v0.10.0_GH0.tar.gz) = 56814 +SHA256 (containerd-console-v1.0.4_GH0.tar.gz) = 3b8f8b07ede2a7236d1ff2ef3e05e8e1a43f43a44dcb8e15f7d30ce910302430 +SIZE (containerd-console-v1.0.4_GH0.tar.gz) = 13622 +SHA256 (cpuguy83-go-md2man-v2.0.4_GH0.tar.gz) = b0a4c7c077ede56967deef6ab7e7696c0f46124b0b3360fd05564ec5a536f11f +SIZE (cpuguy83-go-md2man-v2.0.4_GH0.tar.gz) = 9902 +SHA256 (ghodss-yaml-v1.0.0_GH0.tar.gz) = 8a76b47cd171944612aae1cfa08bbb971b63fec16794c839252808392097de44 +SIZE (ghodss-yaml-v1.0.0_GH0.tar.gz) = 11772 +SHA256 (go-yaml-yaml-v2.4.0_GH0.tar.gz) = d8e94679e5fff6bd1a35e10241543929a5f3da44f701755babf99b3daf0faac0 +SIZE (go-yaml-yaml-v2.4.0_GH0.tar.gz) = 73209 +SHA256 (go-yaml-yaml-v3.0.1_GH0.tar.gz) = cf05411540d3e6ef8f1fd88434b34f94cedaceb540329031d80e23b74540c4e5 +SIZE (go-yaml-yaml-v3.0.1_GH0.tar.gz) = 91173 +SHA256 (golang-crypto-v0.22.0_GH0.tar.gz) = be0f461ea3ce13349996dca48fbb27537fd738aa6498fb38cfbf87a2ce31e082 +SIZE (golang-crypto-v0.22.0_GH0.tar.gz) = 1813353 +SHA256 (golang-net-v0.24.0_GH0.tar.gz) = 6fbc9f6ddc538c67affd1248d68ca85f69e0abe916181b1cd81323093afa96b9 +SIZE (golang-net-v0.24.0_GH0.tar.gz) = 1509016 +SHA256 (golang-sync-v0.7.0_GH0.tar.gz) = 39bf56d2dc04d16baabbf5eb5d847a2ad68762b5efde7ca3a8fdb24bdcdd9461 +SIZE (golang-sync-v0.7.0_GH0.tar.gz) = 18181 +SHA256 (golang-sys-v0.19.0_GH0.tar.gz) = da82f3d99abd964483ec5d622ddf620e2492ec0a18c154475f35d938c4240c7b +SIZE (golang-sys-v0.19.0_GH0.tar.gz) = 1449493 +SHA256 (golang-term-v0.19.0_GH0.tar.gz) = 9ef2c212cb48b0736054cfc3556bea414fb526fff877f6c50c30f78fa5c19218 +SIZE (golang-term-v0.19.0_GH0.tar.gz) = 14741 +SHA256 (golang-text-v0.14.0_GH0.tar.gz) = c80295e75bda599d17ccf74038139b0957b9915fae4e60d8b46f89454ef171a0 +SIZE (golang-text-v0.14.0_GH0.tar.gz) = 8974094 +SHA256 (iancoleman-strcase-v0.3.0_GH0.tar.gz) = 1cd6a7584be53d74b1e3014fa7d50a998b330580ec13109cd0558f554d3457e9 +SIZE (iancoleman-strcase-v0.3.0_GH0.tar.gz) = 5511 +SHA256 (inconshreveable-mousetrap-v1.1.0_GH0.tar.gz) = ab23e7c5cbf42564eb0190ee051b7217c04fd2599d2f26e9ebe205db75963141 +SIZE (inconshreveable-mousetrap-v1.1.0_GH0.tar.gz) = 5338 +SHA256 (lucasb-eyer-go-colorful-v1.2.0_GH0.tar.gz) = b3ee835cc398287452377266313edcc231043bae4168f8d2706e5d34ce1ce755 +SIZE (lucasb-eyer-go-colorful-v1.2.0_GH0.tar.gz) = 970830 +SHA256 (mattn-go-isatty-v0.0.20_GH0.tar.gz) = 18fc42a278e60fb7a1dffa72f20539ae88d0e292db55b513ef514b7d369883a6 +SIZE (mattn-go-isatty-v0.0.20_GH0.tar.gz) = 4713 +SHA256 (mattn-go-localereader-v0.0.1_GH0.tar.gz) = 03bd5a512b593c793cccd3a1f507e3a5ba6f92681b1fa4f812a53eddbc3751dc +SIZE (mattn-go-localereader-v0.0.1_GH0.tar.gz) = 1735 +SHA256 (mattn-go-runewidth-v0.0.15_GH0.tar.gz) = 44a5d37bd7119a9d288d7ff61cf3b4d42c2902c66b0d94136d41d2eb3cf2ba85 +SIZE (mattn-go-runewidth-v0.0.15_GH0.tar.gz) = 18284 +SHA256 (mcnijman-go-emailaddress-v1.1.1_GH0.tar.gz) = 4eb05fe197924cf98dcbe418d7a85e592eb252d9ff2a36b3074b088f1bb7d66f +SIZE (mcnijman-go-emailaddress-v1.1.1_GH0.tar.gz) = 6549 +SHA256 (muesli-ansi-276c6243b2f6_GH0.tar.gz) = 3284ff73b72fb26606a9129355fa2916647423e3ede78ba8031e6bdfa0ccef4f +SIZE (muesli-ansi-276c6243b2f6_GH0.tar.gz) = 5243 +SHA256 (muesli-cancelreader-v0.2.2_GH0.tar.gz) = afd827ad56d7c567389a516ca005ea80d46ed1cbc17c5ec3ca144152f1ecfc5a +SIZE (muesli-cancelreader-v0.2.2_GH0.tar.gz) = 9443 +SHA256 (muesli-reflow-v0.3.0_GH0.tar.gz) = f797b8c25d447e314ad92b155433562446c683924171be1698ad44f24c79f651 +SIZE (muesli-reflow-v0.3.0_GH0.tar.gz) = 21245 +SHA256 (muesli-termenv-v0.15.2_GH0.tar.gz) = 547a35fca6d807006fc15bdd819f175e4214b2153d39b5c6f5df217d4d4fe6ec +SIZE (muesli-termenv-v0.15.2_GH0.tar.gz) = 422802 +SHA256 (mvdan-xurls-v2.5.0_GH0.tar.gz) = 552779a765de29e51ff01fe6c85a7d0389faae1b80d354332e7c69db232ee4ad +SIZE (mvdan-xurls-v2.5.0_GH0.tar.gz) = 27562 +SHA256 (rivo-uniseg-v0.4.7_GH0.tar.gz) = dc7aedce4a8c174b01df8406ff7d92779e2df76cee2ad17fa2ff6777feddadec +SIZE (rivo-uniseg-v0.4.7_GH0.tar.gz) = 458088 +SHA256 (russross-blackfriday-v2.1.0_GH0.tar.gz) = a13af0fc5305713f5154693feaf654d024689efea76390091a5e8c757335b4f4 +SIZE (russross-blackfriday-v2.1.0_GH0.tar.gz) = 92896 +SHA256 (sahilm-fuzzy-v0.1.1_GH0.tar.gz) = 3242679be224552ef8934524cb08bb5d355644084a3476509bedd4dba57af408 +SIZE (sahilm-fuzzy-v0.1.1_GH0.tar.gz) = 3353368 +SHA256 (spf13-cobra-v1.8.0_GH0.tar.gz) = 66605a6a2297d819e3f92fa38fa6d7771fb8a4adb00e9aa7cb34021bd8389602 +SIZE (spf13-cobra-v1.8.0_GH0.tar.gz) = 189706 +SHA256 (spf13-pflag-v1.0.5_GH0.tar.gz) = 9a2cae1f8e8ab0d2cc8ebe468e871af28d9ac0962cf0520999e3ba85f0c7b808 +SIZE (spf13-pflag-v1.0.5_GH0.tar.gz) = 50796 +SHA256 (stretchr-testify-v1.9.0_GH0.tar.gz) = ee651d4d4427d55096007190398102383498e6b5cf97ea9e89ad6e72b4115fbb +SIZE (stretchr-testify-v1.9.0_GH0.tar.gz) = 108663 +SHA256 (vmihailenco-msgpack-v5.4.1_GH0.tar.gz) = cffb190f68ddf9d248e1587080466981ed911cf08901c6a81f4edc8d66b69f90 +SIZE (vmihailenco-msgpack-v5.4.1_GH0.tar.gz) = 37770 +SHA256 (vmihailenco-tagparser-v2.0.0_GH0.tar.gz) = 676b99c051fef68d1b0fb0385103de0e42a3ee556919b2b54ff5d3445bac56dd +SIZE (vmihailenco-tagparser-v2.0.0_GH0.tar.gz) = 3683 +SHA256 (yuin-goldmark-v1.7.1_GH0.tar.gz) = e1159c456d6d5c8fdfeb61534aa23ef6f4108bbf74a21016199debfdde82590a +SIZE (yuin-goldmark-v1.7.1_GH0.tar.gz) = 252103 +SHA256 (sttr-v0.2.21.tar.bz2) = d1d1f8c3577e3b9013c71f7f613068a1f394d20500f464c378830e4e14cbff3f +SIZE (sttr-v0.2.21.tar.bz2) = 1231567 +SHA256 (abhimanyusharma003-go-ordered-json-7ef32eef8eade06db2cd5b92cb95fac45ae7831c_GL0.tar.gz) = fdbdaf569fda5a0758e6c9c02b74872e384896d31333a90d85bb89db447d0153 +SIZE (abhimanyusharma003-go-ordered-json-7ef32eef8eade06db2cd5b92cb95fac45ae7831c_GL0.tar.gz) = 5974 diff --git a/textproc/sttr/files/patch-go.mod b/textproc/sttr/files/patch-go.mod new file mode 100644 index 000000000000..b9206ff2b84f --- /dev/null +++ b/textproc/sttr/files/patch-go.mod @@ -0,0 +1,10 @@ +--- go.mod.orig 2024-05-27 14:22:20 UTC ++++ go.mod +@@ -1,6 +1,6 @@ module github.com/abhimanyu003/sttr + module github.com/abhimanyu003/sttr + +-go 1.22 ++go 1.21 + + require ( + github.com/charmbracelet/bubbles v0.18.0 diff --git a/textproc/sttr/pkg-descr b/textproc/sttr/pkg-descr new file mode 100644 index 000000000000..2b58485c2e72 --- /dev/null +++ b/textproc/sttr/pkg-descr @@ -0,0 +1,21 @@ +The sttr command allows you to quickly run various text transformation +operations: + +- ascii85, base32, base64, base64url, and base85 encode/decode +- HTML encode/decode +- URL encode/decode +- rot13 encode +- generate bcrypt, md5, sha1, sha256, or sha512 checksum +- transform to camel-, kebab-, slug-, snake-, title-case +- transform to lower or upper case +- shuffle, sort, or unique lines +- reverse text character by character or line by line +- remove spaces or new-line characters +- count characters, words, or lines +- convert a #hex color code to RGB +- hex encode/decode +- format text as JSON +- convert between JSON and MSGPACK or YAML text +- convert markdown to HTML +- extract emails, IP numbers, or URLs from text +- pad numbers with zeroes