Skip to content

Commit

Permalink
add bootstrap icons/tailwind/lint/prettier workflows/remove php qr code
Browse files Browse the repository at this point in the history
  • Loading branch information
Zoey2936 committed Jun 1, 2024
1 parent ef83fe9 commit bf68860
Show file tree
Hide file tree
Showing 172 changed files with 282 additions and 12,380 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/bootstrap-icons.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: bootstrap-icons
on:
push:
paths:
- src/bootstrap-icons.json
- .github/workflows/bootstrap-icons.yml
schedule:
- cron: "0 */6 * * *"
workflow_dispatch:
jobs:
bootstrap-icons:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: update bootstrap-icons
run: |
curl -sL $(curl -sL https://api.github.com/repos/twbs/icons/releases/latest --header "authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" | jq -r .assets[].browser_download_url) -o bootstrap-icons.zip
unzip bootstrap-icons.zip
rm -rf src/public/bootstrap-icons bootstrap-icons.zip
mv bootstrap-icons-* bootstrap-icons
mkdir src/public/bootstrap-icons
for icon in $(jq -r .[] src/bootstrap-icons.json); do mv bootstrap-icons/"$icon".svg src/public/bootstrap-icons/"$icon".svg; done
- name: push changes
run: |
git add src/public/bootstrap-icons
git config user.name "GitHub"
git config user.email "noreply@github.com"
git diff-index --quiet HEAD || git commit -sm "bootstrap-icons"
git push
23 changes: 23 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: lint
on:
push:
schedule:
- cron: "0 */6 * * *"
workflow_dispatch:
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: lint
run: |
cd src
cp -v config.php.example config.php
find . -name "*.php" -exec php -l {} \;
curl -sSfL https://github.com/wapmorgan/PhpDeprecationDetector/releases/download/"$(git ls-remote --tags https://github.com/wapmorgan/PhpDeprecationDetector | cut -d/ -f3 | grep -v v1 | sort -V | tail -1)"/phpdd-"$(git ls-remote --tags https://github.com/wapmorgan/PhpDeprecationDetector | cut -d/ -f3 | grep -v v1 | sort -V | tail -1)".phar -o phpdd.phar
chmod +x phpdd.phar
find . -name "*.php" -exec ./phpdd.phar -n {} \;
curl -sSfL https://github.com/vimeo/psalm/releases/latest/download/psalm.phar -o psalm.phar
chmod +x psalm.phar
./psalm.phar --no-cache
24 changes: 24 additions & 0 deletions .github/workflows/prettier.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: prettier
on:
push:
schedule:
- cron: "0 */6 * * *"
workflow_dispatch:
jobs:
prettier:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: prettier
run: |
yarn global add prettier @prettier/plugin-php prettier-plugin-tailwindcss
cd src
prettier . -w --end-of-line crlf --print-width 10000 --plugin /home/runner/.config/yarn/global/node_modules/@prettier/plugin-php/standalone.js --plugin /home/runner/.config/yarn/global/node_modules/prettier-plugin-tailwindcss/dist/index.mjs
- name: push
run: |
git add -A
git config user.name "GitHub"
git config user.email "noreply@github.com"
git diff-index --quiet HEAD || git commit -sm "prettier"
git push
25 changes: 25 additions & 0 deletions .github/workflows/tailwindcss-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: tailwindcss-update
on:
push:
schedule:
- cron: "0 */6 * * *"
workflow_dispatch:
jobs:
tailwindcss-update:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- run: cp -v src/tailwind.config.js tailwind.config.js
- name: update tailwindcss (minify)
uses: ZoeyVid/tailwindcss-update@main
with:
input: src/tailwind-input.css
output: src/public/tailwind.css
params: "--minify"
- name: push changes
run: |
git config user.name "GitHub"
git config user.email "noreply@github.com"
git diff-index --quiet HEAD || git commit -sm "tailwindcss-update"
git push
8 changes: 4 additions & 4 deletions .imgbotconfig
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"schedule": "daily",
"aggressiveCompression": "true",
"compressWiki": "true",
"minKBReduced": 0
"schedule": "daily",
"aggressiveCompression": "true",
"compressWiki": "true",
"minKBReduced": 0
}
6 changes: 2 additions & 4 deletions renovate.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
{
"extends": [
"config:base"
],
"baseBranches": ["develop", "php"],
"extends": ["config:base"],
"baseBranches": [],
"includeForks": true,
"automerge": false,
"branchPrefix": "renovate-deps-update-",
Expand Down
3 changes: 3 additions & 0 deletions src/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
public/tailwind.css
composer.lock
vendor
1 change: 1 addition & 0 deletions src/bootstrap-icons.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
["github", "cloud-download-fill", "cloud-upload-fill"]
67 changes: 33 additions & 34 deletions src/composer.json
Original file line number Diff line number Diff line change
@@ -1,38 +1,37 @@
{
"name": "zoeyvid/npmplus",
"description": "WebUI for NPMplus, which manages nginx and acme.sh",
"type": "project",
"require": {
"phpmailer/phpmailer": "6.9.1",
"endroid/qr-code": "5.0.9",
"ext-sqlite3": "*"
"name": "zoeyvid/npmplus",
"description": "WebUI for NPMplus, which manages nginx and acme.sh",
"type": "project",
"require": {
"phpmailer/phpmailer": "6.9.1",
"ext-sqlite3": "*"
},
"license": "AGPL-3.0",
"version": "v0.0.1-alpha",
"authors": [
{
"name": "Zoey",
"email": "zoey@z0ey.de",
"homepage": "https://z0ey.de"
},
"license": "AGPL-3.0",
"version": "v0.0.1-alpha",
"authors": [
{
"name": "Zoey",
"email": "zoey@z0ey.de",
"homepage": "https://z0ey.de"
},
{
"name": "David",
"email": "david@davidcraft.de",
"homepage": "https://davidcraft.de"
},
{
"name": "ZoeyVid",
"email": "zoeyvid@zvcdn.de",
"homepage": "https://zoeyvid.de"
}
],
"minimum-stability": "alpha",
"support": {
"email": "zoey@z0ey.de",
"issues": "https://github.com/ZoeyVid/booking/issues",
"forum": "https://github.com/ZoeyVid/booking/discussions",
"wiki": "https://github.com/ZoeyVid/booking",
"source": "https://github.com/ZoeyVid/booking",
"docs": "https://github.com/ZoeyVid/booking"
{
"name": "David",
"email": "david@davidcraft.de",
"homepage": "https://davidcraft.de"
},
{
"name": "ZoeyVid",
"email": "zoeyvid@zvcdn.de",
"homepage": "https://zoeyvid.de"
}
],
"minimum-stability": "alpha",
"support": {
"email": "zoey@z0ey.de",
"issues": "https://github.com/ZoeyVid/NPMplus/issues",
"forum": "https://github.com/ZoeyVid/NPMplus/discussions",
"wiki": "https://github.com/ZoeyVid/NPMplus",
"source": "https://github.com/ZoeyVid/NPMplus",
"docs": "https://github.com/ZoeyVid/NPMplus"
}
}
Loading

0 comments on commit bf68860

Please sign in to comment.