mirror of
https://github.com/YunoHost-Apps/weblate_ynh.git
synced 2024-10-01 13:35:04 +02:00
commit
561c057cf1
5 changed files with 29 additions and 32 deletions
4
.github/workflows/updater.yml
vendored
4
.github/workflows/updater.yml
vendored
|
@ -14,7 +14,7 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Fetch the source code
|
||||
uses: actions/checkout@v2
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
- name: Run the updater script
|
||||
|
@ -33,7 +33,7 @@ jobs:
|
|||
- name: Create Pull Request
|
||||
id: cpr
|
||||
if: ${{ env.PROCEED == 'true' }}
|
||||
uses: peter-evans/create-pull-request@v3
|
||||
uses: peter-evans/create-pull-request@v4
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
commit-message: Update to version ${{ env.VERSION }}
|
||||
|
|
|
@ -6,6 +6,7 @@ It shall NOT be edited by hand.
|
|||
# Weblate for YunoHost
|
||||
|
||||
[![Integration level](https://dash.yunohost.org/integration/weblate.svg)](https://dash.yunohost.org/appci/app/weblate) ![Working status](https://ci-apps.yunohost.org/ci/badges/weblate.status.svg) ![Maintenance status](https://ci-apps.yunohost.org/ci/badges/weblate.maintain.svg)
|
||||
|
||||
[![Install Weblate with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=weblate)
|
||||
|
||||
*[Lire ce readme en français.](./README_fr.md)*
|
||||
|
@ -17,7 +18,7 @@ If you don't have YunoHost, please consult [the guide](https://yunohost.org/#/in
|
|||
|
||||
Weblate is a libre web-based translation tool with tight version control integration. It provides two user interfaces, propagation of translations across components, quality checks and automatic linking to source files.
|
||||
|
||||
**Shipped version:** 4.15.2~ynh1
|
||||
**Shipped version:** 4.16.4~ynh1
|
||||
|
||||
**Demo:** https://hosted.weblate.org/
|
||||
|
||||
|
|
|
@ -6,6 +6,7 @@ It shall NOT be edited by hand.
|
|||
# Weblate pour YunoHost
|
||||
|
||||
[![Niveau d’intégration](https://dash.yunohost.org/integration/weblate.svg)](https://dash.yunohost.org/appci/app/weblate) ![Statut du fonctionnement](https://ci-apps.yunohost.org/ci/badges/weblate.status.svg) ![Statut de maintenance](https://ci-apps.yunohost.org/ci/badges/weblate.maintain.svg)
|
||||
|
||||
[![Installer Weblate avec YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=weblate)
|
||||
|
||||
*[Read this readme in english.](./README.md)*
|
||||
|
@ -17,7 +18,7 @@ Si vous n’avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) po
|
|||
|
||||
Weblate est un outil de traduction libre avec une intégration étroite du contrôle de version. Il fournit deux interfaces utilisateur, la propagation des traductions entre les composants, les contrôles de qualité et la liaison automatique aux fichiers source.
|
||||
|
||||
**Version incluse :** 4.15.2~ynh1
|
||||
**Version incluse :** 4.16.4~ynh1
|
||||
|
||||
**Démo :** https://hosted.weblate.org/
|
||||
|
||||
|
|
|
@ -11,25 +11,9 @@
|
|||
|
||||
################################################################################
|
||||
################################################################################
|
||||
# Copyright © Michal Čihař <michal@weblate.org>
|
||||
#
|
||||
# Copyright © 2012–2022 Michal Čihař <michal@cihar.com>
|
||||
#
|
||||
# This file is part of Weblate <https://weblate.org/>
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
#
|
||||
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
import os
|
||||
import platform
|
||||
|
@ -95,6 +79,7 @@ DATABASES = {
|
|||
# Data directory, you can use following for the development purposes:
|
||||
# os.path.join(os.path.dirname(os.path.dirname(os.path.abspath(__file__))), "data")
|
||||
DATA_DIR = os.path.join("__FINALPATH__", "data")
|
||||
CACHE_DIR = f"{DATA_DIR}/cache"
|
||||
|
||||
# Local time zone for this installation. Choices can be found here:
|
||||
# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
|
||||
|
@ -183,7 +168,7 @@ MEDIA_URL = f"{URL_PREFIX}/media/"
|
|||
# Absolute path to the directory static files should be collected to.
|
||||
# Don't put anything in this directory yourself; store your static files
|
||||
# in apps' "static/" subdirectories and in STATICFILES_DIRS.
|
||||
STATIC_ROOT = os.path.join(DATA_DIR, "static")
|
||||
STATIC_ROOT = os.path.join(CACHE_DIR, "static")
|
||||
|
||||
# URL prefix for static files.
|
||||
STATIC_URL = f"{URL_PREFIX}/static/"
|
||||
|
@ -244,6 +229,10 @@ GITLAB_CREDENTIALS = {
|
|||
}
|
||||
}
|
||||
|
||||
# Bitbucket username and token for sending merge requests.
|
||||
# Please see the documentation for more details.
|
||||
BITBUCKETSERVER_CREDENTIALS = {}
|
||||
|
||||
# Authentication configuration
|
||||
AUTHENTICATION_BACKENDS = (
|
||||
"social_core.backends.email.EmailAuth",
|
||||
|
@ -378,6 +367,7 @@ REQUIRE_LOGIN = False
|
|||
MIDDLEWARE = [
|
||||
"weblate.middleware.RedirectMiddleware",
|
||||
"weblate.middleware.ProxyMiddleware",
|
||||
"corsheaders.middleware.CorsMiddleware",
|
||||
"django.middleware.security.SecurityMiddleware",
|
||||
"django.contrib.sessions.middleware.SessionMiddleware",
|
||||
"django.middleware.csrf.CsrfViewMiddleware",
|
||||
|
@ -430,10 +420,13 @@ INSTALLED_APPS = [
|
|||
# Third party Django modules
|
||||
"social_django",
|
||||
"crispy_forms",
|
||||
"crispy_bootstrap3",
|
||||
"compressor",
|
||||
"rest_framework",
|
||||
"rest_framework.authtoken",
|
||||
"django_filters",
|
||||
"django_celery_beat",
|
||||
"corsheaders",
|
||||
]
|
||||
|
||||
# Custom exception reporter to include some details
|
||||
|
@ -455,10 +448,7 @@ if platform.system() != "Windows":
|
|||
except OSError:
|
||||
HAVE_SYSLOG = False
|
||||
|
||||
if DEBUG or not HAVE_SYSLOG:
|
||||
DEFAULT_LOG = "console"
|
||||
else:
|
||||
DEFAULT_LOG = "syslog"
|
||||
DEFAULT_LOG = "console" if DEBUG or not HAVE_SYSLOG else "syslog"
|
||||
DEFAULT_LOGLEVEL = "DEBUG" if DEBUG else "INFO"
|
||||
|
||||
# A sample logging configuration. The only tangible logging
|
||||
|
@ -713,6 +703,7 @@ LIMIT_TRANSLATION_LENGTH_BY_SOURCE_LENGTH = True
|
|||
SIMPLIFY_LANGUAGES = True
|
||||
|
||||
# Render forms using bootstrap
|
||||
CRISPY_ALLOWED_TEMPLATE_PACKS = "bootstrap3"
|
||||
CRISPY_TEMPLATE_PACK = "bootstrap3"
|
||||
|
||||
# List of quality checks
|
||||
|
@ -850,7 +841,7 @@ CACHES = {
|
|||
},
|
||||
"avatar": {
|
||||
"BACKEND": "django.core.cache.backends.filebased.FileBasedCache",
|
||||
"LOCATION": os.path.join(DATA_DIR, "avatar-cache"),
|
||||
"LOCATION": os.path.join(CACHE_DIR, "avatar"),
|
||||
"TIMEOUT": 86400,
|
||||
"OPTIONS": {"MAX_ENTRIES": 1000},
|
||||
},
|
||||
|
@ -881,8 +872,8 @@ REST_FRAMEWORK = {
|
|||
"weblate.api.throttling.AnonRateThrottle",
|
||||
),
|
||||
"DEFAULT_THROTTLE_RATES": {"anon": "100/day", "user": "5000/hour"},
|
||||
"DEFAULT_PAGINATION_CLASS": ("rest_framework.pagination.PageNumberPagination"),
|
||||
"PAGE_SIZE": 20,
|
||||
"DEFAULT_PAGINATION_CLASS": "weblate.api.pagination.StandardPagination",
|
||||
"PAGE_SIZE": 50,
|
||||
"VIEW_DESCRIPTION_FUNCTION": "weblate.api.views.get_view_description",
|
||||
"UNAUTHENTICATED_USER": "weblate.auth.models.get_anonymous",
|
||||
}
|
||||
|
@ -935,7 +926,7 @@ CELERY_RESULT_BACKEND = CELERY_BROKER_URL
|
|||
|
||||
# Celery settings, it is not recommended to change these
|
||||
CELERY_WORKER_MAX_MEMORY_PER_CHILD = 200000
|
||||
CELERY_BEAT_SCHEDULE_FILENAME = os.path.join(DATA_DIR, "celery", "beat-schedule")
|
||||
CELERY_BEAT_SCHEDULER = "django_celery_beat.schedulers:DatabaseScheduler"
|
||||
CELERY_TASK_ROUTES = {
|
||||
"weblate.trans.tasks.auto_translate*": {"queue": "translate"},
|
||||
"weblate.accounts.tasks.notify_*": {"queue": "notify"},
|
||||
|
@ -947,6 +938,10 @@ CELERY_TASK_ROUTES = {
|
|||
"weblate.memory.tasks.*": {"queue": "memory"},
|
||||
}
|
||||
|
||||
# CORS allowed origins
|
||||
CORS_ALLOWED_ORIGINS = []
|
||||
CORS_URLS_REGEX = r"^/api/.*$"
|
||||
|
||||
# Enable plain database backups
|
||||
DATABASE_BACKUP = "plain"
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
"en": "Translation platform using Git and Python",
|
||||
"fr": "Plateforme de traduction utilisant Git et Python"
|
||||
},
|
||||
"version": "4.15.2~ynh1",
|
||||
"version": "4.16.4~ynh1",
|
||||
"url": "https://weblate.org",
|
||||
"upstream": {
|
||||
"license": "AGPL-3.0",
|
||||
|
|
Loading…
Reference in a new issue