Add templates

This commit is contained in:
eyedeekay
2025-04-26 19:56:57 -04:00
parent ad08931b28
commit 93e9d01a98
2 changed files with 77 additions and 0 deletions

View File

@ -1,2 +1,32 @@
#! /usr/bin/env sh
if [ -z "$GITEA_CUSTOM" ]; then
echo "GITEA_CUSTOM is not set. Please set it to the path where you want to install Gitea custom files."
exit 1
fi
if [ ! -d "$GITEA_CUSTOM" ]; then
echo "GITEA_CUSTOM is not a directory. Please set it to a valid directory."
exit 1
fi
if [ ! -d "$GITEA_CUSTOM/public" ]; then
echo "Creating $GITEA_CUSTOM/public directory."
mkdir -p $GITEA_CUSTOM/public
fi
if [ -d "$GITEA_CUSTOM/public/.well-known" ]; then
cp -rv .well-known/* $GITEA_CUSTOM/public/.well-known/
else
cp -rv .well-known $GITEA_CUSTOM/public/.well-known
fi
if [ -d "$GITEA_CUSTOM/public/assets" ]; then
cp -rv assets/* $GITEA_CUSTOM/public/assets
else
cp -rv assets $GITEA_CUSTOM/public/assets
fi
if [ -d "$GITEA_CUSTOM/public/templates" ]; then
cp -rv templates/* $GITEA_CUSTOM/public/templates
else
cp -rv templates $GITEA_CUSTOM/public/templates
fi

47
templates/home.tmpl Normal file
View File

@ -0,0 +1,47 @@
{{template "base/head" .}}
<div role="main" aria-label="{{if .IsSigned}}{{ctx.Locale.Tr "dashboard"}}{{else}}{{ctx.Locale.Tr "home"}}{{end}}" class="page-content home">
<div class="tw-mb-8 tw-px-8">
<div class="center">
<img class="logo" width="220" height="220" src="{{AssetUrlPrefix}}/img/logo.svg" alt="{{ctx.Locale.Tr "logo"}}">
<div class="hero">
<h1 class="ui icon header title">
{{AppName}}
</h1>
<h2>{{ctx.Locale.Tr "startpage.app_desc"}}</h2>
</div>
</div>
</div>
<div class="ui stackable middle very relaxed page grid">
<div class="eight wide center column">
<h1 class="hero ui icon header">
{{svg "octicon-flame"}} I2P is an anonymous network layer that allows for censorship-resistant, peer-to-peer communication.
</h1>
<p class="large">
This is the gitea for the Java I2P Project and the Go I2P Project.
It is also open to contributions from the community.
User accounts are subject to approval by the admin.
Third-party users are encourage to use federation to interact when possible.
<a href="http://git.idk.i2p">git.idk.i2p</a> is the in-network registered hostname for this service.
<a href="http://7qeve4v2chmjdqlwpa3vl7aojf3nodbku7vepnjwrsxljzqipz6a.b32.i2p">7qeve4v2chmjdqlwpa3vl7aojf3nodbku7vepnjwrsxljzqipz6a.b32.i2p></a> is git.idk.i2p in base32 form.
<a href="https://57z3ffssd34lztr2dgkddqd36sdn73luzrkgkvuh7wjfxxy7tqea.b32.i2p/">57z3ffssd34lztr2dgkddqd36sdn73luzrkgkvuh7wjfxxy7tqea.b32.i2p</a> is the HTTPS version. HTTPS is not required for gitea in I2P, but some browsers prefer it.
<a href=""></a> is an onion service with HTTPS which is made available for Tor users.
</p>
</div>
<div class="eight wide center column">
<h1 class="hero ui icon header">
{{svg "octicon-device-desktop"}} I2P is Free Software, and is not affiliated with any government or corporation.
</h1>
<p class="large">
Looking for the application? You can find it on the <a href="https://geti2p.net/en/download">I2P website</a>.
</p>
</div>
</div>
<div class="ui stackable middle very relaxed page grid">
<div class="eight wide center column">
</div>
<div class="eight wide center column">
</div>
</div>
</div>
{{template "base/footer" .}}