Compare commits
3 Commits
dev
...
1c2353cfe1
| Author | SHA1 | Date | |
|---|---|---|---|
| 1c2353cfe1 | |||
| 496b50ed12 | |||
| 50e3ff6ded |
@@ -6,22 +6,6 @@ on:
|
|||||||
- dev
|
- dev
|
||||||
- master
|
- master
|
||||||
jobs:
|
jobs:
|
||||||
dev_tests:
|
|
||||||
if: gitea.ref_name == 'dev'
|
|
||||||
runs-on: debian-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
run: |
|
|
||||||
git clone --quiet --depth=1 --branch=${{ gitea.ref_name }} ${{ gitea.server_url }}/${{ gitea.repository }} repo
|
|
||||||
- name: Install Bats
|
|
||||||
run: |
|
|
||||||
sudo apt-get update
|
|
||||||
sudo apt-get install -y bats
|
|
||||||
- name: Run Shell Tests
|
|
||||||
run: |
|
|
||||||
cd repo
|
|
||||||
bats tests/shell/git_update.bats
|
|
||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
if: gitea.ref_name == 'master'
|
if: gitea.ref_name == 'master'
|
||||||
runs-on: self-hosted
|
runs-on: self-hosted
|
||||||
|
|||||||
@@ -93,8 +93,8 @@
|
|||||||
msg: "Database backed up to: {{ backup_result.stdout }}"
|
msg: "Database backed up to: {{ backup_result.stdout }}"
|
||||||
when: env_file.stat.exists
|
when: env_file.stat.exists
|
||||||
|
|
||||||
- name: Run database migrations safely
|
- name: Run database migrations
|
||||||
command: "keyhelp-php84 artisan migrate:safe --force"
|
command: "keyhelp-php84 artisan migrate --force"
|
||||||
args:
|
args:
|
||||||
chdir: "{{ prod_base_dir }}"
|
chdir: "{{ prod_base_dir }}"
|
||||||
register: migrate_result
|
register: migrate_result
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { useState } from 'react'
|
import { useState } from 'react'
|
||||||
import { Button, Card, Container, Form } from 'react-bootstrap'
|
import { Button, Card, Container, Form } from 'react-bootstrap'
|
||||||
import { useNavigate } from 'react-router-dom'
|
import { Link, useNavigate } from 'react-router-dom'
|
||||||
import { useAuth } from '../context/AuthContext'
|
import { useAuth } from '../context/AuthContext'
|
||||||
import { useTranslation } from 'react-i18next'
|
import { useTranslation } from 'react-i18next'
|
||||||
|
|
||||||
@@ -53,10 +53,18 @@ export default function Login() {
|
|||||||
onChange={(event) => setPassword(event.target.value)}
|
onChange={(event) => setPassword(event.target.value)}
|
||||||
required
|
required
|
||||||
/>
|
/>
|
||||||
|
<div className="mt-2 text-end">
|
||||||
|
<Link to="/reset-password">{t('auth.forgot_password')}</Link>
|
||||||
|
</div>
|
||||||
</Form.Group>
|
</Form.Group>
|
||||||
<Button type="submit" variant="dark" disabled={loading}>
|
<div className="d-flex gap-2">
|
||||||
{loading ? t('form.signing_in') : t('form.sign_in')}
|
<Button as={Link} to="/" type="button" variant="outline-secondary" disabled={loading}>
|
||||||
</Button>
|
{t('acp.cancel')}
|
||||||
|
</Button>
|
||||||
|
<Button type="submit" variant="dark" disabled={loading}>
|
||||||
|
{loading ? t('form.signing_in') : t('form.sign_in')}
|
||||||
|
</Button>
|
||||||
|
</div>
|
||||||
</Form>
|
</Form>
|
||||||
</Card.Body>
|
</Card.Body>
|
||||||
</Card>
|
</Card>
|
||||||
|
|||||||
@@ -81,6 +81,7 @@
|
|||||||
"auth.login_title": "Anmelden",
|
"auth.login_title": "Anmelden",
|
||||||
"auth.login_identifier": "E-Mail oder Benutzername",
|
"auth.login_identifier": "E-Mail oder Benutzername",
|
||||||
"auth.login_placeholder": "name@example.com oder benutzername",
|
"auth.login_placeholder": "name@example.com oder benutzername",
|
||||||
|
"auth.forgot_password": "Passwort vergessen?",
|
||||||
"auth.register_hint": "Registriere dich mit E-Mail und einem eindeutigen Benutzernamen.",
|
"auth.register_hint": "Registriere dich mit E-Mail und einem eindeutigen Benutzernamen.",
|
||||||
"auth.verify_notice": "Bitte bestätige deine E-Mail-Adresse, bevor du dich anmeldest.",
|
"auth.verify_notice": "Bitte bestätige deine E-Mail-Adresse, bevor du dich anmeldest.",
|
||||||
"auth.register_title": "Konto erstellen",
|
"auth.register_title": "Konto erstellen",
|
||||||
|
|||||||
@@ -81,6 +81,7 @@
|
|||||||
"auth.login_title": "Log in",
|
"auth.login_title": "Log in",
|
||||||
"auth.login_identifier": "Email or username",
|
"auth.login_identifier": "Email or username",
|
||||||
"auth.login_placeholder": "name@example.com or username",
|
"auth.login_placeholder": "name@example.com or username",
|
||||||
|
"auth.forgot_password": "Forgot password?",
|
||||||
"auth.register_hint": "Register with an email and a unique username.",
|
"auth.register_hint": "Register with an email and a unique username.",
|
||||||
"auth.verify_notice": "Check your email to verify your account before logging in.",
|
"auth.verify_notice": "Check your email to verify your account before logging in.",
|
||||||
"auth.register_title": "Create account",
|
"auth.register_title": "Create account",
|
||||||
|
|||||||
12
tests/run-shell-tests.sh
Normal file
12
tests/run-shell-tests.sh
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
|
ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
||||||
|
cd "$ROOT_DIR"
|
||||||
|
|
||||||
|
if ! command -v bats >/dev/null 2>&1; then
|
||||||
|
echo "bats is not installed. Install with: brew install bats-core" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
bats tests/shell/git_update.bats
|
||||||
Reference in New Issue
Block a user