Skip to content

Commit

Permalink
Merge pull request #33 from P3D-Legacy/develop
Browse files Browse the repository at this point in the history
Release 4.0.0
  • Loading branch information
dsbilling authored Apr 2, 2022
2 parents 4678966 + cfbee65 commit 49ae7bb
Show file tree
Hide file tree
Showing 622 changed files with 36,316 additions and 7,221 deletions.
44 changes: 38 additions & 6 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
APP_NAME=Laravel
APP_NAME="Pokémon 3D"
APP_ENV=local
APP_KEY=
APP_DEBUG=true
Expand All @@ -10,14 +10,14 @@ LOG_LEVEL=debug
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=skin
DB_DATABASE=laravel
DB_USERNAME=root
DB_PASSWORD=

BROADCAST_DRIVER=log
CACHE_DRIVER=file
QUEUE_CONNECTION=sync
SESSION_DRIVER=file
SESSION_DRIVER=database
SESSION_LIFETIME=120

MEMCACHED_HOST=127.0.0.1
Expand All @@ -26,7 +26,7 @@ REDIS_HOST=127.0.0.1
REDIS_PASSWORD=null
REDIS_PORT=6379

MAIL_MAILER=smtp
MAIL_MAILER=log
MAIL_HOST=mailhog
MAIL_PORT=1025
MAIL_USERNAME=null
Expand All @@ -53,11 +53,43 @@ GAMEJOLT_GAME_PRIVATE_KEY=null

GAMEJOLT_USER_ID_SUPERADMIN=null

API_GITHUB_REPO=https://api.github.com/repos/P3D-Legacy/P3D-Legacy/releases/latest
GITHUB_API_REPO=https://api.github.com/repos/P3D-Legacy/P3D-Legacy

SKIN_MAX_UPLOAD=10

DISCORD_SKIN_UPLOAD_WEBHOOK=null
DISCORD_TOKEN=null
DISCORD_SERVER_ID=null
DISCORD_INVITE_URL="https://discordapp.com/invite/EUhwdrq"

DISCORD_CLIENT_ID=null
DISCORD_CLIENT_SECRET=null

SENTRY_LARAVEL_DSN=null
SENTRY_TRACES_SAMPLE_RATE=1
SENTRY_TRACES_SAMPLE_RATE=null

XENFORO_BASE_WEB_URL="https://pokemon3d.net/forum"
XENFORO_API_KEY=null

GAME_SERVER_URL="https://karp.pokemon3d.net"

SUPER_ADMIN_EMAIL=null

LOGIN_AUTH_BLOG_POST=null

SCRIBE_AUTH_KEY=null

MAIL_TO_ADDRESS="${SUPER_ADMIN_EMAIL}"

TWITTER_CLIENT_ID=null
TWITTER_CLIENT_SECRET=null

FACEBOOK_CLIENT_ID=null
FACEBOOK_CLIENT_SECRET=null

TWITCH_CLIENT_ID=null
TWITCH_CLIENT_SECRET=null

LANG_CONTRIBUTION_URL=null

POSTMARK_TOKEN=null
11 changes: 11 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Please see the documentation for all configuration options:
# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
labels:
- "dependencies"
31 changes: 31 additions & 0 deletions .github/workflows/dependabot-auto-merge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: dependabot-auto-merge
on: pull_request_target

permissions:
pull-requests: write
contents: write

jobs:
dependabot:
runs-on: ubuntu-latest
if: ${{ github.actor == 'dependabot[bot]' }}
steps:
- name: Dependabot metadata
id: metadata
uses: dependabot/[email protected]
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"

- name: Auto-merge Dependabot PRs for semver-minor updates
if: ${{steps.metadata.outputs.update-type == 'version-update:semver-minor'}}
run: gh pr merge --auto --merge "$PR_URL"
env:
PR_URL: ${{github.event.pull_request.html_url}}
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

- name: Auto-merge Dependabot PRs for semver-patch updates
if: ${{steps.metadata.outputs.update-type == 'version-update:semver-patch'}}
run: gh pr merge --auto --merge "$PR_URL"
env:
PR_URL: ${{github.event.pull_request.html_url}}
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
14 changes: 14 additions & 0 deletions .github/workflows/jsoncheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Check JSON syntax

on:
pull_request:

jobs:
jsoncheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: json-syntax-check
uses: limitusus/json-syntax-check@v1
with:
pattern: "\\.json$"
16 changes: 5 additions & 11 deletions .github/workflows/laravel.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Laravel
on: [push, pull_request]
on: [pull_request]
jobs:
laravel:
name: Laravel (PHP ${{ matrix.php-versions }} on ${{ matrix.operating-system }})
Expand All @@ -8,7 +8,7 @@ jobs:
fail-fast: false
matrix:
operating-system: [ubuntu-latest]
php-versions: ['8.0']
php-versions: ['8.1']
steps:
- name: Checkout
uses: actions/checkout@v2
Expand Down Expand Up @@ -43,15 +43,9 @@ jobs:
run: |
mkdir -p database
touch database/database.sqlite
- name: Test with phpunit
- name: Test with pest
env:
DB_CONNECTION: sqlite
DB_DATABASE: database/database.sqlite
run: vendor/bin/phpunit --coverage-clover clover.xml
- name: Codecov
uses: codecov/[email protected]
with:
file: ./clover.xml
flags: unittests
name: codecov-umbrella
fail_ci_if_error: true
MAIL_FROM_ADDRESS: [email protected]
run: vendor/bin/pest
19 changes: 19 additions & 0 deletions .github/workflows/prettier.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Prettier
on: [push]

