1
1
Fork 0

Start trying to customize Gitea homepage

Bill Ewanick 2023-10-07 20:12:22 -04:00
parent 8c399fcf82
commit fd66437cf6
2 changed files with 46 additions and 1 deletions

View File

@ -1,4 +1,4 @@
{ pkgs, ... }: { pkgs, config, ... }:
let baseUrl = "git.ewanick.com"; let baseUrl = "git.ewanick.com";
in in
{ {
@ -21,6 +21,23 @@ in
}; };
}; };
# Shamelessly stolen from:
# <https://github.com/foo-dogsquared/nixos-config/blob/626a92624d1d2e9376adda879eef6a570b4be1e4/hosts/plover/modules/services/gitea.nix#L203-L215>
# Customizing Gitea which you can see more details at
# https://docs.gitea.io/en-us/customizing-gitea/. We're just using
# systemd-tmpfiles to make this work which is pretty convenient.
systemd.tmpfiles.rules =
let
# To be used similarly to $GITEA_CUSTOM variable.
giteaCustomDir = config.services.gitea.customDir;
in
[
"L+ ${giteaCustomDir}/templates/home.tmpl - - - - ${./${baseUrl}/home.tmpl}"
# "L+ ${giteaCustomDir}/public/img/logo.svg - - - - ${./${baseUrl}/logo.svg}"
# "L+ ${giteaCustomDir}/public/img/logo.png - - - - ${./${baseUrl}/logo.png}"
];
# services.gitea-actions-runner.instances = { # services.gitea-actions-runner.instances = {
# "first-runner" = { # "first-runner" = {
# enable = true; # enable = true;

View File

@ -0,0 +1,28 @@
{{template "base/head" .}}
<div class="page-content home">
<div class="ui stackable middle very relaxed page grid">
<div class="sixteen wide center aligned centered column">
<div class="hero">
<h1 class="ui header title">
<a href="https://foodogsquared.one">foodogsquared</a>'s personal forge
</h1>
<div>
<img class="logo" width="220" height="220" src="{{AssetUrlPrefix}}/img/logo.svg" alt="{{.locale.Tr "logo"}}"/>
</div>
</div>
<div class="ui stackable center">
<p class="large">
A single-user instance for the purpose of showing my personal projects without a bunch of scattered projects I forgot to remove in my other code repositories (e.g., GitHub, GitLab).
Includes my personal projects (of course) and a bunch of mirrored repositories I'm mainly interested in archiving.
</p>
<p class="large">
Though this is a single-user instance, I'm also interested in collaboration in this instance.
Feel free to send some patches in email at <code>$FOODOGSQUARED_GITEA_USER@$FOODOGSQUARED_DOMAIN</code> and I'll consider it to be merged.
If the time comes, the need for email patches is reduced once <a href="https://forgefed.org/" target="_blank" rel="noreferrer noopener nofollow">ForgeFed protocol</a> has been implemented.
Once that happens, that would be the preferred way of collaborating.
</p>
</div>
</div>
</div>
</div>
{{template "base/footer" .}}