Hosting my #Git repos on GitHub is feeling increasingly icky because of the way Microsoft is scraping and reusing user code without consent, violating free software licenses in the process. I don't have code worth a shit hosted with them and don't care about the open GitHub Pages repo which I'm using as a quote-unquote free host of my static site. But I also have private repos of writing projects hosted with them and have no confidence at all that the privacy of this content will be respected.

So what are recommended alternatives for a use-case like mine? #Codeberg? Self-host? I don't need fancy actions or anything like that, just trustworthiness and integrity both morally and technically. I could probably self-host if it's just Mastodon- or wiki-levels of fiddly, at a much higher difficulty level (say: email hosting) I'm likely better off with an external host. An external host also has the advantage of not falling prey to my incompetence as a sysadmin, which is why I've held my nose and used GitHub all this time lol.

@ljwrites I just run gitea in a snap on my server and in termux on my phone. It's pretty neat, but people are getting nervous about the company formed around gitea, and are moving to Forgejo (from the Codeberg folks).

For hosted stuff, Codeberg's probably a good place to land. It probably depends on what features you need.

@spacehobo A Git server on a phone is not the image I was prepared to be presented with this night, and yet xD

Yeah I just need it to be a Git repo I can push to, pull from, clone and so on, no really involved development workflow stuff needed. The ability to collaborate would be nice, which was another advantage of GH because everyone and their dog who's the least bit techy has an account, but not an absolute. Thanks for the info, I'll look more into CB.

@ljwrites doesn't help with the git part, but for static sites I use https://surge.sh

free, easy, and (afaik) nothing objectionable about them

Surge

Shipping web projects should be fast, easy, and low risk. Surge is static web publishing for Front-End Developers, right from the CLI.

@catdad Ooh this looks so fun! If it works out I could just delete everything off of GH yay :D
@ljwrites I have a synology NAS. They’re pricier than other NAS but worth it IMHO as it’s a brilliant little box. Effectively a tiny Linux server with a slick ui, the option to ssh in directly and many options to backup to remote storage services. It can act as a git remote server to any device (whilst on the same network).
@ljwrites I've started putting stuff on @Codeberg. Some ppl I know use sourcehut.org / sr.ht.
@nev Those two often seem to come up in the same breath xD will have to look into both.

@ljwrites if you don’t need a web UI hosting your own git is very simple. The “remote” repository can be a separate directory on your computer or any other computer you can ssh to. If you don’t need collaboration you might even stick with your local repository and concentrate on good back ups.

https://git-scm.com/book/en/v2/Git-on-the-Server-The-Protocols

Git - The Protocols

@ljwrites I host mine on a linux server with ssh - that is all. No fancy tools or anything. Plain git and ssh.
@ruskie So plain Git isn't too complicated to host? Which do you use, Gitea or something else?

@ljwrites plain git.
git init /path/on/server
git clone user@server:/path/on/server

That's all. No extra tools or anything beyond basic git.

@ruskie @ljwrites That's how I host all of my stuff.

@drwho @ruskie @ljwrites If you want CI, that meshes well with #Laminar https://laminar.ohwg.net/

Personally I'd also use the #git http-backend #cgi program + #nginx since it has some benefits. Maybe also #gitweb if I want it to be public.

All of those, at least on #Debian, are provided by the git, nginx and laminar packages.

Laminar - Lightweight Continuous Integration

Continuous Integration the Light Way. Laminar is a lightweight yet highly extensible self-hosted Continuous Integration platform for Linux

@lispi314 @ruskie @ljwrites I use that for my COVID-19 data repository. Needed some patching (and desperately needs some CSS) but perfectly workable.
@lispi314 as was already suggested — plain #git will do just fine. Should you need to share the repository with others I can’t recommend #gitolite enough: https://gitolite.com
gitolite.com

@hadret I've actually had issues with gitolite & networked filesystems.

Some of its file operations have checks that don't play well with certain types of attribute translation.

@ljwrites @rrwo if you’re not using GitHub to collaborate or share code, why do you need it hosted vs local and backed up?

My primary GitHub usage is to make it easy to keep code in sync across devices, but I sure don’t need GH for that, it’s just easy.

@ljwrites

I've used gitlab with no problems.

@ljwrites
We're moving to @Codeberg but we gotta lotta stuff to move to it will be a slow process done in our mythical spare time...

