URL shortener in Go, Rust or PHP reddit / selfhosted ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-16 00:57 Suggest me a few in Go, Rust or PHP A **lightweight**, simple and convenient. Preferably with web UI. I've found a few, and I could even write one myself. I'm aware of https://dub.sh/ -- and it's not what I'm looking for. ---------------------------------------------------------------------- thekrautboy · 2023-12-16 01:29 Most of them are meant to be deployed as Docker containers, so the specific versions of Go/rust/php/etc dont matter to the user because they are taken care of by the publisher of the image. Take a look at the URL shorteners listed in the awesome-selfhosted list from the subreddit sidebar, inspect the Dockerfiles, some of them might fight your requirements. ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-16 02:08 I'm not asking what to do. I'm asking what they are. ---------------------------------------------------------------------- thekrautboy · 2023-12-16 02:24 What? ---------------------------------------------------------------------- Kaleodis · 2023-12-16 03:13 Dude, all the info is in the sidebar. Do your own research, this sub ain't for low effort questions. Jeez. ---------------------------------------------------------------------- revereddesecration · 2023-12-16 03:23 Your question is a bad question and you won’t get any good answers. ---------------------------------------------------------------------- Fanyang-Meng · 2023-12-16 04:10 Dude did not even took a look of the list and posted this low effort question here. ---------------------------------------------------------------------- Open_Resolution_1969 · 2023-12-16 06:04 I've used Polr, but seems it's no longer maintained. Now I have https://shlink.io/ on my list ---------------------------------------------------------------------- dudeskeeroo · 2023-12-16 07:24 +1 for shlink in a docker container behind a reverse proxy. It has a webui but also works easily with a REST API and curl. ---------------------------------------------------------------------- vogelke · 2023-12-16 09:52 Here's a simple Perl URL-shortener. It tries to keep the host portion if there is one; if not, it uses "https://site.me/t" for the tiny URL. Code (BYODB): #!/usr/bin/perl #) { chomp; print tinyurl($_), "\n"; } exit(0); #--------------------------------------------------------------------- # Good hash, written in C for speed. use Digest::SHA3 qw/sha3_224/; # Encode according to the base64 scheme for "URL applications". This is # a variant of the base64 encoding which does not use padding, does not # break the string into multiple lines and use the characters "-" and # "_" instead of "+" and "/" to avoid using reserved URL characters. use MIME::Base64 qw/encode_base64url/; sub tinyurl { my $str = shift; my $site; # Extract the site, if there is one. if ($str =~ m!^(https://.*?/)!) { $site = $1 . "t/"; } else { $site = "https://site.me/t/"; } my $bytes = sha3_224($_); my $digest = substr(encode_base64url($bytes), 0, 7); return $site . $digest; } Example: me% cat long https://dev.to/lichtkind/system-thinking-2fmp https://github.com/ajanin/uni2ascii https://ubuntuforums.org/showthread.php?t=251868 https://www.google.com/search?q=perl+xml+encoding+conversion https://www.reddit.com/r/selfhosted/comments/18ag6is/need_flexible _backup/ https://www.xml.com/pub/2000/04/26/encodings/index.html /path/to/some/file me% ./turl long https://dev.to/t/w6B8FvL https://github.com/t/TonpIcw https://ubuntuforums.org/t/FBzYzBU https://www.google.com/t/Kb9LaY0 https://www.reddit.com/t/porKI6_ https://www.xml.com/t/CP0EylR https://site.me/t/Z-EZ5ZZ Hope this gives you some ideas. ---------------------------------------------------------------------- Annual-Advisor-7916 · 2023-12-16 14:48 WTF, you are asking others to do the work for you? Fuck off I guess... ---------------------------------------------------------------------- string-user-equals · 2023-12-16 18:46 > I could even write one myself. But why would I? If you can write the code then you either have a bunch of additional requirements you aren’t saying or you are lazy af lol. This would take maybe an hour tops to write 🤣 ---------------------------------------------------------------------- Vogete · 2023-12-16 22:09 Maybe just try these? https://github.com/awesome-selfhosted/awesome-selfhosted?tab=readme- ov-file#url-shorteners ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-19 14:53 Deaf? Or unable to read? ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-19 14:53 He didn't. Correct. ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-19 14:54 Then bring it up over here. ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-19 14:55 Re-read my question ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-19 14:55 Because I wan't you to write it for me. ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-19 14:56 The question isn't "where to look for", but "which ones" ---------------------------------------------------------------------- string-user-equals · 2023-12-19 15:12 Sure, but then you have to write something for me 😈 ---------------------------------------------------------------------- Vogete · 2023-12-19 21:58 Start from the top, and stop if you found something that suits you. ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-20 00:02 Reread my question ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-20 00:02 > Sure, Go!!!!!!!!!!!! ---------------------------------------------------------------------- Vogete · 2023-12-20 06:59 > Suggest me a few Just did, it's on the list. If you want any, start trying. >and I could even write one Then do it if you're so smart. > why would I? Because you need it, not me. If you don't like it then I guess ¯⁠\⁠_⁠(⁠ツ⁠)⁠_⁠/⁠¯ ---------------------------------------------------------------------- ddifdevsda · 2023-12-20 14:50 Oof. Rude ---------------------------------------------------------------------- ddifdevsda · 2023-12-20 14:53 You are toxic. Please learn some social etiquette. We are trying to help each other, for f’s sake… ---------------------------------------------------------------------- ddifdevsda · 2023-12-20 14:54 Re-read your life choices. You are rude af :( ---------------------------------------------------------------------- ddifdevsda · 2023-12-20 14:55 Just don’t reply, mate. This person is def not worth the effort ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-22 02:26 Re-read my question. You're a cocky cock :( ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-22 02:26 You are toxic. Please learn some social etiquette. We are trying to help each other, for f’s sake… ---------------------------------------------------------------------- Background_Bar_70 · 2023-12-22 02:26 Oof. Rude