Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update libraries and remove deprecations #818 #819

Open
wants to merge 34 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
6434819
add php8, use sqlite for tests
tacman Nov 14, 2021
9122a7e
add php8, use sqlite for tests
tacman Nov 14, 2021
8f11d9e
remove some deprecation messages
tacman Nov 14, 2021
7db9633
run tests on my branch
tacman Nov 14, 2021
e3fb8eb
drop support for < php 7.4
tacman Nov 14, 2021
cb4437c
re-add mysql
tacman Nov 14, 2021
8b1827f
try with postgres
tacman Aug 25, 2022
93123b8
update composer with allow-plugins
tacman Aug 25, 2022
6ba6269
merge upstream
tacman Sep 5, 2022
4023629
remove req for symfony and php
tacman Sep 5, 2022
7679715
merge upstream
tacman Sep 26, 2022
6b32334
tweak validator so that reddit.com/.rss doesn't fail
tacman Sep 26, 2022
caad335
php8.1 with postgres
tacman Sep 26, 2022
656c917
merge upstream
tacman Sep 26, 2022
786d874
remove survos/base and umbrella, add bootstrap
tacman Sep 27, 2022
67ab9af
Merge branch 'j0k3r:master' into master
tacman Apr 21, 2023
1bb4c96
merge upstream
tacman Apr 21, 2023
f37eb2e
Merge remote-tracking branch 'upstream/master'
tacman Mar 15, 2024
0bd4543
merge main
tacman Mar 15, 2024
3a7bab6
use attributes instead of annotations
tacman Mar 15, 2024
c8c5e30
get working with 6.4
tacman Mar 15, 2024
3aaa6df
remove sensio
tacman Mar 15, 2024
4b3fa2f
update recipe
tacman Mar 15, 2024
eff518c
update recipe
tacman Mar 15, 2024
17f8f32
update recipe
tacman Mar 15, 2024
311908f
update recipe
tacman Mar 15, 2024
52e14e6
back to 6.4 until gaby/sites-config is updated
tacman Mar 15, 2024
86168a9
add AssetMapper
tacman Mar 15, 2024
63c8516
add registration, refactor security a bit, drop webpack and add asset…
tacman Mar 15, 2024
f2c447e
Merge branch 'j0k3r:master' into master
tacman Nov 15, 2024
deb33d5
merge upstream, fix depenencies so Symfony 7.1 and php 8.3 work
tacman Nov 15, 2024
30268ff
updates for Symfony 7 and survos utilities
tacman Nov 15, 2024
8a14980
start to use tabler, last commit before new repo
tacman Nov 15, 2024
0bc0720
initial version
tacman Nov 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,11 @@ APP_SECRET=951e2173ffafecadc57cbbb2263567ea
# DATABASE_URL="sqlite:///%kernel.project_dir%/var/data.db"
# DATABASE_URL="mysql://app:!ChangeMe!@127.0.0.1:3306/app?serverVersion=8&charset=utf8mb4"
# DATABASE_URL="postgresql://app:!ChangeMe!@127.0.0.1:5432/app?serverVersion=15&charset=utf8"
DATABASE_URL=mysql://root:root@127.0.0.1:3306/f43me?serverVersion=5.7&charset=utf8mb4
#DATABASE_URL=mysql://root:root@127.0.0.1:3306/f43me?serverVersion=5.7&charset=utf8mb4
DATABASE_URL=postgresql://postgres:docker@127.0.0.1:5434/f43?serverVersion=16&charset=utf8

# DATABASE_URL="mysql://app:!ChangeMe!@127.0.0.1:3306/app?serverVersion=8.0.32&charset=utf8mb4"
# DATABASE_URL="mysql://app:!ChangeMe!@127.0.0.1:3306/app?serverVersion=10.11.2-MariaDB&charset=utf8mb4"
###< doctrine/doctrine-bundle ###

###> sentry/sentry-symfony ###
Expand Down
20 changes: 8 additions & 12 deletions .github/workflows/continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
- "master"
push:
branches:
- "master"
- "tac"

env:
fail-fast: true
Expand Down Expand Up @@ -34,10 +34,11 @@ jobs:
strategy:
matrix:
php:
- "7.4"
- "8.0"
- "8.1"
- "8.2"
- "8.3"
include:
- php: "8.3"
coverage: true

steps:
- name: Checkout
Expand All @@ -64,9 +65,6 @@ jobs:
node-version-file: ".nvmrc"
cache: "yarn"