@ljwrites
I moved to Codeberg, both static site and code. Esp. the static site was very easy to move over. (The code repos also, of course.)
I'm inclined to trust their privacy arrangements as they have to be GDPR compliant.

@bhaugen
@Codeberg

@wim_v12e @bhaugen It *would* be nice to have a repo that can do both! Interest rising...
@ljwrites I run forgejo. Its a gitea fork. Just like gitea its super easy to setup and requires basically no maintenance other than updating postgresql when needed and updating system packages, both of which you'd already be doing if you self host
@joe sounds nice! Definitely another option to look into.
@ljwrites if it's just about your git repositories, https://forgejo.org/ (the software behind codeberg) is very easy to self-host. Less-than-mastodon-levels of finicky, especially if you don't expect high traffic.
Forgejo – Beyond coding. We forge.

Forgejo is a self-hosted lightweight software forge. Easy to install and low maintenance, it just does the job.

@ljwrites I've been moving all my stuff off GH since before they sold out, (2015-ish) and have put various projects on gitlab, codeberg, and sourcehut

gitlab is unbearably slow on old hardware; maybe for personal use that's fine for you, but I have moved almost all my stuff off it to avoid inflicting its performance woes on other people, also by far the buggiest of the 3

sourcehut is very fast and simple but the author is a jerk which makes me reluctant to recommend it

codeberg is a user-owned cooperative which makes it ideologically the best of the 3; their CI is very rough/immature and their comment box has a very bad accessibility bug making it unusable for mouseless users, but other than that it's been nearly flawless

@ljwrites on the other hand if it's for strictly personal use without collaboration you don't need a git server, you can just push to an existing SSH account remote and git will automatically create a repo for you there
@technomancy Thank you for the vivid comparative review! I'll have to think about my uses, for now I'm leaning toward CB or maybe just a remote SSH-connected repo and no more, as you say.
@technomancy @ljwrites I've been using gitea and it was super easy to set up and use

@technomancy @ljwrites

but the author is a jerk

I went looking for a blog post he made a while back where he seemed to be turning a new leaf.

Ever since, I ... well, I haven't been watching really, but have kept it in mind when he and his stuff passed through my attention every now and again.

I didn't find the post I had in mind, but I found this one from last year.

https://drewdevault.com/2022/05/30/bleh.html

I have made no shortage of mistakes, and there are plenty of hurt feelings which can be laid at my feet. I am regretful for my mistakes, and I have worked actively to improve.

He's also on the fediverse, again (like a lot of people who left and came back).

I don't know whether it would be a kindness or not to tag him into this discussion.

I'm still not sure sourcehut is something I want to touch, yet alone recommend.

But when someone sincerely tries to do better--which I think he is doing--I think we're all better off to give them some room to do that.

bleh

@idlestate @ljwrites that post is a good start; honestly I'm basing my stance on things that happened a couple years ago, and I haven't paid close attention since then

I'd prefer to see a public apology for some specific racist comments made to a friend of mine back then; I am willing to believe that he regrets saying those things, but until I actually hear that I'm kind of ... wavering

given that the comment was made to my friend, and not to me, and my friend isn't really around on fedi any more, I may be waiting for something that's never going to happen (or it could have happened and I missed it)

it's complicated

@technomancy

more than fair

thanks for filling in some of the blanks for me

@ljwrites

@ljwrites regardless of the fact that scraping for machine learning is not violating said licenses and that there's only a very finite way to handle a certain problem efficiently in any given programming language aside [ https://felixreda.eu/2021/07/github-copilot-is-not-infringing-your-copyright/ ] I'd recommend #SelfHosting #GitLab or #Gitea depending on what features you need.
GitHub Copilot is not infringing your copyright

Felix Reda
@ljwrites gitea/forgejo is impressively easy to selfhost, much easier than mastodon
@Ember definitely options to consider, thank you!

@ljwrites I like the suggestions here, but just for my personal experience - I use a Gitea container setup for my code hosting. It's really simple to get set up and lightweight, just one port to forward and you're good to go. Especially if it's just gonna be you using it.

If you *do* end up needing something more powerful, GitLab is a decent alternative. Both of those are self-hosted solutions, and you shouldn't have any trouble getting Gitea to run on a little single-board if you wanna get really lightweight with it. That's how I used to host it for years!