jobs:
Prettier:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2
with:
ref: ${{ github.head_ref }}
- name: Install NPM dependencies
run: npm install
- name: Prettify code
uses: creyD/[email protected]
with:
prettier_options: --write **/*.{php,js} --config .prettierrc --ignore-path .prettierignore
prettier_plugins: '@prettier/plugin-php prettier-plugin-tailwindcss'
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,8 @@ yarn-error.log
public/css/bootstrap.min.css
public/js/bootstrap.min.js
public/skin/*.png
.scribe/
resources/views/scribe/
public/vendor/scribe/
.vscode/
.idea/
10 changes: 10 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
/vendor
/storage
/node_modules
/.github
/public
README.md
CHANGELOG.md
LICENSE
phpunit.xml
/lang
8 changes: 8 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"tabWidth": 4,
"useTabs": false,
"semi": true,
"trailingComma": "all",
"singleQuote": true,
"printWidth": 125
}
58 changes: 53 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,61 @@

<p align="center">
<img src="https://github.com/P3D-Legacy/pokemon3d.net/workflows/Laravel/badge.svg" alt="Test Status">
<img src="https://img.shields.io/github/license/P3D-Legacy/pokemon3d.net" alt="License">
<img src="https://img.shields.io/github/contributors/P3D-Legacy/pokemon3d.net" alt="Contributors">
<img src="https://img.shields.io/github/issues/P3D-Legacy/pokemon3d.net" alt="Issues">
<img src="https://img.shields.io/github/v/tag/P3D-Legacy/pokemon3d.net" alt="Tag">
<img src="https://img.shields.io/github/contributors/P3D-Legacy/pokemon3d.net" alt="Contributors">
<img src="https://img.shields.io/github/license/P3D-Legacy/pokemon3d.net" alt="License">
<a href="https://discordapp.com/invite/EUhwdrq" target="_blank"><img src="https://img.shields.io/discord/299181628188524544" alt="Discord"></a>
<a href="https://skin.pokemon3d.net" target="_blank"><img src="https://img.shields.io/website?down_color=red&down_message=offline&up_color=green&up_message=online&url=https%3A%2F%pokemon3d.net%2F" alt="Website"></a>
<a href="https://pokemon3d.net" target="_blank"><img src="https://img.shields.io/website?down_color=red&down_message=offline&up_color=green&up_message=online&url=https%3A%2F%2Fnext.pokemon3d.net" alt="Website"></a>
</p>

## About
# About

Our new website is built with Laravel and Tailwind CSS. This new website has replaced the old design from 2014. With the new design, we have a much cleaner and more modern website. And we will more easily be adding more features to the website in the future.

# Contribute
Want to contribute to the project? Check out [CONTRIBUTING.md](CONTRIBUTING.md) for more info.

# Installation
Want to install the project? Here is a quick guide to installing the project.

Please check the official laravel installation guide for server requirements before you start, [official documentation](https://laravel.com/docs/8.x/installation).

Clone the repository
``` bash
git clone [email protected]:P3D-Legacy/pokemon3d.net.git
```
Switch to the repo folder
``` bash
cd pokemon3d.net
```
Install all the dependencies using composer
``` bash
composer install
```
Install all the dependencies using npm
``` bash
npm install
```
Copy the example env file and make the required configuration changes in the .env file
``` bash
cp .env.example .env
```

Generate a new application key
``` bash
php artisan key:generate
```
We've made it easy for updating stuff for the application. Running this command will migrate the database, set settings, seed needed data, update API docs and more.
``` bash
php artisan p3d:update
```
Start the local development server
``` bash
php artisan serve
```
You can now access the server at http://localhost:8000

# Licence

This site is a *work in progress* and but has been published under `skin.pokemon3d.net` until it is finished. It is built with Laravel and Tailwind CSS. This will be replacing the design from 2014.
This software is licensed under the GPL-3.0 License. Check out [LICENSE](LICENSE) for more info.
28 changes: 28 additions & 0 deletions app/Achievements/User/AssociatedDiscord.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?php

declare(strict_types=1);

namespace App\Achievements\User;

use Assada\Achievements\Achievement;

/**
* Class Registered
*/
class AssociatedDiscord extends Achievement
{
/*
* The achievement name
*/
public $name = 'AssociatedDiscord';

/*
* A small description for the achievement
*/
public $description = 'User associated their account with Discord';

/*
* The amount of "points" this user need to obtain in order to complete this achievement
*/
public $points = 1;
}
28 changes: 28 additions & 0 deletions app/Achievements/User/AssociatedFacebook.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?php

declare(strict_types=1);

namespace App\Achievements\User;

use Assada\Achievements\Achievement;

/**
* Class Registered
*/
class AssociatedFacebook extends Achievement
{
/*
* The achievement name
*/
public $name = 'AssociatedFacebook';

/*
* A small description for the achievement
*/
public $description = 'User associated their account with Facebook';

/*
* The amount of "points" this user need to obtain in order to complete this achievement
*/
public $points = 1;
}
28 changes: 28 additions & 0 deletions app/Achievements/User/AssociatedGamejolt.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?php

declare(strict_types=1);

namespace App\Achievements\User;

use Assada\Achievements\Achievement;

/**
* Class Registered
*/
class AssociatedGamejolt extends Achievement
{
/*
* The achievement name
*/
public $name = 'AssociatedGamejolt';

/*
* A small description for the achievement
*/
public $description = 'User associated their account with Gamejolt';

/*
* The amount of "points" this user need to obtain in order to complete this achievement
*/
public $points = 1;
}
Loading

0 comments on commit 49ae7bb

Please sign in to comment.