- name: Install dependencies with Yarn
run: yarn install && yarn dev

- name: Setup messenger queue
run: php bin/console messenger:setup-transports --env=dev

Expand All @@ -81,10 +79,10 @@ jobs:

postgresql:
name: PHPUnit (PHP ${{ matrix.php }} with PostgreSQL)
runs-on: "ubuntu-20.04"
runs-on: "ubuntu-22.04"
services:
postgres:
image: postgres:14-alpine
image: postgres:16-alpine
env:
POSTGRES_PASSWORD: root
ports:
Expand All @@ -100,10 +98,8 @@ jobs:
strategy:
matrix:
php:
- "7.4"
- "8.0"
- "8.1"
- "8.2"
- "8.3"

steps:
- name: Checkout
Expand Down
18 changes: 12 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,15 @@
/phpunit.xml
###< symfony/phpunit-bridge ###

###> symfony/webpack-encore-bundle ###
/node_modules/
/public/build/
npm-debug.log
yarn-error.log
###< symfony/webpack-encore-bundle ###
###> phpunit/phpunit ###
/phpunit.xml
.phpunit.result.cache
###< phpunit/phpunit ###
###> symfony/asset-mapper ###
/public/assets/
/assets/vendor/
###< symfony/asset-mapper ###

###> phpstan/phpstan ###
phpstan.neon
###< phpstan/phpstan ###
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,15 @@ Anyway, it's simple:

