Compare commits
24 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6748bc4ba4 | ||
|
|
c71241dcd7 | ||
|
|
d47181cfbe | ||
|
|
a0ba3f61f4 | ||
|
|
aef8acfe9f | ||
|
|
fb3d3146c8 | ||
|
|
ec332a519a | ||
|
|
7fe886a278 | ||
|
|
3458601402 | ||
|
|
32870cc447 | ||
|
|
0efe142ea0 | ||
| 5eba9d705c | |||
| 1319d59c8c | |||
| 05e12dde69 | |||
| a0035707b8 | |||
|
|
cdaf096965 | ||
|
|
46263f3195 | ||
|
|
3c4efa15c2 | ||
|
|
a24d001d98 | ||
|
|
107988a5b3 | ||
|
|
ae82b926f6 | ||
|
|
b12134b1c0 | ||
|
|
c56e16206b | ||
|
|
06a4e56ee7 |
@@ -4,6 +4,31 @@ on:
|
|||||||
branches: main
|
branches: main
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
tests:
|
||||||
|
name: Tests
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
- name: Setup PHP with Xdebug
|
||||||
|
uses: shivammathur/setup-php@v2
|
||||||
|
with:
|
||||||
|
php-version: '8.1'
|
||||||
|
coverage: xdebug
|
||||||
|
- name: Install dependencies with composer
|
||||||
|
run: composer update --no-ansi --no-interaction --no-progress
|
||||||
|
- name: Run tests with phpunit/phpunit
|
||||||
|
run: vendor/bin/phpunit --coverage-clover=coverage.xml
|
||||||
|
- name: Fix code coverage paths
|
||||||
|
run: sed -i 's@'$GITHUB_WORKSPACE'@/github/workspace/@g' coverage.xml
|
||||||
|
- name: SonarCloud Scan
|
||||||
|
uses: SonarSource/sonarcloud-github-action@master
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||||
|
|
||||||
release-on-push:
|
release-on-push:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
outputs:
|
outputs:
|
||||||
@@ -26,9 +51,9 @@ jobs:
|
|||||||
build:
|
build:
|
||||||
name: GitHub Container Registry
|
name: GitHub Container Registry
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: [prepare-data]
|
needs: [tests, release-on-push]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: Login to GitHub Container Registry
|
- name: Login to GitHub Container Registry
|
||||||
run: echo ${{ secrets.PAT }} | docker login ghcr.io -u luketainton --password-stdin
|
run: echo ${{ secrets.PAT }} | docker login ghcr.io -u luketainton --password-stdin
|
||||||
- name: Build image for GitHub Container Registry
|
- name: Build image for GitHub Container Registry
|
||||||
@@ -10,7 +10,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/stale@v4
|
- uses: actions/stale@v8
|
||||||
with:
|
with:
|
||||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
stale-issue-message: 'This issue has been marked as stale due to inactivity. If this issue is still ongoing, please leave a comment.'
|
stale-issue-message: 'This issue has been marked as stale due to inactivity. If this issue is still ongoing, please leave a comment.'
|
||||||
@@ -5,9 +5,9 @@ build:
|
|||||||
stage: build
|
stage: build
|
||||||
only:
|
only:
|
||||||
- tags
|
- tags
|
||||||
image: docker:19.03.12
|
image: docker:23.0.3
|
||||||
services:
|
services:
|
||||||
- docker:19.03.12-dind
|
- docker:23.0.3-dind
|
||||||
variables:
|
variables:
|
||||||
IMAGE_TAG: "$CI_REGISTRY_IMAGE:$CI_COMMIT_TAG"
|
IMAGE_TAG: "$CI_REGISTRY_IMAGE:$CI_COMMIT_TAG"
|
||||||
script:
|
script:
|
||||||
1130
app/composer.lock
generated
1130
app/composer.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -6,6 +6,8 @@
|
|||||||
$updates = get_updates($db, $request);
|
$updates = get_updates($db, $request);
|
||||||
$authorised_users = get_subscribers($db, $request);
|
$authorised_users = get_subscribers($db, $request);
|
||||||
$is_authorised = isAuthorised($_SESSION['uuid'], $authorised_users, $request);
|
$is_authorised = isAuthorised($_SESSION['uuid'], $authorised_users, $request);
|
||||||
|
|
||||||
|
$rid = htmlspecialchars($_GET['rid'])
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
||||||
@@ -131,7 +133,7 @@
|
|||||||
<div class="form-group" style="margin: 2%;">
|
<div class="form-group" style="margin: 2%;">
|
||||||
<textarea type="text" class="form-control" id="msg" name="msg" rows="3"></textarea>
|
<textarea type="text" class="form-control" id="msg" name="msg" rows="3"></textarea>
|
||||||
<button type="submit" class="btn btn-primary" style="margin-top: 2%;">Submit</button>
|
<button type="submit" class="btn btn-primary" style="margin-top: 2%;">Submit</button>
|
||||||
<a href="/view?rid=<?php echo($_GET['rid']); ?>" class="btn btn-danger" style="margin-top: 2%;">Cancel</a>
|
<a href="/view?rid=<?php echo($rid); ?>" class="btn btn-danger" style="margin-top: 2%;">Cancel</a>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -6,6 +6,8 @@
|
|||||||
$updates = get_updates($db, $request);
|
$updates = get_updates($db, $request);
|
||||||
$authorised_users = get_subscribers($db, $request);
|
$authorised_users = get_subscribers($db, $request);
|
||||||
$is_authorised = isAuthorised($_SESSION['uuid'], $authorised_users, $request);
|
$is_authorised = isAuthorised($_SESSION['uuid'], $authorised_users, $request);
|
||||||
|
|
||||||
|
$rid = htmlspecialchars($_GET['rid']);
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
||||||
@@ -131,7 +133,7 @@
|
|||||||
<div class="form-group" style="margin: 2%;">
|
<div class="form-group" style="margin: 2%;">
|
||||||
<input type="file" class="form-control-file" id="file" name="file">
|
<input type="file" class="form-control-file" id="file" name="file">
|
||||||
<button type="submit" class="btn btn-primary" style="margin-top: 2%;">Submit</button>
|
<button type="submit" class="btn btn-primary" style="margin-top: 2%;">Submit</button>
|
||||||
<a href="/view?rid=<?php echo($_GET['rid']); ?>" class="btn btn-danger" style="margin-top: 2%;">Cancel</a>
|
<a href="/view?rid=<?php echo($rid); ?>" class="btn btn-danger" style="margin-top: 2%;">Cancel</a>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
12
sonar-project.properties
Normal file
12
sonar-project.properties
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
sonar.projectKey=luketainton_FHeD
|
||||||
|
sonar.organization=luketainton
|
||||||
|
|
||||||
|
# This is the name and version displayed in the SonarCloud UI.
|
||||||
|
#sonar.projectName=FHeD
|
||||||
|
#sonar.projectVersion=1.0
|
||||||
|
|
||||||
|
# Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows.
|
||||||
|
#sonar.sources=.
|
||||||
|
|
||||||
|
# Encoding of the source code. Default is default system encoding
|
||||||
|
#sonar.sourceEncoding=UTF-8
|
||||||
Reference in New Issue
Block a user