Skip to content
simple updater with email notification for gitea
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


This script send you a notification when a new version of gitea is available. It can update gitea with only one command.


  1. How it works
  2. Install
  3. Configure variables
  4. Uninstall
  5. Usage
  6. Author, Warning, Licence and Changelog


  • Gitea
  • Bash
  • mailx

How it works

This script will be launched manually or through a cron :

  • check last version of gitea on github
  • check if version is different than current version
    • send you a notification if new version available and option -n (or -c for dry-run)
    • run update if new version available and option -u


  • Install this script where you want (i.e. : /usr/local/bin/ )
    cp /usr/local/bin/

  • Edit it with the good values in the part VARIABLES (see Configure variables)

  • Change rights
    chmod 700 /usr/local/bin/

  • Add cron for periodic check (i.e. every day at 5am)
    echo "0 5 * * * root /usr/local/bin/ -n >/dev/null" > /etc/cron.d/gitea

  • Check if it works : /usr/local/bin/ -c

  • No restart needed.

  • When new version available, use the option -u as like as the noficitaion suggest

Configure variables

go to the 'VARIABLES' part in the script

key value example
MAIL_FROM sender 'Your Mail<>'
MAIL_TO destination '<>'
GITEA_PATH path where gitea is installed "/usr/local/bin/"
GITEA_USER dedicated user for gitea "gitea"
CHANGE_LOG_MAX_LINES max lines of changlog returned in notification 100


  • remove this script (i.e. if installed in suggested path)
    rm /usr/local/bin/

  • remove cron file rm /etc/cron.d/gitea


Usage : ${0##*/} <Option>

Option :
-c : Check (Dry-Run notification)
-n : Notify when update are available
-u : do the update


PiDroid-B, 2019


Use it at your own risk. The author assumes no responsibility for all usage or error that result from this script.


This project is licensed under the GPL v3 License. See the LICENSE file for the full license text.


version release date description
1.0.0 2019-08-24 Init
You can’t perform that action at this time.