![f43.me screenshot](https://user-images.githubusercontent.com/62333/158586771-2137ea59-e882-4f89-9dd4-5eb657b843c5.png)

## Issues

graby is key, but out of date.

```bash
composer config repositories.graby '{"type": "path", "url": "/home/tac/g/tacman/graby"}'
composer req j0k3r/graby:*@dev
```

## Contents

<!-- MarkdownTOC autolink="true" -->
Expand Down Expand Up @@ -68,7 +77,7 @@ You can find some examples in the [improver folder](https://github.com/j0k3r/f43

Parser that gets html content from an url and find what can be the most interesting part for the user is important. But, most of the time they fail when it comes to images (like from Imgur, Flickr) or from social network (like Tumblr, Twitter or Facebook).

These online service provides API to retrieve content from the their platform. Extractors will use them to grab the *real* content.
These online service provides API to retrieve content from their platform. Extractors will use them to grab the *real* content.

An extractor uses 2 methods:

Expand Down
12 changes: 9 additions & 3 deletions assets/app.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
const timeago = require('timeago.js')
import '@picocss/pico/css/pico.min.css';
import 'htmx.org'

import './styles/app.scss'
import '@tabler/core'; // the js
import '@tabler/core/dist/css/tabler.min.css'


import timeago from 'timeago.js';
// import './styles/app.scss'

// handle timeago date on the public page
if (document.querySelectorAll('.time-ago').length > 0) {
timeago.render(document.querySelectorAll('.time-ago'), { minInterval: 60 })
// timeago.render(document.querySelectorAll('.time-ago'), { minInterval: 60 })
}

// handle show / hide of the textarea when testing config file
Expand Down
3 changes: 3 additions & 0 deletions assets/styles/app.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
body {
background-color: skyblue;
}
5 changes: 5 additions & 0 deletions bin/create-admins.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/env bash

bin/console survos:user:create tacman@gmail.com tt
bin/console survos:user:create tt@survos.com tt --roles ROLE_ADMIN --roles ROLE_SUPER_ADMIN

17 changes: 17 additions & 0 deletions c
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/usr/bin/env php
<?php

use App\Kernel;
use Symfony\Bundle\FrameworkBundle\Console\Application;

if (!is_file(dirname(__FILE__).'/vendor/autoload_runtime.php')) {
throw new LogicException('Symfony Runtime is missing. Try running "composer require symfony/runtime".');
}

require_once dirname(__FILE__).'/vendor/autoload_runtime.php';

return function (array $context) {
$kernel = new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);

return new Application($kernel);
};
8 changes: 8 additions & 0 deletions compose.override.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: '3'

services:
###> doctrine/doctrine-bundle ###
database:
ports:
- "5432"
###< doctrine/doctrine-bundle ###
71 changes: 37 additions & 34 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,38 +22,39 @@
}
],
"require": {
"php": "^7.4",
"php": "^8.3",
"ext-tidy": "*",
"beberlei/doctrineextensions": "^1.2",
"composer/package-versions-deprecated": "^1.11",
"doctrine/doctrine-bundle": "^2.0",
"doctrine/orm": "^2.5",
"doctrine/doctrine-bundle": "^2.4",
"doctrine/orm": "^3.0",
"gedmo/doctrine-extensions": "^3.6.0",
"j0k3r/graby": "dev-master",
"j0k3r/graby-site-config": "^1",
"j0k3r/php-imgur-api-client": "~4.0",
"laminas/laminas-code": "^4.5",
"php-http/guzzle7-adapter": "^1.0",
"php-http/httplug-bundle": "^1.14",
"ricardoper/twitteroauth": "~1.0",
"sensio/framework-extra-bundle": "^6.0",
"sentry/sentry-symfony": "^5.0",
"simplepie/simplepie": "^1.8",
"stof/doctrine-extensions-bundle": "~1.1",
"symfony/amqp-messenger": "5.4.*",
"symfony/asset": "5.4.*",
"symfony/dotenv": "5.4.*",
"survos/auth-bundle": "*",
"survos/command-bundle": "^1.5",
"symfony/amqp-messenger": "^7.0",
"symfony/asset": "^7.0",
"symfony/asset-mapper": "^7.0",
"symfony/dotenv": "^7.0",
"symfony/flex": "^1.9",
"symfony/form": "5.4.*",
"symfony/lock": "5.4.*",
"symfony/form": "^7.0",
"symfony/lock": "^7.0",
"symfony/monolog-bundle": "^3.5",
"symfony/polyfill-php80": "^1.27",
"symfony/runtime": "5.4.*",
"symfony/security-bundle": "5.4.*",
"symfony/translation": "5.4.*",
"symfony/twig-bundle": "5.4.*",
"symfony/validator": "5.4.*",
"symfony/webpack-encore-bundle": "^1.13",
"symfony/yaml": "5.4.*",
"symfony/runtime": "^7.0",
"symfony/security-bundle": "^7.0",
"symfony/translation": "^7.0",
"symfony/twig-bundle": "^7.0",
"symfony/validator": "^7.0",
"symfony/yaml": "^7.0",
"tacman/graby": "dev-tac",
"twig/extra-bundle": "^2.12|^3.0",
"twig/twig": "^2.12|^3.0"
},
Expand All @@ -62,18 +63,19 @@
"friendsofphp/php-cs-fixer": "~3.0",
"php-http/mock-client": "^1.3",
"phpstan/extension-installer": "^1.0",
"phpstan/phpstan": "^0.12",
"phpstan/phpstan-deprecation-rules": "^0.12.5",
"phpstan/phpstan-doctrine": "^0.12",
"phpstan/phpstan-phpunit": "^0.12",
"phpstan/phpstan-symfony": "^0.12",
"symfony/browser-kit": "5.4.*",
"symfony/css-selector": "5.4.*",
"symfony/debug-bundle": "5.4.*",
"phpstan/phpstan": "*",
"phpstan/phpstan-deprecation-rules": "*",
"phpstan/phpstan-doctrine": "*",
"phpstan/phpstan-phpunit": "*",
"phpstan/phpstan-symfony": "*",
"rector/rector": "*",
"symfony/browser-kit": "^7.0",
"symfony/css-selector": "^7.0",
"symfony/debug-bundle": "^7.0",
"symfony/maker-bundle": "^1.21",
"symfony/phpunit-bridge": "7.1.*",
"symfony/stopwatch": "5.4.*",
"symfony/web-profiler-bundle": "5.4.*"
"symfony/phpunit-bridge": "^7.0",
"symfony/stopwatch": "^7.0",
"symfony/web-profiler-bundle": "^7.0"
},
"conflict": {
"symfony/symfony": "*"
Expand All @@ -87,27 +89,28 @@
],
"auto-scripts": {
"cache:clear": "symfony-cmd",
"assets:install %PUBLIC_DIR%": "symfony-cmd"
"assets:install %PUBLIC_DIR%": "symfony-cmd",
"importmap:install": "symfony-cmd"
}
},
"config": {
"platform": {
"php": "7.4.26"
},
"bin-dir": "bin",
"sort-packages": true,
"allow-plugins": {
"mnsami/composer-custom-directory-installer": true,
"phpstan/extension-installer": true,
"symfony/flex": true,
"symfony/runtime": true,
"php-http/discovery": true
"php-http/discovery": true,
"endroid/installer": true
}
},
"extra": {
"symfony": {
"allow-contrib": true,
"require": "5.4.*",
"docker": true
"require": "^7.0"
}
}
}
Loading