Compare commits

...

239 Commits
2.6.1 ... 2.6.3

Author SHA1 Message Date
85065b509f Merge pull request #6862 from wallabag/prepare-263
Prepare wallabag 2.6.3
2023-08-21 11:57:10 +02:00
ca879c36de Prepare wallabag 2.6.3 2023-08-21 11:52:16 +02:00
ffcc5c9062 Merge pull request from GHSA-gjvc-55fw-v6vq
Replace GET way to POST way to delete API client
2023-08-21 11:08:47 +02:00
78b0b55c40 Merge pull request from GHSA-p8gp-899c-jvq9
Replace GET way to POST way to reset data user
2023-08-21 11:08:24 +02:00
94a6bc0dad Merge pull request #6806 from wallabag/dependabot/composer/craue/config-bundle-2.7.0
Bump craue/config-bundle from 2.6.0 to 2.7.0
2023-08-21 10:57:10 +02:00
383dcc5c45 Merge pull request #6119 from Spoons/feat_referer_to_session_redirect
Fix: Use Session instead of Referrer for Redirection
2023-08-21 10:32:03 +02:00
de5aa004cb Bump craue/config-bundle from 2.6.0 to 2.7.0
Bumps [craue/config-bundle](https://github.com/craue/CraueConfigBundle) from 2.6.0 to 2.7.0.
- [Changelog](https://github.com/craue/CraueConfigBundle/blob/master/CHANGELOG.md)
- [Commits](https://github.com/craue/CraueConfigBundle/compare/2.6.0...2.7.0)

---
updated-dependencies:
- dependency-name: craue/config-bundle
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-21 09:38:54 +02:00
dca910e2a6 Merge pull request #6860 from wallabag/dependabot/npm_and_yarn/sass-1.66.1
Bump sass from 1.65.1 to 1.66.1
2023-08-21 03:08:38 +00:00
bc491e3712 Bump sass from 1.65.1 to 1.66.1
Bumps [sass](https://github.com/sass/dart-sass) from 1.65.1 to 1.66.1.
- [Release notes](https://github.com/sass/dart-sass/releases)
- [Changelog](https://github.com/sass/dart-sass/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sass/dart-sass/compare/1.65.1...1.66.1)

---
updated-dependencies:
- dependency-name: sass
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-21 03:01:00 +00:00
40d7ca11da Merge pull request #6859 from wallabag/dependabot/npm_and_yarn/postcss-scss-4.0.7
Bump postcss-scss from 4.0.6 to 4.0.7
2023-08-21 02:59:43 +00:00
89d38b23e0 Merge pull request #6861 from wallabag/dependabot/npm_and_yarn/stylelint-15.10.3
Bump stylelint from 15.10.2 to 15.10.3
2023-08-21 02:57:59 +00:00
7be1a4e1b2 Merge pull request #6858 from wallabag/dependabot/npm_and_yarn/eslint-plugin-import-2.28.1
Bump eslint-plugin-import from 2.28.0 to 2.28.1
2023-08-21 02:44:22 +00:00
4d890868ed Bump postcss-scss from 4.0.6 to 4.0.7
Bumps [postcss-scss](https://github.com/postcss/postcss-scss) from 4.0.6 to 4.0.7.
- [Changelog](https://github.com/postcss/postcss-scss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/postcss/postcss-scss/compare/4.0.6...4.0.7)

---
updated-dependencies:
- dependency-name: postcss-scss
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-21 02:42:50 +00:00
1d0200c5b9 Bump stylelint from 15.10.2 to 15.10.3
Bumps [stylelint](https://github.com/stylelint/stylelint) from 15.10.2 to 15.10.3.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/15.10.2...15.10.3)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-21 02:42:47 +00:00
6a5e7dba89 Merge pull request #6857 from wallabag/dependabot/npm_and_yarn/postcss-8.4.28
Bump postcss from 8.4.27 to 8.4.28
2023-08-21 02:41:38 +00:00
6f23eba62d Bump eslint-plugin-import from 2.28.0 to 2.28.1
Bumps [eslint-plugin-import](https://github.com/import-js/eslint-plugin-import) from 2.28.0 to 2.28.1.
- [Release notes](https://github.com/import-js/eslint-plugin-import/releases)
- [Changelog](https://github.com/import-js/eslint-plugin-import/blob/main/CHANGELOG.md)
- [Commits](https://github.com/import-js/eslint-plugin-import/compare/v2.28.0...v2.28.1)

---
updated-dependencies:
- dependency-name: eslint-plugin-import
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-21 02:36:30 +00:00
d87237484c Bump postcss from 8.4.27 to 8.4.28
Bumps [postcss](https://github.com/postcss/postcss) from 8.4.27 to 8.4.28.
- [Release notes](https://github.com/postcss/postcss/releases)
- [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/postcss/postcss/compare/8.4.27...8.4.28)

---
updated-dependencies:
- dependency-name: postcss
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-21 02:36:22 +00:00
46ebbfc9a4 Merge pull request #6788 from wallabag/add-git-check
Add check if git is installed
2023-08-19 16:11:11 +02:00
8ee95437a0 Fix typo 2023-08-19 07:18:13 +02:00
ef5b43f55c Add check if git is installed
Fix #3589
2023-08-19 07:17:06 +02:00
a465db607f Merge pull request #6842 from wallabag/dependabot/npm_and_yarn/eslint-8.47.0
Bump eslint from 8.46.0 to 8.47.0
2023-08-14 03:36:07 +00:00
985c7add1d Bump eslint from 8.46.0 to 8.47.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.46.0 to 8.47.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.46.0...v8.47.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-14 03:30:45 +00:00
3d9986d6fc Merge pull request #6841 from wallabag/dependabot/npm_and_yarn/babel/core-7.22.10
Bump @babel/core from 7.22.9 to 7.22.10
2023-08-14 03:29:22 +00:00
4b7a6eaf39 Bump @babel/core from 7.22.9 to 7.22.10
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.22.9 to 7.22.10.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.22.10/packages/babel-core)

---
updated-dependencies:
- dependency-name: "@babel/core"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-14 03:20:56 +00:00
3e8cc92dcd Merge pull request #6844 from wallabag/dependabot/npm_and_yarn/autoprefixer-10.4.15
Bump autoprefixer from 10.4.14 to 10.4.15
2023-08-14 03:19:49 +00:00
6172071a64 Bump autoprefixer from 10.4.14 to 10.4.15
Bumps [autoprefixer](https://github.com/postcss/autoprefixer) from 10.4.14 to 10.4.15.
- [Release notes](https://github.com/postcss/autoprefixer/releases)
- [Changelog](https://github.com/postcss/autoprefixer/blob/main/CHANGELOG.md)
- [Commits](https://github.com/postcss/autoprefixer/compare/10.4.14...10.4.15)

---
updated-dependencies:
- dependency-name: autoprefixer
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-14 03:10:09 +00:00
cf3adbfaea Merge pull request #6845 from wallabag/dependabot/npm_and_yarn/babel/preset-env-7.22.10
Bump @babel/preset-env from 7.22.9 to 7.22.10
2023-08-14 03:08:59 +00:00
24e6311c05 Merge pull request #6843 from wallabag/dependabot/npm_and_yarn/stylelint-scss-5.1.0
Bump stylelint-scss from 5.0.1 to 5.1.0
2023-08-14 02:59:06 +00:00
69b96fe179 Bump @babel/preset-env from 7.22.9 to 7.22.10
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.22.9 to 7.22.10.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.22.10/packages/babel-preset-env)

---
updated-dependencies:
- dependency-name: "@babel/preset-env"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-14 02:51:35 +00:00
ffa2e68c5f Merge pull request #6840 from wallabag/dependabot/npm_and_yarn/babel/eslint-parser-7.22.10
Bump @babel/eslint-parser from 7.22.9 to 7.22.10
2023-08-14 02:50:24 +00:00
b338c68945 Merge pull request #6839 from wallabag/dependabot/npm_and_yarn/sass-1.65.1
Bump sass from 1.64.2 to 1.65.1
2023-08-14 02:47:30 +00:00
f67486a6df Bump stylelint-scss from 5.0.1 to 5.1.0
Bumps [stylelint-scss](https://github.com/stylelint-scss/stylelint-scss) from 5.0.1 to 5.1.0.
- [Release notes](https://github.com/stylelint-scss/stylelint-scss/releases)
- [Changelog](https://github.com/stylelint-scss/stylelint-scss/blob/master/CHANGELOG.md)
- [Commits](https://github.com/stylelint-scss/stylelint-scss/compare/v5.0.1...v5.1.0)

---
updated-dependencies:
- dependency-name: stylelint-scss
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-14 02:43:55 +00:00
33c72bb9fc Bump @babel/eslint-parser from 7.22.9 to 7.22.10
Bumps [@babel/eslint-parser](https://github.com/babel/babel/tree/HEAD/eslint/babel-eslint-parser) from 7.22.9 to 7.22.10.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.22.10/eslint/babel-eslint-parser)

---
updated-dependencies:
- dependency-name: "@babel/eslint-parser"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-14 02:43:07 +00:00
78dc311c72 Bump sass from 1.64.2 to 1.65.1
Bumps [sass](https://github.com/sass/dart-sass) from 1.64.2 to 1.65.1.
- [Release notes](https://github.com/sass/dart-sass/releases)
- [Changelog](https://github.com/sass/dart-sass/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sass/dart-sass/compare/1.64.2...1.65.1)

---
updated-dependencies:
- dependency-name: sass
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-14 02:42:52 +00:00
48226ad6e5 Merge pull request #6809 from yguedidi/replace-kernel.root_dir-by-kernel.project_dir
Replace kernel.root_dir by kernel.project_dir
2023-08-13 20:02:06 +02:00
f33d1f8e48 Merge pull request #6829 from wallabag/impr/css-content
css: reduce risk of collision for #content
2023-08-13 18:03:17 +02:00
97810f7335 css: rebuild assets
Signed-off-by: Kevin Decherf <kevin@kdecherf.com>
2023-08-13 00:09:59 +02:00
15230f488a css: reduce risk of collision for #content
`main #content` can match fetched content and break the layout, like for
technologyreview.com

Signed-off-by: Kevin Decherf <kevin@kdecherf.com>
2023-08-13 00:08:39 +02:00
89ca32e705 Merge pull request #6817 from yguedidi/split-symfony/symfony
Split symfony/symfony
2023-08-11 22:03:53 +02:00
a71d95e38a Merge pull request #6826 from weblate/weblate-wallabag-messages
Translations update from Hosted Weblate
2023-08-11 20:55:44 +02:00
fa2e1d933f Translated using Weblate (Croatian)
Currently translated at 100.0% (582 of 582 strings)
2023-08-11 14:47:40 +02:00
181fe7e1e9 Translated using Weblate (Polish)
Currently translated at 100.0% (582 of 582 strings)
2023-08-11 14:47:39 +02:00
905d61eb49 Merge pull request #6824 from wallabag/dependabot/composer/doctrine/orm-2.16.1
Bump doctrine/orm from 2.15.4 to 2.16.1
2023-08-10 08:07:08 +02:00
c78f2706c9 Bump doctrine/orm from 2.15.4 to 2.16.1
Bumps [doctrine/orm](https://github.com/doctrine/orm) from 2.15.4 to 2.16.1.
- [Release notes](https://github.com/doctrine/orm/releases)
- [Commits](https://github.com/doctrine/orm/compare/2.15.4...2.16.1)

---
updated-dependencies:
- dependency-name: doctrine/orm
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-10 07:57:48 +02:00
dbbb5f3cfb Merge pull request #6825 from wallabag/dependabot/composer/phpstan/phpstan-doctrine-1.3.42
Bump phpstan/phpstan-doctrine from 1.3.41 to 1.3.42
2023-08-10 07:57:27 +02:00
33d22c149b Bump phpstan/phpstan-doctrine from 1.3.41 to 1.3.42
Bumps [phpstan/phpstan-doctrine](https://github.com/phpstan/phpstan-doctrine) from 1.3.41 to 1.3.42.
- [Release notes](https://github.com/phpstan/phpstan-doctrine/releases)
- [Commits](https://github.com/phpstan/phpstan-doctrine/compare/1.3.41...1.3.42)

---
updated-dependencies:
- dependency-name: phpstan/phpstan-doctrine
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-10 02:06:55 +00:00
cc33fcb4ba Replace kernel.root_dir by kernel.project_dir 2023-08-09 22:46:18 +01:00
24db3d6862 Split symfony/symfony 2023-08-09 21:51:49 +01:00
c3d1f92278 Replace GET way to POST way to delete API client 2023-08-09 21:54:40 +02:00
a9893d754f Replace GET way to POST way to reset data user
Signed-off-by: Kevin Decherf <kevin@kdecherf.com>
2023-08-09 21:39:03 +02:00
f4fd8e4675 Merge pull request #6778 from wallabag/add-confirmation-before-reload
Add confirmation before reload entry
2023-08-09 19:40:49 +02:00
0ccbd653fa Merge pull request #6812 from yguedidi/make-crawler-extract-get-an-array
Make Crawler::extract get an array
2023-08-09 11:03:03 +02:00
70452cfc3f Merge pull request #6820 from wallabag/dependabot/composer/phpstan/phpstan-doctrine-1.3.41
Bump phpstan/phpstan-doctrine from 1.3.40 to 1.3.41
2023-08-09 07:54:32 +02:00
826e310687 Bump phpstan/phpstan-doctrine from 1.3.40 to 1.3.41
Bumps [phpstan/phpstan-doctrine](https://github.com/phpstan/phpstan-doctrine) from 1.3.40 to 1.3.41.
- [Release notes](https://github.com/phpstan/phpstan-doctrine/releases)
- [Commits](https://github.com/phpstan/phpstan-doctrine/compare/1.3.40...1.3.41)

---
updated-dependencies:
- dependency-name: phpstan/phpstan-doctrine
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-09 07:45:44 +02:00
b81054697b Merge pull request #6819 from wallabag/dependabot/composer/phpstan/phpstan-1.10.28
Bump phpstan/phpstan from 1.10.27 to 1.10.28
2023-08-09 07:45:15 +02:00
ddd8754a11 Bump phpstan/phpstan from 1.10.27 to 1.10.28
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan) from 1.10.27 to 1.10.28.
- [Release notes](https://github.com/phpstan/phpstan/releases)
- [Changelog](https://github.com/phpstan/phpstan/blob/1.11.x/CHANGELOG.md)
- [Commits](https://github.com/phpstan/phpstan/compare/1.10.27...1.10.28)

---
updated-dependencies:
- dependency-name: phpstan/phpstan
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-09 02:24:32 +00:00
ac1c1ff571 Merge pull request #6816 from yguedidi/use-psr-17-and-psr-18
Use PSR-17 and PSR-18
2023-08-08 23:56:10 +02:00
815158fefa Merge pull request #6813 from yguedidi/replace-client-by-kernelbrowser
Replace Client by KernelBrowser
2023-08-08 23:36:06 +02:00
e1928c78ff Merge pull request #6810 from yguedidi/replace-debug-component-by-errorhandler-component
Replace Debug component by ErrorHandler component
2023-08-08 23:28:13 +02:00
65915004e0 Merge pull request #6808 from yguedidi/make-importcontroller-extends-abstractcontroller
Make ImportController extends AbstractController
2023-08-08 23:26:37 +02:00
60cb8c0294 Merge pull request #6797 from yguedidi/use-twig-instead-of-templating
Use Twig instead of templating
2023-08-08 23:18:16 +02:00
f6e85e88af Merge pull request #6799 from yguedidi/identify-platforms-by-their-class
Identify platforms by their class
2023-08-08 23:04:42 +02:00
a4b0a01b6d Merge pull request #6798 from yguedidi/add-mandatory-$class-parameter
Add mandatory $class parameter
2023-08-08 22:59:16 +02:00
1bed15fd9b Merge pull request #6800 from yguedidi/move-from-transchoice-to-trans
Move from transchoice to trans
2023-08-08 22:57:48 +02:00
59860d9526 Merge pull request #6794 from wallabag/dependabot/composer/guzzlehttp/psr7-2.6.0
Bump guzzlehttp/psr7 from 2.5.0 to 2.6.0
2023-08-08 16:54:46 +02:00
807d473564 Merge pull request #6811 from yguedidi/replace-getresponseevent-by-requestevent
Replace GetResponseEvent by RequestEvent
2023-08-08 16:53:18 +02:00
ed17e61db2 Merge pull request #6803 from yguedidi/ensure-the-kernel-is-shut-down-before-calling-createclient
Ensure the kernel is shut down before calling createClient
2023-08-08 16:51:44 +02:00
6159c92f27 Merge pull request #6814 from yguedidi/ignore-docker-compose.override.yml
Ignore docker-compose.override.yml
2023-08-08 08:17:42 +02:00
bf176121c4 Use PSR-17 and PSR-18 2023-08-08 03:25:27 +01:00
ec33ec14e5 Replace Client by KernelBrowser 2023-08-08 02:55:35 +01:00
2aa7e7e121 Ignore docker-compose.override.yml 2023-08-08 01:35:52 +01:00
093003d9af Make Crawler::extract get an array 2023-08-07 22:51:18 +01:00
58a0ca2622 Replace GetResponseEvent by RequestEvent 2023-08-07 22:34:47 +01:00
1ba1ed23f1 Replace Debug component by ErrorHandler component 2023-08-07 22:29:48 +01:00
7beb535b7a Make ImportController extends AbstractController 2023-08-07 22:04:13 +01:00
9870785d59 Merge pull request #6805 from wallabag/dependabot/composer/phpstan/phpstan-1.10.27
Bump phpstan/phpstan from 1.10.26 to 1.10.27
2023-08-07 07:08:51 +02:00
53a2874351 Bump phpstan/phpstan from 1.10.26 to 1.10.27
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan) from 1.10.26 to 1.10.27.
- [Release notes](https://github.com/phpstan/phpstan/releases)
- [Changelog](https://github.com/phpstan/phpstan/blob/1.11.x/CHANGELOG.md)
- [Commits](https://github.com/phpstan/phpstan/compare/1.10.26...1.10.27)

---
updated-dependencies:
- dependency-name: phpstan/phpstan
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-07 02:27:25 +00:00
bb6b9f9f05 Merge pull request #6804 from wallabag/dependabot/npm_and_yarn/sass-1.64.2
Bump sass from 1.64.1 to 1.64.2
2023-08-07 02:25:08 +00:00
526ef23e1a Bump sass from 1.64.1 to 1.64.2
Bumps [sass](https://github.com/sass/dart-sass) from 1.64.1 to 1.64.2.
- [Release notes](https://github.com/sass/dart-sass/releases)
- [Changelog](https://github.com/sass/dart-sass/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sass/dart-sass/compare/1.64.1...1.64.2)

---
updated-dependencies:
- dependency-name: sass
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-07 02:19:52 +00:00
8d3d916d4a Remove extraneous blank lines from EntryController.php 2023-08-06 15:48:28 -05:00
e90daf0690 Update TagController.php 2023-08-06 20:20:35 +00:00
9729db75de Update EntryController.php 2023-08-06 20:19:49 +00:00
ced2ea4015 Merge branch 'master' into feat_referer_to_session_redirect 2023-08-06 20:14:44 +00:00
7d78e2ae06 Ensure the kernel is shut down before calling createClient 2023-08-06 13:48:53 +01:00
f43d8fa947 Move from transchoice to trans 2023-08-05 23:39:13 +01:00
f48f982025 Identify platforms by their class 2023-08-05 18:35:09 +01:00
667ea14d42 Add mandatory $class parameter 2023-08-05 17:25:03 +01:00
e93fdca2d3 Use Twig instead of templating 2023-08-05 16:43:36 +01:00
fcf6d3c3f8 Bump guzzlehttp/psr7 from 2.5.0 to 2.6.0
Bumps [guzzlehttp/psr7](https://github.com/guzzle/psr7) from 2.5.0 to 2.6.0.
- [Release notes](https://github.com/guzzle/psr7/releases)
- [Changelog](https://github.com/guzzle/psr7/blob/2.6/CHANGELOG.md)
- [Commits](https://github.com/guzzle/psr7/compare/2.5.0...2.6.0)

---
updated-dependencies:
- dependency-name: guzzlehttp/psr7
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-04 02:40:33 +00:00
c2bfc0f359 Merge pull request #6786 from wallabag/dependabot/composer/sentry/sentry-symfony-4.10.0
Bump sentry/sentry-symfony from 4.9.2 to 4.10.0
2023-08-03 11:26:02 +02:00
8281920f2c Merge pull request #6775 from viktoriussuwandi/issue#6772
Remove external dependencies on src/Wallabag/CoreBundle/Resources/vie…
2023-08-02 23:14:13 +02:00
d4913c50c2 Bump sentry/sentry-symfony from 4.9.2 to 4.10.0
Bumps [sentry/sentry-symfony](https://github.com/getsentry/sentry-symfony) from 4.9.2 to 4.10.0.
- [Release notes](https://github.com/getsentry/sentry-symfony/releases)
- [Changelog](https://github.com/getsentry/sentry-symfony/blob/master/CHANGELOG.md)
- [Commits](https://github.com/getsentry/sentry-symfony/compare/4.9.2...4.10.0)

---
updated-dependencies:
- dependency-name: sentry/sentry-symfony
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-08-02 02:10:33 +00:00
19d3e878cf Merge branch 'master' into issue#6772 2023-08-01 19:43:37 +07:00
c659a42c51 Merge pull request #6783 from wallabag/fix-dependencies
Update dependencies
2023-07-31 15:38:43 +02:00
cb411e8dcd Update dependencies 2023-07-31 14:58:29 +02:00
fec8a993d9 Merge pull request #6779 from wallabag/dependabot/composer/jms/serializer-3.27.0
Bump jms/serializer from 3.26.0 to 3.27.0
2023-07-31 11:46:58 +02:00
31542bc4b1 Merge branch 'master' into dependabot/composer/jms/serializer-3.27.0 2023-07-31 11:36:39 +02:00
827dded754 Merge pull request #6780 from wallabag/dependabot/composer/symfony/phpunit-bridge-6.3.2
Bump symfony/phpunit-bridge from 6.3.1 to 6.3.2
2023-07-31 11:36:18 +02:00
39bcddfd8b Merge branch 'master' into dependabot/composer/symfony/phpunit-bridge-6.3.2 2023-07-31 11:29:08 +02:00
8cfa1cd551 Merge pull request #6782 from wallabag/dependabot/npm_and_yarn/eslint-8.46.0
Bump eslint from 8.45.0 to 8.46.0
2023-07-31 02:38:17 +00:00
649e1e56a9 Bump eslint from 8.45.0 to 8.46.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.45.0 to 8.46.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.45.0...v8.46.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-31 02:33:21 +00:00
c1ed66aad5 Merge pull request #6781 from wallabag/dependabot/npm_and_yarn/eslint-plugin-import-2.28.0
Bump eslint-plugin-import from 2.27.5 to 2.28.0
2023-07-31 02:32:20 +00:00
9beadfde59 Bump eslint-plugin-import from 2.27.5 to 2.28.0
Bumps [eslint-plugin-import](https://github.com/import-js/eslint-plugin-import) from 2.27.5 to 2.28.0.
- [Release notes](https://github.com/import-js/eslint-plugin-import/releases)
- [Changelog](https://github.com/import-js/eslint-plugin-import/blob/main/CHANGELOG.md)
- [Commits](https://github.com/import-js/eslint-plugin-import/compare/v2.27.5...v2.28.0)

---
updated-dependencies:
- dependency-name: eslint-plugin-import
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-31 02:27:52 +00:00
090f873ffc Bump symfony/phpunit-bridge from 6.3.1 to 6.3.2
Bumps [symfony/phpunit-bridge](https://github.com/symfony/phpunit-bridge) from 6.3.1 to 6.3.2.
- [Release notes](https://github.com/symfony/phpunit-bridge/releases)
- [Changelog](https://github.com/symfony/phpunit-bridge/blob/6.3/CHANGELOG.md)
- [Commits](https://github.com/symfony/phpunit-bridge/compare/v6.3.1...v6.3.2)

---
updated-dependencies:
- dependency-name: symfony/phpunit-bridge
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-31 02:14:05 +00:00
1b7d756be0 Bump jms/serializer from 3.26.0 to 3.27.0
Bumps [jms/serializer](https://github.com/schmittjoh/serializer) from 3.26.0 to 3.27.0.
- [Release notes](https://github.com/schmittjoh/serializer/releases)
- [Changelog](https://github.com/schmittjoh/serializer/blob/master/CHANGELOG.md)
- [Commits](https://github.com/schmittjoh/serializer/compare/3.26.0...3.27.0)

---
updated-dependencies:
- dependency-name: jms/serializer
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-31 02:13:54 +00:00
d6f63d5d51 Add confirmation before reload entry 2023-07-30 20:07:24 +02:00
c1cba72a19 Replace hardcoded url by current wallabag url 2023-07-30 10:09:54 +02:00
e80a169435 Remove external dependencies on src/Wallabag/CoreBundle/Resources/views/Developer/howto_app.html.twig 2023-07-30 14:07:45 +07:00
911e0238b7 Merge pull request #6763 from wallabag/fix-ci
Fix failing randomly test
2023-07-27 09:02:07 +02:00
5fe5551972 Fix failing randomly test 2023-07-27 07:55:42 +02:00
90631abe46 Merge pull request #6766 from wallabag/dependabot/composer/twig/string-extra-3.7.0 2023-07-27 07:06:17 +02:00
ce88e7aaab Merge pull request #6765 from wallabag/dependabot/composer/twig/extra-bundle-3.7.0 2023-07-27 06:27:13 +02:00
a339fcd137 Bump twig/string-extra from 3.6.0 to 3.7.0
Bumps [twig/string-extra](https://github.com/twigphp/string-extra) from 3.6.0 to 3.7.0.
- [Commits](https://github.com/twigphp/string-extra/compare/v3.6.0...v3.7.0)

---
updated-dependencies:
- dependency-name: twig/string-extra
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-27 02:52:17 +00:00
f74571e750 Bump twig/extra-bundle from 3.6.1 to 3.7.0
Bumps [twig/extra-bundle](https://github.com/twigphp/twig-extra-bundle) from 3.6.1 to 3.7.0.
- [Commits](https://github.com/twigphp/twig-extra-bundle/compare/v3.6.1...v3.7.0)

---
updated-dependencies:
- dependency-name: twig/extra-bundle
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-27 02:51:31 +00:00
0f44b2b75c Merge pull request #6762 from wallabag/enhance-composer
Add composer normalizer
2023-07-26 15:25:50 +02:00
382272c51c Add composer normalizer 2023-07-26 15:12:47 +02:00
78cddcafd7 Merge pull request #6754 from wallabag/update-release
Update RELEASE_PROCESS
2023-07-24 15:37:27 +02:00
594770bdf4 Update RELEASE_PROCESS 2023-07-24 15:02:44 +02:00
2dcdb4e23c Merge pull request #6738 from wallabag/prepare-262
Prepare 2.6.2 release
2023-07-24 13:01:36 +02:00
76617f0440 Update some sub-package 2023-07-24 10:28:29 +02:00
192fa3ea2e Prepare 2.6.2 release 2023-07-24 10:28:28 +02:00
72eef910d9 Merge pull request #6751 from wallabag/dependabot/composer/doctrine/orm-2.15.4 2023-07-24 06:15:08 +02:00
8508b92f98 Merge pull request #6753 from wallabag/dependabot/composer/doctrine/dbal-3.6.5 2023-07-24 06:14:29 +02:00
839a3ddbf2 Bump doctrine/dbal from 3.6.4 to 3.6.5
Bumps [doctrine/dbal](https://github.com/doctrine/dbal) from 3.6.4 to 3.6.5.
- [Release notes](https://github.com/doctrine/dbal/releases)
- [Commits](https://github.com/doctrine/dbal/compare/3.6.4...3.6.5)

---
updated-dependencies:
- dependency-name: doctrine/dbal
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-24 02:53:24 +00:00
3904543a96 Bump doctrine/orm from 2.15.3 to 2.15.4
Bumps [doctrine/orm](https://github.com/doctrine/orm) from 2.15.3 to 2.15.4.
- [Release notes](https://github.com/doctrine/orm/releases)
- [Commits](https://github.com/doctrine/orm/compare/2.15.3...2.15.4)

---
updated-dependencies:
- dependency-name: doctrine/orm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-24 02:52:14 +00:00
af7cd960dd Merge pull request #6748 from wallabag/dependabot/npm_and_yarn/webpack-5.88.2
Bump webpack from 5.88.1 to 5.88.2
2023-07-24 02:30:51 +00:00
b58b6ca9f3 Merge pull request #6747 from wallabag/dependabot/npm_and_yarn/sass-1.64.1
Bump sass from 1.63.6 to 1.64.1
2023-07-24 02:27:52 +00:00
7098fd6193 Bump webpack from 5.88.1 to 5.88.2
Bumps [webpack](https://github.com/webpack/webpack) from 5.88.1 to 5.88.2.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.88.1...v5.88.2)

---
updated-dependencies:
- dependency-name: webpack
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-24 02:20:17 +00:00
070f5e1cf4 Bump sass from 1.63.6 to 1.64.1
Bumps [sass](https://github.com/sass/dart-sass) from 1.63.6 to 1.64.1.
- [Release notes](https://github.com/sass/dart-sass/releases)
- [Changelog](https://github.com/sass/dart-sass/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sass/dart-sass/compare/1.63.6...1.64.1)

---
updated-dependencies:
- dependency-name: sass
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-24 02:20:15 +00:00
8e05fd0a3f Merge pull request #6750 from wallabag/dependabot/npm_and_yarn/stylelint-15.10.2
Bump stylelint from 15.10.1 to 15.10.2
2023-07-24 02:19:16 +00:00
931f665bc7 Bump stylelint from 15.10.1 to 15.10.2
Bumps [stylelint](https://github.com/stylelint/stylelint) from 15.10.1 to 15.10.2.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/15.10.1...15.10.2)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-24 02:14:06 +00:00
7615a29095 Merge pull request #6749 from wallabag/dependabot/npm_and_yarn/postcss-8.4.27
Bump postcss from 8.4.26 to 8.4.27
2023-07-24 02:13:08 +00:00
1a01323002 Bump postcss from 8.4.26 to 8.4.27
Bumps [postcss](https://github.com/postcss/postcss) from 8.4.26 to 8.4.27.
- [Release notes](https://github.com/postcss/postcss/releases)
- [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/postcss/postcss/compare/8.4.26...8.4.27)

---
updated-dependencies:
- dependency-name: postcss
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-24 02:02:41 +00:00
724fea0aea Merge pull request #6745 from wallabag/impr/dockerdev
Update dev docker base image to php:8.1-fpm
2023-07-23 12:40:32 +02:00
13a3a5596c Update dev docker base image to php:8.1-fpm
Signed-off-by: Kevin Decherf <kevin@kdecherf.com>
2023-07-22 19:16:32 +02:00
e2857a1ffe Merge pull request #6744 from weblate/weblate-wallabag-messages
Translations update from Hosted Weblate
2023-07-22 14:14:35 +02:00
8c39d2aca1 Translated using Weblate (French)
Currently translated at 100.0% (581 of 581 strings)
2023-07-22 10:08:02 +02:00
8c82b42338 Merge pull request #6743 from wallabag/dependabot/composer/phpstan/phpstan-1.10.26 2023-07-20 07:06:18 +02:00
24a0ec60bf Bump phpstan/phpstan from 1.10.25 to 1.10.26
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan) from 1.10.25 to 1.10.26.
- [Release notes](https://github.com/phpstan/phpstan/releases)
- [Changelog](https://github.com/phpstan/phpstan/blob/1.11.x/CHANGELOG.md)
- [Commits](https://github.com/phpstan/phpstan/compare/1.10.25...1.10.26)

---
updated-dependencies:
- dependency-name: phpstan/phpstan
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-20 02:14:06 +00:00
fc95d812dd Merge pull request #6731 from wallabag/fix/migration-queries-debug
Add a new build to test when no database table prefix are defined
2023-07-17 15:48:01 +02:00
8b9fd04c74 Add a new build to test when no database table prefix are defined
This is mostly to avoid further error when users don't defined a database table prefix. it's recommenced to define one anyway.

Also enable verbose migration so we'll be able to actually view SQL queries (and execution time).
2023-07-17 14:21:12 +02:00
df56bfe94e Merge pull request #6710 from Glandos/patch-1
Keep escaped table name while migrating
2023-07-17 14:12:25 +02:00
11617ca7e1 Merge pull request #6723 from wallabag/remove-2fa-parameter
Remove `twofactor_auth` parameter
2023-07-17 13:39:48 +02:00
90281b8786 Merge pull request #6730 from wallabag/dependabot/npm_and_yarn/eslint-8.45.0
Bump eslint from 8.44.0 to 8.45.0
2023-07-17 03:13:50 +00:00
91b47be5a9 Bump eslint from 8.44.0 to 8.45.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.44.0 to 8.45.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.44.0...v8.45.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-17 03:08:36 +00:00
8146b4180e Merge pull request #6728 from wallabag/dependabot/npm_and_yarn/babel/core-7.22.9
Bump @babel/core from 7.22.8 to 7.22.9
2023-07-17 03:07:37 +00:00
f1fb885ca6 Bump @babel/core from 7.22.8 to 7.22.9
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.22.8 to 7.22.9.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.22.9/packages/babel-core)

---
updated-dependencies:
- dependency-name: "@babel/core"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-17 03:01:59 +00:00
cf42b834d7 Merge pull request #6729 from wallabag/dependabot/npm_and_yarn/babel/preset-env-7.22.9
Bump @babel/preset-env from 7.22.7 to 7.22.9
2023-07-17 03:01:02 +00:00
b2b2627817 Merge pull request #6727 from wallabag/dependabot/npm_and_yarn/postcss-8.4.26
Bump postcss from 8.4.25 to 8.4.26
2023-07-17 02:51:54 +00:00
8c56a40d38 Bump @babel/preset-env from 7.22.7 to 7.22.9
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.22.7 to 7.22.9.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.22.9/packages/babel-preset-env)

---
updated-dependencies:
- dependency-name: "@babel/preset-env"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-17 02:49:37 +00:00
9484f3d2ce Merge pull request #6726 from wallabag/dependabot/npm_and_yarn/babel/eslint-parser-7.22.9
Bump @babel/eslint-parser from 7.22.7 to 7.22.9
2023-07-17 02:48:28 +00:00
d835f03f15 Bump postcss from 8.4.25 to 8.4.26
Bumps [postcss](https://github.com/postcss/postcss) from 8.4.25 to 8.4.26.
- [Release notes](https://github.com/postcss/postcss/releases)
- [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/postcss/postcss/compare/8.4.25...8.4.26)

---
updated-dependencies:
- dependency-name: postcss
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-17 02:44:38 +00:00
81403edb00 Bump @babel/eslint-parser from 7.22.7 to 7.22.9
Bumps [@babel/eslint-parser](https://github.com/babel/babel/tree/HEAD/eslint/babel-eslint-parser) from 7.22.7 to 7.22.9.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.22.9/eslint/babel-eslint-parser)

---
updated-dependencies:
- dependency-name: "@babel/eslint-parser"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-17 02:44:29 +00:00
c75d3e6961 Remove twofactor_auth parameter
Fix #6649
2023-07-15 16:18:01 +02:00
2c1687ce91 Merge pull request #6685 from caspermeijn/contributing_docs
Document how to run tests and formatter for new contributors
2023-07-15 16:12:56 +02:00
5ca4df1585 Add test and formatter commands to CONTRIBUTING.md 2023-07-15 14:53:25 +02:00
241955a317 Merge pull request #6719 from wallabag/dependabot/composer/php-http/discovery-1.19.1
Bump php-http/discovery from 1.19.0 to 1.19.1
2023-07-12 19:14:02 +02:00
193953f75d Merge pull request #6713 from wallabag/dependabot/npm_and_yarn/stylelint-config-standard-34.0.0 2023-07-12 06:33:37 +02:00
c535e291d5 Bump php-http/discovery from 1.19.0 to 1.19.1
Bumps [php-http/discovery](https://github.com/php-http/discovery) from 1.19.0 to 1.19.1.
- [Release notes](https://github.com/php-http/discovery/releases)
- [Changelog](https://github.com/php-http/discovery/blob/1.x/CHANGELOG.md)
- [Commits](https://github.com/php-http/discovery/compare/1.19.0...1.19.1)

---
updated-dependencies:
- dependency-name: php-http/discovery
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-12 02:24:03 +00:00
d9b4e0791d Merge pull request #6718 from wallabag/dependabot/npm_and_yarn/semver-5.7.2
Bump semver from 5.7.1 to 5.7.2
2023-07-11 09:41:26 +00:00
edc2194ead Bump semver from 5.7.1 to 5.7.2
Bumps [semver](https://github.com/npm/node-semver) from 5.7.1 to 5.7.2.
- [Release notes](https://github.com/npm/node-semver/releases)
- [Changelog](https://github.com/npm/node-semver/blob/v5.7.2/CHANGELOG.md)
- [Commits](https://github.com/npm/node-semver/compare/v5.7.1...v5.7.2)

---
updated-dependencies:
- dependency-name: semver
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-11 09:36:22 +00:00
3d36ccf8dd Merge pull request #6714 from wallabag/dependabot/npm_and_yarn/babel/preset-env-7.22.7
Bump @babel/preset-env from 7.22.5 to 7.22.7
2023-07-10 02:55:16 +00:00
65b621da9e Bump @babel/preset-env from 7.22.5 to 7.22.7
Bumps [@babel/preset-env](https://github.com/babel/babel/tree/HEAD/packages/babel-preset-env) from 7.22.5 to 7.22.7.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.22.7/packages/babel-preset-env)

---
updated-dependencies:
- dependency-name: "@babel/preset-env"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-10 02:50:19 +00:00
0e0de8578c Merge pull request #6716 from wallabag/dependabot/npm_and_yarn/babel/eslint-parser-7.22.7
Bump @babel/eslint-parser from 7.22.5 to 7.22.7
2023-07-10 02:49:20 +00:00
2241d77304 Bump @babel/eslint-parser from 7.22.5 to 7.22.7
Bumps [@babel/eslint-parser](https://github.com/babel/babel/tree/HEAD/eslint/babel-eslint-parser) from 7.22.5 to 7.22.7.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.22.7/eslint/babel-eslint-parser)

---
updated-dependencies:
- dependency-name: "@babel/eslint-parser"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-10 02:43:03 +00:00
54e3801cfe Merge pull request #6717 from wallabag/dependabot/npm_and_yarn/babel-loader-9.1.3
Bump babel-loader from 9.1.2 to 9.1.3
2023-07-10 02:42:04 +00:00
9cc23c615a Merge pull request #6715 from wallabag/dependabot/npm_and_yarn/babel/core-7.22.8
Bump @babel/core from 7.22.5 to 7.22.8
2023-07-10 02:37:22 +00:00
80a3447d20 Merge pull request #6712 from wallabag/dependabot/npm_and_yarn/postcss-8.4.25
Bump postcss from 8.4.24 to 8.4.25
2023-07-10 02:30:14 +00:00
e07b13fd38 Bump babel-loader from 9.1.2 to 9.1.3
Bumps [babel-loader](https://github.com/babel/babel-loader) from 9.1.2 to 9.1.3.
- [Release notes](https://github.com/babel/babel-loader/releases)
- [Changelog](https://github.com/babel/babel-loader/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel-loader/compare/v9.1.2...v9.1.3)

---
updated-dependencies:
- dependency-name: babel-loader
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-10 02:27:06 +00:00
da3e9a2fb2 Bump @babel/core from 7.22.5 to 7.22.8
Bumps [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) from 7.22.5 to 7.22.8.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.22.8/packages/babel-core)

---
updated-dependencies:
- dependency-name: "@babel/core"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-10 02:26:37 +00:00
8b79bc654b Bump stylelint-config-standard from 33.0.0 to 34.0.0
Bumps [stylelint-config-standard](https://github.com/stylelint/stylelint-config-standard) from 33.0.0 to 34.0.0.
- [Release notes](https://github.com/stylelint/stylelint-config-standard/releases)
- [Changelog](https://github.com/stylelint/stylelint-config-standard/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint-config-standard/compare/33.0.0...34.0.0)

---
updated-dependencies:
- dependency-name: stylelint-config-standard
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-10 02:26:03 +00:00
f8c834db0f Bump postcss from 8.4.24 to 8.4.25
Bumps [postcss](https://github.com/postcss/postcss) from 8.4.24 to 8.4.25.
- [Release notes](https://github.com/postcss/postcss/releases)
- [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/postcss/postcss/compare/8.4.24...8.4.25)

---
updated-dependencies:
- dependency-name: postcss
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-10 02:25:46 +00:00
0596633a29 Keep escaped table name while migrating
Fix #6709
2023-07-09 15:29:50 +02:00
c8190c8a5a Merge pull request #6704 from wallabag/dependabot/npm_and_yarn/stylelint-15.10.1
Bump stylelint from 15.9.0 to 15.10.1
2023-07-07 22:39:17 +00:00
f315552825 Bump stylelint from 15.9.0 to 15.10.1
Bumps [stylelint](https://github.com/stylelint/stylelint) from 15.9.0 to 15.10.1.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/15.9.0...15.10.1)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-07 22:33:55 +00:00
a8ade4bb39 Merge pull request #6701 from wallabag/dependabot/composer/friendsofsymfony/user-bundle-3.2.1 2023-07-07 06:41:45 +02:00
530fc289f2 Merge pull request #6702 from wallabag/dependabot/composer/phpstan/phpstan-1.10.25 2023-07-07 06:40:52 +02:00
21a8d427e7 Bump phpstan/phpstan from 1.10.24 to 1.10.25
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan) from 1.10.24 to 1.10.25.
- [Release notes](https://github.com/phpstan/phpstan/releases)
- [Changelog](https://github.com/phpstan/phpstan/blob/1.11.x/CHANGELOG.md)
- [Commits](https://github.com/phpstan/phpstan/compare/1.10.24...1.10.25)

---
updated-dependencies:
- dependency-name: phpstan/phpstan
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-07 02:49:01 +00:00
1be3dc91b9 Bump friendsofsymfony/user-bundle from 3.1.0 to 3.2.1
Bumps [friendsofsymfony/user-bundle](https://github.com/FriendsOfSymfony/FOSUserBundle) from 3.1.0 to 3.2.1.
- [Release notes](https://github.com/FriendsOfSymfony/FOSUserBundle/releases)
- [Changelog](https://github.com/FriendsOfSymfony/FOSUserBundle/blob/master/Changelog.md)
- [Commits](https://github.com/FriendsOfSymfony/FOSUserBundle/compare/v3.1.0...v3.2.1)

---
updated-dependencies:
- dependency-name: friendsofsymfony/user-bundle
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-07 02:48:40 +00:00
74f8acca3e Merge pull request #6700 from wallabag/nicosomb-patch-1
Add link to wallabag ecosystem resources
2023-07-06 16:17:54 +02:00
a4d2957c54 Add link to wallabag ecosystem resources 2023-07-06 15:31:50 +02:00
112c9e1b7c Merge pull request #6697 from wallabag/dependabot/composer/phpstan/phpstan-1.10.24 2023-07-06 06:28:54 +02:00
908e44f9b9 Bump phpstan/phpstan from 1.10.23 to 1.10.24
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan) from 1.10.23 to 1.10.24.
- [Release notes](https://github.com/phpstan/phpstan/releases)
- [Changelog](https://github.com/phpstan/phpstan/blob/1.11.x/CHANGELOG.md)
- [Commits](https://github.com/phpstan/phpstan/compare/1.10.23...1.10.24)

---
updated-dependencies:
- dependency-name: phpstan/phpstan
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-06 02:35:22 +00:00
b22a6feed2 Merge pull request #6695 from wallabag/dependabot/composer/phpstan/phpstan-1.10.23 2023-07-05 06:51:16 +02:00
13a7f1bc80 Bump phpstan/phpstan from 1.10.22 to 1.10.23
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan) from 1.10.22 to 1.10.23.
- [Release notes](https://github.com/phpstan/phpstan/releases)
- [Changelog](https://github.com/phpstan/phpstan/blob/1.11.x/CHANGELOG.md)
- [Commits](https://github.com/phpstan/phpstan/compare/1.10.22...1.10.23)

---
updated-dependencies:
- dependency-name: phpstan/phpstan
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-05 02:15:59 +00:00
24887f4ad6 Merge pull request #6684 from caspermeijn/apidoc
ApiDoc: Add response description to UserRestController
2023-07-04 16:05:40 +02:00
5b1230a909 Merge pull request #6680 from wallabag/fix-export-same-domain
Fix export for same domain entries
2023-07-03 22:31:23 +02:00
31566fb6eb Merge pull request #6678 from cloudron-io/doctrine_migration_fix
Skip migration if the table was already renamed
2023-07-03 09:58:12 +02:00
183c5248f3 Merge pull request #6689 from wallabag/dependabot/npm_and_yarn/stylelint-config-standard-scss-10.0.0 2023-07-03 08:27:54 +02:00
738ff474a6 Merge pull request #6690 from wallabag/dependabot/composer/php-amqplib/php-amqplib-3.5.4 2023-07-03 08:27:38 +02:00
81022c3089 Merge pull request #6691 from wallabag/dependabot/composer/phpstan/phpstan-1.10.22 2023-07-03 07:24:21 +02:00
2486f42c09 Merge pull request #6692 from wallabag/dependabot/github_actions/dependabot/fetch-metadata-1.6.0 2023-07-03 07:24:05 +02:00
4fc21d08f2 Bump dependabot/fetch-metadata from 1.5.1 to 1.6.0
Bumps [dependabot/fetch-metadata](https://github.com/dependabot/fetch-metadata) from 1.5.1 to 1.6.0.
- [Release notes](https://github.com/dependabot/fetch-metadata/releases)
- [Commits](https://github.com/dependabot/fetch-metadata/compare/v1.5.1...v1.6.0)

---
updated-dependencies:
- dependency-name: dependabot/fetch-metadata
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 02:28:14 +00:00
8814eaa03b Merge pull request #6688 from wallabag/dependabot/npm_and_yarn/webpack-5.88.1
Bump webpack from 5.88.0 to 5.88.1
2023-07-03 02:18:26 +00:00
303cdffe36 Bump webpack from 5.88.0 to 5.88.1
Bumps [webpack](https://github.com/webpack/webpack) from 5.88.0 to 5.88.1.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.88.0...v5.88.1)

---
updated-dependencies:
- dependency-name: webpack
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 02:07:17 +00:00
27b7ce9479 Bump phpstan/phpstan from 1.10.21 to 1.10.22
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan) from 1.10.21 to 1.10.22.
- [Release notes](https://github.com/phpstan/phpstan/releases)
- [Changelog](https://github.com/phpstan/phpstan/blob/1.11.x/CHANGELOG.md)
- [Commits](https://github.com/phpstan/phpstan/compare/1.10.21...1.10.22)

---
updated-dependencies:
- dependency-name: phpstan/phpstan
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 02:06:47 +00:00
39bed07622 Merge pull request #6687 from wallabag/dependabot/npm_and_yarn/eslint-8.44.0
Bump eslint from 8.43.0 to 8.44.0
2023-07-03 02:06:20 +00:00
cb1082904b Bump php-amqplib/php-amqplib from 3.5.3 to 3.5.4
Bumps [php-amqplib/php-amqplib](https://github.com/php-amqplib/php-amqplib) from 3.5.3 to 3.5.4.
- [Release notes](https://github.com/php-amqplib/php-amqplib/releases)
- [Changelog](https://github.com/php-amqplib/php-amqplib/blob/master/CHANGELOG.md)
- [Commits](https://github.com/php-amqplib/php-amqplib/compare/v3.5.3...v3.5.4)

---
updated-dependencies:
- dependency-name: php-amqplib/php-amqplib
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 02:06:05 +00:00
ee5de3b491 Bump stylelint-config-standard-scss from 9.0.0 to 10.0.0
Bumps [stylelint-config-standard-scss](https://github.com/stylelint-scss/stylelint-config-standard-scss) from 9.0.0 to 10.0.0.
- [Release notes](https://github.com/stylelint-scss/stylelint-config-standard-scss/releases)
- [Changelog](https://github.com/stylelint-scss/stylelint-config-standard-scss/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint-scss/stylelint-config-standard-scss/compare/v9.0.0...v10.0.0)

---
updated-dependencies:
- dependency-name: stylelint-config-standard-scss
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 02:02:05 +00:00
5acab2b264 Bump eslint from 8.43.0 to 8.44.0
Bumps [eslint](https://github.com/eslint/eslint) from 8.43.0 to 8.44.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v8.43.0...v8.44.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-07-03 02:01:42 +00:00
4c797162bf ApiDoc: Add response description to UserRestController 2023-07-02 08:31:11 +02:00
0a6826cb4c Merge pull request #6683 from wallabag/dependabot/composer/stof/doctrine-extensions-bundle-1.7.2 2023-06-30 07:28:53 +02:00
49e81d8952 Bump stof/doctrine-extensions-bundle from 1.7.1 to 1.7.2
Bumps [stof/doctrine-extensions-bundle](https://github.com/stof/StofDoctrineExtensionsBundle) from 1.7.1 to 1.7.2.
- [Release notes](https://github.com/stof/StofDoctrineExtensionsBundle/releases)
- [Changelog](https://github.com/stof/StofDoctrineExtensionsBundle/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stof/StofDoctrineExtensionsBundle/compare/v1.7.1...v1.7.2)

---
updated-dependencies:
- dependency-name: stof/doctrine-extensions-bundle
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-30 02:20:04 +00:00
4af2abf0b7 Merge pull request #6682 from wallabag/remove-useless-directory
Remove empty file
2023-06-29 21:39:04 +02:00
84bbeed4f0 Remove empty file 2023-06-29 21:27:45 +02:00
6639f7da6d Fix export for same domain entries 2023-06-29 19:59:08 +02:00
131ef532c7 Skip migration if the table was already renamed
Doctrine 3.5 reruns skipped migrations when invoking doctrine:migrations:migrate.
This causes this migration to rerun and it errors since craue_config_setting table
gets renamed in Version20190808124957.php to internal_setting table.

Fixes #6660
2023-06-28 21:50:46 +05:30
dc02c679d2 Merge pull request #6102 from caspermeijn/apidoc
ApiDoc: Add response description to WallabagRestController
2023-06-28 11:02:07 +02:00
0fff56ea68 ApiDoc: Add response description to WallabagRestController 2023-06-27 20:59:43 +02:00
e9054bbd41 Merge pull request #6675 from wallabag/dependabot/composer/symfony/phpunit-bridge-6.3.1 2023-06-27 06:17:59 +02:00
36c3a7d505 Bump symfony/phpunit-bridge from 6.3.0 to 6.3.1
Bumps [symfony/phpunit-bridge](https://github.com/symfony/phpunit-bridge) from 6.3.0 to 6.3.1.
- [Release notes](https://github.com/symfony/phpunit-bridge/releases)
- [Changelog](https://github.com/symfony/phpunit-bridge/blob/6.2/CHANGELOG.md)
- [Commits](https://github.com/symfony/phpunit-bridge/compare/v6.3.0...v6.3.1)

---
updated-dependencies:
- dependency-name: symfony/phpunit-bridge
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-27 02:57:28 +00:00
05c04cc509 Merge pull request #6674 from weblate/weblate-wallabag-messages
Translations update from Hosted Weblate
2023-06-26 23:08:55 +02:00
2e3ca273c8 Translated using Weblate (Croatian)
Currently translated at 100.0% (581 of 581 strings)
2023-06-26 22:52:50 +02:00
bc8c7cd7ca Merge pull request #6673 from Simounet/fix/6664-mass-action-dark-theme
Fix #6664 mass action input on dark theme
2023-06-26 22:46:51 +02:00
513337c1fa Fix 6664 mass action input on dark theme 2023-06-26 22:34:57 +02:00
103386c66a Merge pull request #6672 from wallabag/nicosomb-patch-1
Fix undefined variable
2023-06-26 20:09:10 +02:00
74848a4794 Fix undefined variable 2023-06-26 17:41:55 +02:00
32c901f7cd Merge pull request #6668 from wallabag/dependabot/composer/doctrine/dbal-3.6.4 2023-06-26 06:28:30 +02:00
1d9709db08 Merge pull request #6669 from wallabag/dependabot/composer/jms/serializer-3.26.0 2023-06-26 06:28:15 +02:00
5905b0c12f Merge pull request #6665 from wallabag/dependabot/npm_and_yarn/webpack-5.88.0
Bump webpack from 5.87.0 to 5.88.0
2023-06-26 03:16:19 +00:00
e776c9bc9d Bump webpack from 5.87.0 to 5.88.0
Bumps [webpack](https://github.com/webpack/webpack) from 5.87.0 to 5.88.0.
- [Release notes](https://github.com/webpack/webpack/releases)
- [Commits](https://github.com/webpack/webpack/compare/v5.87.0...v5.88.0)

---
updated-dependencies:
- dependency-name: webpack
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 03:07:14 +00:00
3a691e8ddd Merge pull request #6667 from wallabag/dependabot/npm_and_yarn/sass-1.63.6
Bump sass from 1.63.4 to 1.63.6
2023-06-26 03:05:53 +00:00
dc36da99c0 Merge pull request #6666 from wallabag/dependabot/npm_and_yarn/stylelint-15.9.0
Bump stylelint from 15.8.0 to 15.9.0
2023-06-26 03:03:31 +00:00
b05464ffd1 Bump jms/serializer from 3.25.0 to 3.26.0
Bumps [jms/serializer](https://github.com/schmittjoh/serializer) from 3.25.0 to 3.26.0.
- [Release notes](https://github.com/schmittjoh/serializer/releases)
- [Changelog](https://github.com/schmittjoh/serializer/blob/master/CHANGELOG.md)
- [Commits](https://github.com/schmittjoh/serializer/compare/3.25.0...3.26.0)

---
updated-dependencies:
- dependency-name: jms/serializer
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 02:58:57 +00:00
28d3a5655c Bump doctrine/dbal from 3.6.3 to 3.6.4
Bumps [doctrine/dbal](https://github.com/doctrine/dbal) from 3.6.3 to 3.6.4.
- [Release notes](https://github.com/doctrine/dbal/releases)
- [Commits](https://github.com/doctrine/dbal/compare/3.6.3...3.6.4)

---
updated-dependencies:
- dependency-name: doctrine/dbal
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 02:58:04 +00:00
696ee80de7 Bump sass from 1.63.4 to 1.63.6
Bumps [sass](https://github.com/sass/dart-sass) from 1.63.4 to 1.63.6.
- [Release notes](https://github.com/sass/dart-sass/releases)
- [Changelog](https://github.com/sass/dart-sass/blob/main/CHANGELOG.md)
- [Commits](https://github.com/sass/dart-sass/compare/1.63.4...1.63.6)

---
updated-dependencies:
- dependency-name: sass
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 02:57:36 +00:00
8bf4222bdb Bump stylelint from 15.8.0 to 15.9.0
Bumps [stylelint](https://github.com/stylelint/stylelint) from 15.8.0 to 15.9.0.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/15.8.0...15.9.0)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 02:57:20 +00:00
f58c656a08 Merge pull request #6658 from weblate/weblate-wallabag-messages
Translations update from Hosted Weblate
2023-06-23 15:49:24 +02:00
391f346cc3 Translated using Weblate (Galician)
Currently translated at 100.0% (581 of 581 strings)
2023-06-23 13:50:08 +02:00
6c3118951b Translated using Weblate (Occitan)
Currently translated at 100.0% (581 of 581 strings)
2023-06-23 13:50:08 +02:00
c833141942 Merge pull request #6661 from wallabag/dependabot/composer/doctrine/orm-2.15.3 2023-06-23 06:25:01 +02:00
4f162fff64 Bump doctrine/orm from 2.15.2 to 2.15.3
Bumps [doctrine/orm](https://github.com/doctrine/orm) from 2.15.2 to 2.15.3.
- [Release notes](https://github.com/doctrine/orm/releases)
- [Commits](https://github.com/doctrine/orm/compare/2.15.2...2.15.3)

---
updated-dependencies:
- dependency-name: doctrine/orm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-23 02:57:27 +00:00
1413772bca Merge pull request #6657 from wallabag/dependabot/composer/phpstan/phpstan-1.10.21 2023-06-22 06:16:14 +02:00
bf59e8aad3 Bump phpstan/phpstan from 1.10.20 to 1.10.21
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan) from 1.10.20 to 1.10.21.
- [Release notes](https://github.com/phpstan/phpstan/releases)
- [Changelog](https://github.com/phpstan/phpstan/blob/1.11.x/CHANGELOG.md)
- [Commits](https://github.com/phpstan/phpstan/compare/1.10.20...1.10.21)

---
updated-dependencies:
- dependency-name: phpstan/phpstan
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-22 03:02:14 +00:00
d33e3d64d2 Merge pull request #6653 from wallabag/fix-migrations
Fix table name in migration
2023-06-21 14:06:10 +02:00
a6c78f0039 Fix table name in migration 2023-06-21 11:34:08 +02:00
97fee36fa6 Update src/Wallabag/CoreBundle/Controller/TagController.php
Co-authored-by: Jérémy Benoist <j0k3r@users.noreply.github.com>
2022-12-23 11:03:25 -06:00
fbccae8a79 fix: update remove tag test to accept root relative urls 2022-12-10 11:52:18 -06:00
13bd448e01 feat: use session instead of referer for redirects 2022-12-04 16:20:11 -06:00
107 changed files with 6636 additions and 1812 deletions

View File

@ -45,3 +45,17 @@ Note : If you have large portions of text, use [Github's Gist service](https://g
## You want to fix a bug or to add a feature
Please fork wallabag and work with **the master branch**.
## Run Tests and PHP formatter
All pull requests need to pass the tests and the code needs match the style guide.
To run the tests locally run:
- when testing using Docker: `docker-compose run --rm php make test`
- otherwise: `make test`
To run the PHP formatter:
- when testing using Docker: `docker-compose run --rm php bin/php-cs-fixer fix`
- otherwise: `php bin/php-cs-fixer fix`

View File

@ -49,3 +49,6 @@ jobs:
- name: "Run TwigCS"
run: "php bin/twigcs --severity=error --display=blocking --reporter checkstyle app/ src/ | cs2pr"
- name: "Run ergebnis/composer-normalize"
run: "composer normalize --dry-run --no-check-lock"

View File

@ -80,3 +80,74 @@ jobs:
- name: "Run PHPUnit"
run: "php bin/simple-phpunit -v"
phpunit_no_prefix:
name: "PHP ${{ matrix.php }} using ${{ matrix.database }} without prefix"
runs-on: "ubuntu-20.04"
services:
rabbitmq:
image: rabbitmq:3-alpine
ports:
- 5672:5672
redis:
image: redis:6-alpine
ports:
- 6379:6379
strategy:
fail-fast: true
matrix:
php:
- "8.2"
database:
- "sqlite"
- "mysql"
- "pgsql"
steps:
- name: "Checkout"
uses: "actions/checkout@v3"
with:
fetch-depth: 2
- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
with:
php-version: "${{ matrix.php }}"
coverage: none
tools: pecl
extensions: json, pdo, pdo_mysql, pdo_sqlite, pdo_pgsql, curl, imagick, pgsql, gd, tidy
ini-values: "date.timezone=Europe/Paris"
- name: "Remove database prefix"
run: |
pip install --user yq
yq -Y --in-place '.parameters.database_table_prefix = ""' app/config/parameters.yml.dist
- name: "Setup MySQL"
if: "${{ matrix.database == 'mysql' }}"
run: |
sudo systemctl start mysql.service
sudo mysql -u root -proot -h 127.0.0.1 -e "CREATE DATABASE wallabag_test"
- name: "Setup PostgreSQL"
if: "${{ matrix.database == 'pgsql' }}"
run: |
sudo systemctl start postgresql
sudo -u postgres psql -d template1 -c "CREATE USER wallabag WITH PASSWORD 'wallabagrocks' CREATEDB"
createdb -h localhost -p 5432 -U wallabag wallabag_test
pg_isready -d wallabag_test -h localhost -p 5432 -U wallabag
- name: "Install dependencies with Composer"
uses: "ramsey/composer-install@v2"
with:
composer-options: "--optimize-autoloader --prefer-dist"
- name: "Prepare database"
run: "make prepare DB=${{ matrix.database }}"
- name: "Prepare fixtures"
run: "make fixtures"
- name: "Run PHPUnit"
run: "php bin/simple-phpunit -v"

View File

@ -12,7 +12,7 @@ jobs:
steps:
- name: Dependabot metadata
id: metadata
uses: dependabot/fetch-metadata@v1.5.1
uses: dependabot/fetch-metadata@v1.6.0
with:
github-token: '${{ secrets.GITHUB_TOKEN }}'
- name: Approve and merge minor updates

1
.gitignore vendored
View File

@ -15,6 +15,7 @@
.php-cs-fixer.cache
.phpunit.result.cache
phpunit.xml
docker-compose.override.yml
# Parameters
/app/config/parameters.yml

View File

@ -1,5 +1,59 @@
# Changelog
## [2.6.3](https://github.com/wallabag/wallabag/tree/2.6.3)
[Full Changelog](https://github.com/wallabag/wallabag/compare/2.6.2...2.6.3)
### Security fixes
* Replace GET way to POST way to reset data user by @nicosomb https://github.com/wallabag/wallabag/commit/78b0b55c40511e1f22d5bbb4897aa10fca68441c
* Replace GET way to POST way to delete API client by @nicosomb https://github.com/wallabag/wallabag/commit/ffcc5c9062fcc8cd922d7d6d65edbe5efae96806
### Improvement
* Add confirmation before reload entry by @nicosomb https://github.com/wallabag/wallabag/pull/6778
* Remove external dependencies on howto page by @viktoriussuwandi https://github.com/wallabag/wallabag/pull/6775
### Fixes
* Use Session instead of Referrer for Redirection by @Spoons https://github.com/wallabag/wallabag/pull/6119
* Reduce risk of collision for #content by @kdecherf https://github.com/wallabag/wallabag/pull/6829
* Update dependencies to fix vulnerabilities by @nicosomb https://github.com/wallabag/wallabag/pull/6783
* Fix failing randomly test by @nicosomb https://github.com/wallabag/wallabag/pull/6763
### Technical stuff
* Add check if git is installed by @nicosomb https://github.com/wallabag/wallabag/pull/6788
* Replace kernel.root_dir by kernel.project_dir by @yguedidi https://github.com/wallabag/wallabag/pull/6809
* Split symfony/symfony by @yguedidi https://github.com/wallabag/wallabag/pull/6817
* Make Crawler::extract get an array by @yguedidi https://github.com/wallabag/wallabag/pull/6812
* Use PSR-17 and PSR-18 by @yguedidi https://github.com/wallabag/wallabag/pull/6816
* Replace Client by KernelBrowser by @yguedidi https://github.com/wallabag/wallabag/pull/6813
* Replace Debug component by ErrorHandler component by @yguedidi https://github.com/wallabag/wallabag/pull/6810
* Make ImportController extends AbstractController by @yguedidi https://github.com/wallabag/wallabag/pull/6808
* Use Twig instead of templating by @yguedidi https://github.com/wallabag/wallabag/pull/6797
* Identify platforms by their class by @yguedidi https://github.com/wallabag/wallabag/pull/6799
* Move from transchoice to trans by @yguedidi https://github.com/wallabag/wallabag/pull/6800
* Replace GetResponseEvent by RequestEvent by @yguedidi https://github.com/wallabag/wallabag/pull/6811
* Ensure the kernel is shut down before calling createClient by @yguedidi https://github.com/wallabag/wallabag/pull/6803
* Ignore docker-compose.override.yml by @yguedidi https://github.com/wallabag/wallabag/pull/6814
* Add composer normalizer by @nicosomb https://github.com/wallabag/wallabag/pull/6762
## [2.6.2](https://github.com/wallabag/wallabag/tree/2.6.2)
[Full Changelog](https://github.com/wallabag/wallabag/compare/2.6.1...2.6.2)
### Fixes
* Fix mass action input on dark theme by @simounet https://github.com/wallabag/wallabag/pull/6673
* Fix undefined variable by @nicosomb https://github.com/wallabag/wallabag/pull/6672
* Fix table name in migration by @nicosomb https://github.com/wallabag/wallabag/pull/6653
### Technical stuff
* Add a new build to test when no database table prefix are defined by @j0k3r https://github.com/wallabag/wallabag/pull/6731
* Keep escaped table name while migrating by @Glandos https://github.com/wallabag/wallabag/pull/6710
* Remove twofactor_auth parameter by @nicosomb https://github.com/wallabag/wallabag/pull/6723
* ApiDoc: Add response description to UserRestController by @caspermeijn https://github.com/wallabag/wallabag/pull/6684
* ApiDoc: Add response description to WallabagRestController by @caspermeijn https://github.com/wallabag/wallabag/pull/6102
* Skip migration if the table was already renamed by @gramakri https://github.com/wallabag/wallabag/pull/6678
### Meta
* Document how to run tests and formatter for new contributors by @caspermeijn https://github.com/wallabag/wallabag/pull/6685
* Add link to wallabag ecosystem resources by @nicosomb https://github.com/wallabag/wallabag/pull/6700
## [2.6.1](https://github.com/wallabag/wallabag/tree/2.6.1)
[Full Changelog](https://github.com/wallabag/wallabag/compare/2.6.0...2.6.1)

View File

@ -40,7 +40,7 @@ ifdef DB
endif
-php bin/console doctrine:database:drop --force --env=test
php bin/console doctrine:database:create --env=test
php bin/console doctrine:migrations:migrate --no-interaction --env=test
php bin/console doctrine:migrations:migrate --no-interaction --env=test -vv
fixtures: ## Load fixtures into database
php bin/console doctrine:fixtures:load --no-interaction --env=test

View File

@ -18,6 +18,7 @@ You can install it on your own server, or you can create an account on [wallabag
* iOS app: [wallabag/ios-app](https://github.com/wallabag/ios-app)
* Browser extension: [wallabag/wallabagger](https://github.com/wallabag/wallabagger)
* GNOME (Linux) app: [read-it-later](https://gitlab.gnome.org/World/read-it-later) (not maintained by this project)
* All resources about wallabag ecosystem are listed here: https://github.com/wallabag/wallabag/wiki/wallabag-ecosystem
## Documentation

View File

@ -17,9 +17,8 @@ During this documentation, we assume the release is `$LAST_WALLABAG_RELEASE` (li
#### Create a new release on GitHub
- [Create the new release on GitHub](https://github.com/wallabag/wallabag/releases/new) by targetting the `master` branch or any appropriate branch (for instance backports).
- Update [website](https://github.com/wallabag/website) to change the redirect rule for `/latest-v2-package` & `/latest-v2`. They both should redirect to the asset of the GitHub release.
- Update [website](https://github.com/wallabag/website) to change MD5 sum and create the release blog post (based on the changelog).
- Update Dockerfile https://github.com/wallabag/docker (and create a new tag)
- Update [website](https://github.com/wallabag/website) website (downloads, MD5 sum, releases and new blog post)
- Put the next patch version suffixed with `-dev` in `app/config/wallabag.yml` (`wallabag_core.version`)
- Drink a :beer:!

View File

@ -62,11 +62,6 @@ class AppKernel extends Kernel
return $bundles;
}
public function getRootDir()
{
return __DIR__;
}
public function getCacheDir()
{
return dirname(__DIR__) . '/var/cache/' . $this->getEnvironment();
@ -79,7 +74,7 @@ class AppKernel extends Kernel
public function registerContainerConfiguration(LoaderInterface $loader)
{
$loader->load($this->getRootDir() . '/config/config_' . $this->getEnvironment() . '.yml');
$loader->load($this->getProjectDir() . '/app/config/config_' . $this->getEnvironment() . '.yml');
$loader->load(function ($container) {
if ($container->getParameter('use_webpack_dev_server')) {

View File

@ -2,6 +2,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -14,8 +17,10 @@ class Version20160401000000 extends WallabagMigration
{
$this->skipIf($schema->hasTable($this->getTable('entry')), 'Database already initialized');
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$sql = <<<SQL
CREATE TABLE {$this->getTable('craue_config_setting')} (name VARCHAR(255) NOT NULL, value VARCHAR(255) DEFAULT NULL, section VARCHAR(255) DEFAULT NULL, PRIMARY KEY(name));
CREATE UNIQUE INDEX UNIQ_5D9649505E237E06 ON {$this->getTable('craue_config_setting')} (name);
@ -58,7 +63,7 @@ SQL
}
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$sql = <<<SQL
CREATE TABLE {$this->getTable('craue_config_setting')} (name VARCHAR(255) NOT NULL, value VARCHAR(255) DEFAULT NULL, section VARCHAR(255) DEFAULT NULL, UNIQUE INDEX UNIQ_5D9649505E237E06 (name), PRIMARY KEY(name)) DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci ENGINE = InnoDB;
CREATE TABLE {$this->getTable('entry')} (id INT AUTO_INCREMENT NOT NULL, user_id INT DEFAULT NULL, title LONGTEXT DEFAULT NULL, url LONGTEXT DEFAULT NULL, is_archived TINYINT(1) NOT NULL, is_starred TINYINT(1) NOT NULL, content LONGTEXT DEFAULT NULL, created_at DATETIME NOT NULL, updated_at DATETIME NOT NULL, mimetype LONGTEXT DEFAULT NULL, language LONGTEXT DEFAULT NULL, reading_time INT DEFAULT NULL, domain_name LONGTEXT DEFAULT NULL, preview_picture LONGTEXT DEFAULT NULL, is_public TINYINT(1) DEFAULT '0', INDEX IDX_F4D18282A76ED395 (user_id), PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci ENGINE = InnoDB;
@ -91,7 +96,7 @@ SQL
$this->addSql($query);
}
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$sql = <<<SQL
CREATE TABLE {$this->getTable('craue_config_setting')} (name VARCHAR(255) NOT NULL, value VARCHAR(255) DEFAULT NULL, section VARCHAR(255) DEFAULT NULL, PRIMARY KEY(name));
CREATE UNIQUE INDEX UNIQ_5D9649505E237E06 ON {$this->getTable('craue_config_setting')} (name);

View File

@ -2,6 +2,7 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -15,7 +16,7 @@ class Version20160812120952 extends WallabagMigration
$clientsTable = $schema->getTable($this->getTable('oauth2_clients'));
$this->skipIf($clientsTable->hasColumn('name'), 'It seems that you already played this migration.');
if ('sqlite' === $this->connection->getDatabasePlatform()->getName()) {
if ($this->connection->getDatabasePlatform() instanceof SqlitePlatform) {
// Can't use $clientsTable->addColumn('name', 'blob');
// because of the error:
// SQLSTATE[HY000]: General error: 1 Cannot add a NOT NULL column with default value NULL
@ -35,7 +36,7 @@ class Version20160812120952 extends WallabagMigration
{
$clientsTable = $schema->getTable($this->getTable('oauth2_clients'));
if ('sqlite' === $this->connection->getDatabasePlatform()->getName()) {
if ($this->connection->getDatabasePlatform() instanceof SqlitePlatform) {
$databaseTablePrefix = $this->container->getParameter('database_table_prefix');
$this->addSql('DROP INDEX IDX_635D765EA76ED395');
$this->addSql('CREATE TEMPORARY TABLE __temp__' . $databaseTablePrefix . 'oauth2_clients AS SELECT id, random_id, redirect_uris, secret, allowed_grant_types FROM ' . $databaseTablePrefix . 'oauth2_clients');

View File

@ -3,6 +3,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Migrations\SkipMigrationException;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -13,11 +16,13 @@ class Version20161001072726 extends WallabagMigration
{
public function up(Schema $schema): void
{
$this->skipIf('sqlite' === $this->connection->getDatabasePlatform()->getName(), 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
$platform = $this->connection->getDatabasePlatform();
$this->skipIf($platform instanceof SqlitePlatform, 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
// remove all FK from entry_tag
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'mysql':
switch (true) {
case $platform instanceof MySQLPlatform:
$query = $this->connection->query("
SELECT CONSTRAINT_NAME
FROM information_schema.key_column_usage
@ -29,7 +34,7 @@ class Version20161001072726 extends WallabagMigration
$this->addSql('ALTER TABLE ' . $this->getTable('entry_tag') . ' DROP FOREIGN KEY ' . $fk['CONSTRAINT_NAME']);
}
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
// http://dba.stackexchange.com/questions/36979/retrieving-all-pk-and-fk
$query = $this->connection->query("
SELECT conrelid::regclass AS table_from
@ -53,8 +58,8 @@ class Version20161001072726 extends WallabagMigration
// remove entry FK from annotation
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'mysql':
switch (true) {
case $platform instanceof MySQLPlatform:
$query = $this->connection->query("
SELECT CONSTRAINT_NAME
FROM information_schema.key_column_usage
@ -68,7 +73,7 @@ class Version20161001072726 extends WallabagMigration
$this->addSql('ALTER TABLE ' . $this->getTable('annotation') . ' DROP FOREIGN KEY ' . $fk['CONSTRAINT_NAME']);
}
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
// http://dba.stackexchange.com/questions/36979/retrieving-all-pk-and-fk
$query = $this->connection->query("
SELECT conrelid::regclass AS table_from

View File

@ -2,6 +2,7 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -12,7 +13,7 @@ class Version20161022134138 extends WallabagMigration
{
public function up(Schema $schema): void
{
$this->skipIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'This migration only apply to MySQL');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof MySQLPlatform, 'This migration only apply to MySQL');
$this->addSql('ALTER DATABASE `' . $this->connection->getParams()['dbname'] . '` CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci;');
@ -40,7 +41,7 @@ class Version20161022134138 extends WallabagMigration
public function down(Schema $schema): void
{
$this->skipIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'This migration only apply to MySQL');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof MySQLPlatform, 'This migration only apply to MySQL');
$this->addSql('ALTER DATABASE `' . $this->connection->getParams()['dbname'] . '` CHARACTER SET = utf8 COLLATE = utf8_unicode_ci;');

View File

@ -2,6 +2,7 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -37,7 +38,7 @@ class Version20161024212538 extends WallabagMigration
$clientsTable->dropColumn('user_id', 'integer');
if ('sqlite' !== $this->connection->getDatabasePlatform()->getName()) {
if (!$this->connection->getDatabasePlatform() instanceof SqlitePlatform) {
$clientsTable->removeForeignKey($this->constraintName);
}
}

View File

@ -2,6 +2,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -16,18 +19,20 @@ class Version20161214094402 extends WallabagMigration
$this->skipIf($entryTable->hasColumn('uid'), 'It seems that you already played this migration.');
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('CREATE TEMPORARY TABLE __temp__wallabag_entry AS SELECT id, user_id, uuid, title, url, is_archived, is_starred, content, created_at, updated_at, mimetype, language, reading_time, domain_name, preview_picture, is_public FROM ' . $this->getTable('entry'));
$this->addSql('DROP TABLE ' . $this->getTable('entry'));
$this->addSql('CREATE TABLE ' . $this->getTable('entry') . ' (id INTEGER NOT NULL, user_id INTEGER DEFAULT NULL, uid CLOB DEFAULT NULL COLLATE BINARY, title CLOB DEFAULT NULL COLLATE BINARY, url CLOB DEFAULT NULL COLLATE BINARY, is_archived BOOLEAN NOT NULL, is_starred BOOLEAN NOT NULL, content CLOB DEFAULT NULL COLLATE BINARY, created_at DATETIME NOT NULL, updated_at DATETIME NOT NULL, mimetype CLOB DEFAULT NULL COLLATE BINARY, language CLOB DEFAULT NULL COLLATE BINARY, reading_time INTEGER DEFAULT NULL, domain_name CLOB DEFAULT NULL COLLATE BINARY, preview_picture CLOB DEFAULT NULL COLLATE BINARY, is_public BOOLEAN DEFAULT "0", PRIMARY KEY(id));');
$this->addSql('INSERT INTO ' . $this->getTable('entry') . ' (id, user_id, uid, title, url, is_archived, is_starred, content, created_at, updated_at, mimetype, language, reading_time, domain_name, preview_picture, is_public) SELECT id, user_id, uuid, title, url, is_archived, is_starred, content, created_at, updated_at, mimetype, language, reading_time, domain_name, preview_picture, is_public FROM __temp__wallabag_entry;');
$this->addSql('DROP TABLE __temp__wallabag_entry');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' CHANGE uuid uid VARCHAR(23)');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' RENAME uuid TO uid');
}
}
@ -38,14 +43,16 @@ class Version20161214094402 extends WallabagMigration
$this->skipIf($entryTable->hasColumn('uuid'), 'It seems that you already played this migration.');
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
throw new SkipMigrationException('Too complex ...');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' CHANGE uid uuid VARCHAR(23)');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' RENAME uid TO uuid');
}
}

View File

@ -2,6 +2,7 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -25,7 +26,7 @@ class Version20170501115751 extends WallabagMigration
$table->setPrimaryKey(['id']);
$table->addForeignKeyConstraint($this->getTable('user'), ['user_id'], ['id'], [], 'fk_user');
if ('postgresql' === $this->connection->getDatabasePlatform()->getName()) {
if ($this->connection->getDatabasePlatform() instanceof PostgreSQLPlatform) {
$schema->dropSequence('site_credential_id_seq');
$schema->createSequence('site_credential_id_seq');
}

View File

@ -2,6 +2,7 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -19,7 +20,7 @@ class Version20170510082609 extends WallabagMigration
public function up(Schema $schema): void
{
$this->skipIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'This migration only apply to MySQL');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof MySQLPlatform, 'This migration only apply to MySQL');
foreach ($this->fields as $field) {
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' CHANGE ' . $field . ' ' . $field . ' VARCHAR(180) NOT NULL;');
@ -28,7 +29,7 @@ class Version20170510082609 extends WallabagMigration
public function down(Schema $schema): void
{
$this->skipIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'This migration only apply to MySQL');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof MySQLPlatform, 'This migration only apply to MySQL');
foreach ($this->fields as $field) {
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' CHANGE ' . $field . ' ' . $field . ' VARCHAR(255) NOT NULL;');

View File

@ -3,6 +3,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Migrations\SkipMigrationException;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -13,8 +16,10 @@ class Version20170511211659 extends WallabagMigration
{
public function up(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$annotationTableName = $this->getTable('annotation', true);
$userTableName = $this->getTable('user', true);
$entryTableName = $this->getTable('entry', true);
@ -53,10 +58,10 @@ EOD
);
$this->addSql('DROP TABLE __temp__wallabag_annotation');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('annotation') . ' MODIFY quote TEXT NOT NULL');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('annotation') . ' ALTER COLUMN quote TYPE TEXT');
break;
}
@ -66,14 +71,16 @@ EOD
{
$tableName = $this->getTable('annotation');
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
throw new SkipMigrationException('Too complex ...');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $tableName . ' MODIFY quote VARCHAR(255) NOT NULL');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $tableName . ' ALTER COLUMN quote TYPE VARCHAR(255)');
break;
}

View File

@ -13,6 +13,8 @@ class Version20170606155640 extends WallabagMigration
{
public function up(Schema $schema): void
{
$this->skipIf(!$schema->hasTable($this->getTable('craue_config_setting')), 'Table already renamed');
$apiUserRegistration = $this->container
->get('doctrine.orm.default_entity_manager')
->getConnection()

View File

@ -2,6 +2,7 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -12,7 +13,7 @@ class Version20170719231144 extends WallabagMigration
{
public function up(Schema $schema): void
{
$this->skipIf('sqlite' === $this->connection->getDatabasePlatform()->getName(), 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
$this->skipIf($this->connection->getDatabasePlatform() instanceof SqlitePlatform, 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
// Find tags which need to be merged
$dupTags = $this->connection->query('

View File

@ -2,6 +2,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -12,14 +15,16 @@ class Version20171008195606 extends WallabagMigration
{
public function up(Schema $schema): void
{
$this->skipIf('sqlite' === $this->connection->getDatabasePlatform()->getName(), 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
$platform = $this->connection->getDatabasePlatform();
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'mysql':
$this->skipIf($platform instanceof SqlitePlatform, 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
switch (true) {
case $platform instanceof MySQLPlatform:
$this->addSql('UPDATE ' . $this->getTable('entry') . ' SET reading_time = 0 WHERE reading_time IS NULL;');
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' CHANGE reading_time reading_time INT(11) NOT NULL;');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('UPDATE ' . $this->getTable('entry') . ' SET reading_time = 0 WHERE reading_time IS NULL;');
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' ALTER COLUMN reading_time SET NOT NULL;');
break;
@ -28,13 +33,15 @@ class Version20171008195606 extends WallabagMigration
public function down(Schema $schema): void
{
$this->skipIf('sqlite' === $this->connection->getDatabasePlatform()->getName(), 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
$platform = $this->connection->getDatabasePlatform();
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'mysql':
$this->skipIf($platform instanceof SqlitePlatform, 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
switch (true) {
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' CHANGE reading_time reading_time INT(11);');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' ALTER COLUMN reading_time DROP NOT NULL;');
break;
}

View File

@ -2,6 +2,7 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -12,7 +13,7 @@ class Version20181128203230 extends WallabagMigration
{
public function up(Schema $schema): void
{
$this->skipIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'This migration can only be applied on \'mysql\'.');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof MySQLPlatform, 'This migration can only be applied on \'mysql\'.');
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_access_tokens') . ' CHANGE `token` `token` varchar(191) NOT NULL');
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_access_tokens') . ' CHANGE `scope` `scope` varchar(191)');
@ -27,7 +28,7 @@ class Version20181128203230 extends WallabagMigration
public function down(Schema $schema): void
{
$this->skipIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'This migration can only be applied on \'mysql\'.');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof MySQLPlatform, 'This migration can only be applied on \'mysql\'.');
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_access_tokens') . ' CHANGE `token` `token` varchar(255) NOT NULL');
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_access_tokens') . ' CHANGE `scope` `scope` varchar(255)');

View File

@ -2,6 +2,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -12,8 +15,10 @@ final class Version20181202073750 extends WallabagMigration
{
public function up(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('DROP INDEX UNIQ_1D63E7E5C05FB297');
$this->addSql('DROP INDEX UNIQ_1D63E7E5A0D96FBF');
$this->addSql('DROP INDEX UNIQ_1D63E7E592FC23A8');
@ -28,13 +33,13 @@ final class Version20181202073750 extends WallabagMigration
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5A0D96FBF ON ' . $this->getTable('user', true) . ' (email_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E592FC23A8 ON ' . $this->getTable('user', true) . ' (username_canonical)');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' ADD googleAuthenticatorSecret VARCHAR(191) DEFAULT NULL');
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' CHANGE twoFactorAuthentication emailTwoFactor BOOLEAN NOT NULL');
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' DROP trusted');
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' ADD backupCodes LONGTEXT DEFAULT NULL COMMENT \'(DC2Type:json_array)\'');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' ADD googleAuthenticatorSecret VARCHAR(191) DEFAULT NULL');
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' RENAME COLUMN twofactorauthentication TO emailTwoFactor');
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' DROP trusted');
@ -45,8 +50,10 @@ final class Version20181202073750 extends WallabagMigration
public function down(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('DROP INDEX UNIQ_1D63E7E592FC23A8');
$this->addSql('DROP INDEX UNIQ_1D63E7E5A0D96FBF');
$this->addSql('DROP INDEX UNIQ_1D63E7E5C05FB297');
@ -59,13 +66,13 @@ final class Version20181202073750 extends WallabagMigration
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5A0D96FBF ON "' . $this->getTable('user', true) . '" (email_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5C05FB297 ON "' . $this->getTable('user', true) . '" (confirmation_token)');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE `' . $this->getTable('user') . '` DROP googleAuthenticatorSecret');
$this->addSql('ALTER TABLE `' . $this->getTable('user') . '` CHANGE emailtwofactor twoFactorAuthentication BOOLEAN NOT NULL');
$this->addSql('ALTER TABLE `' . $this->getTable('user') . '` ADD trusted TEXT DEFAULT NULL');
$this->addSql('ALTER TABLE `' . $this->getTable('user') . '` DROP backupCodes');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' DROP googleAuthenticatorSecret');
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' RENAME COLUMN emailTwoFactor TO twofactorauthentication');
$this->addSql('ALTER TABLE ' . $this->getTable('user') . ' ADD trusted TEXT DEFAULT NULL');

View File

@ -2,6 +2,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -12,8 +15,10 @@ final class Version20190425115043 extends WallabagMigration
{
public function up(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('DROP INDEX UNIQ_87E64C53A76ED395');
$this->addSql('CREATE TEMPORARY TABLE __temp__' . $this->getTable('config', true) . ' AS SELECT id, user_id, theme, items_per_page, language, rss_token, rss_limit, reading_speed, pocket_consumer_key, action_mark_as_read, list_mode FROM ' . $this->getTable('config', true));
$this->addSql('DROP TABLE ' . $this->getTable('config', true));
@ -22,11 +27,11 @@ final class Version20190425115043 extends WallabagMigration
$this->addSql('DROP TABLE __temp__' . $this->getTable('config', true));
$this->addSql('CREATE UNIQUE INDEX UNIQ_87E64C53A76ED395 ON ' . $this->getTable('config', true) . ' (user_id)');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('config') . ' CHANGE rss_token feed_token VARCHAR(255) DEFAULT NULL');
$this->addSql('ALTER TABLE ' . $this->getTable('config') . ' CHANGE rss_limit feed_limit INT DEFAULT NULL');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('config') . ' RENAME COLUMN rss_token TO feed_token');
$this->addSql('ALTER TABLE ' . $this->getTable('config') . ' RENAME COLUMN rss_limit TO feed_limit');
break;
@ -35,8 +40,10 @@ final class Version20190425115043 extends WallabagMigration
public function down(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('DROP INDEX UNIQ_87E64C53A76ED395');
$this->addSql('CREATE TEMPORARY TABLE __temp__' . $this->getTable('config', true) . ' AS SELECT id, user_id, theme, items_per_page, language, feed_token, feed_limit, reading_speed, pocket_consumer_key, action_mark_as_read, list_mode FROM "' . $this->getTable('config', true) . '"');
$this->addSql('DROP TABLE "' . $this->getTable('config', true) . '"');
@ -45,11 +52,11 @@ final class Version20190425115043 extends WallabagMigration
$this->addSql('DROP TABLE __temp__' . $this->getTable('config', true));
$this->addSql('CREATE UNIQUE INDEX UNIQ_87E64C53A76ED395 ON "' . $this->getTable('config', true) . '" (user_id)');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('config') . ' CHANGE feed_token rss_token');
$this->addSql('ALTER TABLE ' . $this->getTable('config') . ' CHANGE feed_limit rss_limit');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('config') . ' RENAME COLUMN feed_token TO rss_token');
$this->addSql('ALTER TABLE ' . $this->getTable('config') . ' RENAME COLUMN feed_limit TO rss_limit');
break;

View File

@ -3,6 +3,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Migrations\SkipMigrationException;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -17,8 +20,10 @@ final class Version20190510141130 extends WallabagMigration
{
public function up(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('DROP INDEX IDX_368A4209A76ED395');
$this->addSql('DROP INDEX IDX_368A420919EB6921');
$this->addSql('DROP INDEX UNIQ_368A42095F37A13B');
@ -60,7 +65,7 @@ final class Version20190510141130 extends WallabagMigration
$this->addSql('CREATE INDEX IDX_EE52E3FAA76ED395 ON ' . $this->getTable('oauth2_auth_codes', true) . ' (user_id)');
$this->addSql('CREATE INDEX IDX_EE52E3FA19EB6921 ON ' . $this->getTable('oauth2_auth_codes', true) . ' (client_id)');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_access_tokens') . ' DROP FOREIGN KEY FK_368A4209A76ED395');
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_access_tokens') . ' ADD CONSTRAINT FK_368A4209A76ED395 FOREIGN KEY (user_id) REFERENCES ' . $this->getTable('user') . ' (id) ON DELETE CASCADE');
@ -75,7 +80,7 @@ final class Version20190510141130 extends WallabagMigration
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_auth_codes') . ' DROP FOREIGN KEY FK_EE52E3FAA76ED395');
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_auth_codes') . ' ADD CONSTRAINT FK_EE52E3FAA76ED395 FOREIGN KEY (user_id) REFERENCES ' . $this->getTable('user') . ' (id) ON DELETE CASCADE');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_access_tokens') . ' DROP CONSTRAINT FK_368A4209A76ED395');
$this->addSql('ALTER TABLE ' . $this->getTable('oauth2_access_tokens') . ' ADD CONSTRAINT FK_368A4209A76ED395 FOREIGN KEY (user_id) REFERENCES ' . $this->getTable('user') . ' (id) ON DELETE CASCADE NOT DEFERRABLE INITIALLY IMMEDIATE');

View File

@ -4,6 +4,7 @@ declare(strict_types=1);
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -14,7 +15,7 @@ final class Version20190511165128 extends WallabagMigration
{
public function up(Schema $schema): void
{
$this->skipIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'This migration only apply to MySQL');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof MySQLPlatform, 'This migration only apply to MySQL');
$this->addSql('ALTER TABLE ' . $this->getTable('tag') . ' CHANGE `label` `label` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;');
$this->addSql('ALTER TABLE ' . $this->getTable('tag') . ' CHANGE `slug` `slug` VARCHAR(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;');
@ -22,7 +23,7 @@ final class Version20190511165128 extends WallabagMigration
public function down(Schema $schema): void
{
$this->skipIf('mysql' !== $this->connection->getDatabasePlatform()->getName(), 'This migration only apply to MySQL');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof MySQLPlatform, 'This migration only apply to MySQL');
$this->addSql('ALTER TABLE ' . $this->getTable('tag') . ' CHANGE `slug` `slug` VARCHAR(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;');
$this->addSql('ALTER TABLE ' . $this->getTable('tag') . ' CHANGE `label` `label` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;');

View File

@ -2,6 +2,7 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -14,7 +15,7 @@ final class Version20190619093534 extends WallabagMigration
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->skipIf('sqlite' !== $this->connection->getDatabasePlatform()->getName(), 'Migration can only be executed safely on \'sqlite\'.');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof SqlitePlatform, 'Migration can only be executed safely on \'sqlite\'.');
$this->addSql('UPDATE ' . $this->getTable('entry', true) . ' SET reading_time = 0 WHERE reading_time IS NULL;');
@ -42,7 +43,7 @@ final class Version20190619093534 extends WallabagMigration
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->skipIf('sqlite' !== $this->connection->getDatabasePlatform()->getName(), 'Migration can only be executed safely on \'sqlite\'.');
$this->skipIf(!$this->connection->getDatabasePlatform() instanceof SqlitePlatform, 'Migration can only be executed safely on \'sqlite\'.');
$this->addSql('DROP INDEX IDX_F4D18282A76ED395');
$this->addSql('DROP INDEX created_at');

View File

@ -2,6 +2,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -18,8 +21,10 @@ final class Version20190806130304 extends WallabagMigration
{
public function up(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('DROP INDEX uid');
$this->addSql('DROP INDEX created_at');
$this->addSql('DROP INDEX hashed_url_user_id');
@ -44,7 +49,7 @@ final class Version20190806130304 extends WallabagMigration
$this->addSql('CREATE INDEX tag_label ON ' . $this->getTable('tag', true) . ' (label)');
$this->addSql('CREATE INDEX config_feed_token ON ' . $this->getTable('config', true) . ' (feed_token)');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' MODIFY language VARCHAR(20) DEFAULT NULL');
$this->addSql('CREATE INDEX user_language ON ' . $this->getTable('entry') . ' (language, user_id)');
$this->addSql('CREATE INDEX user_archived ON ' . $this->getTable('entry') . ' (user_id, is_archived, archived_at)');
@ -53,7 +58,7 @@ final class Version20190806130304 extends WallabagMigration
$this->addSql('CREATE INDEX tag_label ON ' . $this->getTable('tag') . ' (label (255))');
$this->addSql('CREATE INDEX config_feed_token ON ' . $this->getTable('config') . ' (feed_token (255))');
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' ALTER language TYPE VARCHAR(20)');
$this->addSql('CREATE INDEX user_language ON ' . $this->getTable('entry') . ' (language, user_id)');
$this->addSql('CREATE INDEX user_archived ON ' . $this->getTable('entry') . ' (user_id, is_archived, archived_at)');
@ -67,8 +72,10 @@ final class Version20190806130304 extends WallabagMigration
public function down(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('DROP INDEX IDX_F4D18282A76ED395');
$this->addSql('DROP INDEX created_at');
$this->addSql('DROP INDEX uid');
@ -93,7 +100,7 @@ final class Version20190806130304 extends WallabagMigration
$this->addSql('CREATE INDEX hashed_url_user_id ON ' . $this->getTable('entry', true) . ' (user_id, hashed_url)');
$this->addSql('CREATE INDEX hashed_given_url_user_id ON ' . $this->getTable('entry', true) . ' (user_id, hashed_given_url)');
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' MODIFY language LONGTEXT DEFAULT NULL');
$this->addSql('DROP INDEX user_language ON ' . $this->getTable('entry'));
$this->addSql('DROP INDEX user_archived ON ' . $this->getTable('entry'));
@ -102,7 +109,7 @@ final class Version20190806130304 extends WallabagMigration
$this->addSql('DROP INDEX tag_label ON ' . $this->getTable('tag'));
$this->addSql('DROP INDEX config_feed_token ON ' . $this->getTable('config'));
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('entry') . ' ALTER language TYPE TEXT');
$this->addSql('DROP INDEX user_language ON ' . $this->getTable('entry'));
$this->addSql('DROP INDEX user_archived ON ' . $this->getTable('entry'));

View File

@ -2,6 +2,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -12,14 +15,16 @@ final class Version20190808124957 extends WallabagMigration
{
public function up(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('craue_config_setting', true) . ' RENAME TO ' . $this->getTable('internal_setting', true));
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('craue_config_setting') . ' RENAME ' . $this->getTable('internal_setting'));
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('craue_config_setting') . ' RENAME TO ' . $this->getTable('internal_setting'));
break;
}
@ -27,14 +32,16 @@ final class Version20190808124957 extends WallabagMigration
public function down(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('internal_setting', true) . ' RENAME TO ' . $this->getTable('craue_config_setting', true));
break;
case 'mysql':
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('internal_setting') . ' RENAME ' . $this->getTable('craue_config_setting'));
break;
case 'postgresql':
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $this->getTable('internal_setting') . ' RENAME TO ' . $this->getTable('craue_config_setting'));
break;
}

View File

@ -4,6 +4,7 @@ declare(strict_types=1);
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -23,7 +24,7 @@ final class Version20190826204730 extends WallabagMigration
$userTable->setPrimaryKey(['id']);
$userTable->addForeignKeyConstraint($this->getTable('config'), ['config_id'], ['id'], [], 'fk_config');
if ('postgresql' === $this->connection->getDatabasePlatform()->getName()) {
if ($this->connection->getDatabasePlatform() instanceof PostgreSQLPlatform) {
$schema->dropSequence('ignore_origin_user_rule_id_seq');
$schema->createSequence('ignore_origin_user_rule_id_seq');
}
@ -35,7 +36,7 @@ final class Version20190826204730 extends WallabagMigration
$instanceTable->addColumn('rule', 'string', ['length' => 255]);
$instanceTable->setPrimaryKey(['id']);
if ('postgresql' === $this->connection->getDatabasePlatform()->getName()) {
if ($this->connection->getDatabasePlatform() instanceof PostgreSQLPlatform) {
$schema->dropSequence('ignore_origin_instance_rule_id_seq');
$schema->createSequence('ignore_origin_instance_rule_id_seq');
}

View File

@ -2,6 +2,9 @@
namespace Application\Migrations;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\DBAL\Schema\Schema;
use Wallabag\CoreBundle\Doctrine\WallabagMigration;
@ -12,48 +15,54 @@ final class Version20221221092957 extends WallabagMigration
{
public function up(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$this->addSql('CREATE TEMPORARY TABLE __temp__wallabag_user AS SELECT id, username, username_canonical, email, email_canonical, enabled, password, last_login, password_requested_at, name, created_at, updated_at, authCode, emailTwoFactor, salt, confirmation_token, roles, googleAuthenticatorSecret, backupCodes FROM wallabag_user');
$this->addSql('DROP TABLE wallabag_user');
$this->addSql('CREATE TABLE "wallabag_user" (id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, username VARCHAR(180) NOT NULL, username_canonical VARCHAR(180) NOT NULL, email VARCHAR(180) NOT NULL, email_canonical VARCHAR(180) NOT NULL, enabled BOOLEAN NOT NULL, salt VARCHAR(255) DEFAULT NULL, password VARCHAR(255) NOT NULL, last_login DATETIME DEFAULT NULL, confirmation_token VARCHAR(180) DEFAULT NULL, password_requested_at DATETIME DEFAULT NULL, roles CLOB NOT NULL --(DC2Type:array)
$userTable = $this->getTable('user');
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('CREATE TEMPORARY TABLE __temp__wallabag_user AS SELECT id, username, username_canonical, email, email_canonical, enabled, password, last_login, password_requested_at, name, created_at, updated_at, authCode, emailTwoFactor, salt, confirmation_token, roles, googleAuthenticatorSecret, backupCodes FROM ' . $userTable);
$this->addSql('DROP TABLE ' . $userTable);
$this->addSql('CREATE TABLE ' . $userTable . ' (id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, username VARCHAR(180) NOT NULL, username_canonical VARCHAR(180) NOT NULL, email VARCHAR(180) NOT NULL, email_canonical VARCHAR(180) NOT NULL, enabled BOOLEAN NOT NULL, salt VARCHAR(255) DEFAULT NULL, password VARCHAR(255) NOT NULL, last_login DATETIME DEFAULT NULL, confirmation_token VARCHAR(180) DEFAULT NULL, password_requested_at DATETIME DEFAULT NULL, roles CLOB NOT NULL --(DC2Type:array)
, name CLOB DEFAULT NULL, created_at DATETIME NOT NULL, updated_at DATETIME NOT NULL, authCode INTEGER DEFAULT NULL, googleAuthenticatorSecret VARCHAR(255) DEFAULT NULL, backupCodes CLOB DEFAULT NULL --(DC2Type:json)
, emailTwoFactor BOOLEAN NOT NULL)');
$this->addSql('INSERT INTO wallabag_user (id, username, username_canonical, email, email_canonical, enabled, password, last_login, password_requested_at, name, created_at, updated_at, authCode, emailTwoFactor, salt, confirmation_token, roles, googleAuthenticatorSecret, backupCodes) SELECT id, username, username_canonical, email, email_canonical, enabled, password, last_login, password_requested_at, name, created_at, updated_at, authCode, emailTwoFactor, salt, confirmation_token, roles, googleAuthenticatorSecret, backupCodes FROM __temp__wallabag_user');
$this->addSql('INSERT INTO ' . $userTable . ' (id, username, username_canonical, email, email_canonical, enabled, password, last_login, password_requested_at, name, created_at, updated_at, authCode, emailTwoFactor, salt, confirmation_token, roles, googleAuthenticatorSecret, backupCodes) SELECT id, username, username_canonical, email, email_canonical, enabled, password, last_login, password_requested_at, name, created_at, updated_at, authCode, emailTwoFactor, salt, confirmation_token, roles, googleAuthenticatorSecret, backupCodes FROM __temp__wallabag_user');
$this->addSql('DROP TABLE __temp__wallabag_user');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E592FC23A8 ON wallabag_user (username_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5A0D96FBF ON wallabag_user (email_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5C05FB297 ON wallabag_user (confirmation_token)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E592FC23A8 ON ' . $userTable . ' (username_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5A0D96FBF ON ' . $userTable . ' (email_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5C05FB297 ON ' . $userTable . ' (confirmation_token)');
break;
case 'mysql':
$this->addSql('ALTER TABLE wallabag_user CHANGE backupCodes backupCodes JSON DEFAULT NULL');
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $userTable . ' CHANGE backupCodes backupCodes JSON DEFAULT NULL');
break;
case 'postgresql':
$this->addSql('ALTER TABLE wallabag_user ALTER backupcodes TYPE JSON USING backupcodes::json');
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $userTable . ' ALTER backupcodes TYPE JSON USING backupcodes::json');
break;
}
}
public function down(Schema $schema): void
{
switch ($this->connection->getDatabasePlatform()->getName()) {
case 'sqlite':
$this->addSql('CREATE TEMPORARY TABLE __temp__wallabag_user AS SELECT id, username, username_canonical, email, email_canonical, enabled, salt, password, last_login, confirmation_token, password_requested_at, roles, name, created_at, updated_at, authCode, googleAuthenticatorSecret, backupCodes, emailTwoFactor FROM "wallabag_user"');
$this->addSql('DROP TABLE "wallabag_user"');
$this->addSql('CREATE TABLE "wallabag_user" (id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, username VARCHAR(180) NOT NULL, username_canonical VARCHAR(180) NOT NULL, email VARCHAR(180) NOT NULL, email_canonical VARCHAR(180) NOT NULL, enabled BOOLEAN NOT NULL, salt VARCHAR(255) DEFAULT NULL, password VARCHAR(255) NOT NULL, last_login DATETIME DEFAULT NULL, confirmation_token VARCHAR(180) DEFAULT NULL, password_requested_at DATETIME DEFAULT NULL, roles CLOB NOT NULL --(DC2Type:array)
$userTable = $this->getTable('user');
$platform = $this->connection->getDatabasePlatform();
switch (true) {
case $platform instanceof SqlitePlatform:
$this->addSql('CREATE TEMPORARY TABLE __temp__wallabag_user AS SELECT id, username, username_canonical, email, email_canonical, enabled, salt, password, last_login, confirmation_token, password_requested_at, roles, name, created_at, updated_at, authCode, googleAuthenticatorSecret, backupCodes, emailTwoFactor FROM ' . $userTable);
$this->addSql('DROP TABLE ' . $userTable);
$this->addSql('CREATE TABLE ' . $userTable . ' (id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, username VARCHAR(180) NOT NULL, username_canonical VARCHAR(180) NOT NULL, email VARCHAR(180) NOT NULL, email_canonical VARCHAR(180) NOT NULL, enabled BOOLEAN NOT NULL, salt VARCHAR(255) DEFAULT NULL, password VARCHAR(255) NOT NULL, last_login DATETIME DEFAULT NULL, confirmation_token VARCHAR(180) DEFAULT NULL, password_requested_at DATETIME DEFAULT NULL, roles CLOB NOT NULL --(DC2Type:array)
, name CLOB DEFAULT NULL, created_at DATETIME NOT NULL, updated_at DATETIME NOT NULL, authCode INTEGER DEFAULT NULL, googleAuthenticatorSecret VARCHAR(255) DEFAULT NULL, backupCodes CLOB DEFAULT NULL --(DC2Type:json_array)
, emailTwoFactor BOOLEAN NOT NULL)');
$this->addSql('INSERT INTO "wallabag_user" (id, username, username_canonical, email, email_canonical, enabled, salt, password, last_login, confirmation_token, password_requested_at, roles, name, created_at, updated_at, authCode, googleAuthenticatorSecret, backupCodes, emailTwoFactor) SELECT id, username, username_canonical, email, email_canonical, enabled, salt, password, last_login, confirmation_token, password_requested_at, roles, name, created_at, updated_at, authCode, googleAuthenticatorSecret, backupCodes, emailTwoFactor FROM __temp__wallabag_user');
$this->addSql('INSERT INTO ' . $userTable . ' (id, username, username_canonical, email, email_canonical, enabled, salt, password, last_login, confirmation_token, password_requested_at, roles, name, created_at, updated_at, authCode, googleAuthenticatorSecret, backupCodes, emailTwoFactor) SELECT id, username, username_canonical, email, email_canonical, enabled, salt, password, last_login, confirmation_token, password_requested_at, roles, name, created_at, updated_at, authCode, googleAuthenticatorSecret, backupCodes, emailTwoFactor FROM __temp__wallabag_user');
$this->addSql('DROP TABLE __temp__wallabag_user');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E592FC23A8 ON "wallabag_user" (username_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5A0D96FBF ON "wallabag_user" (email_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5C05FB297 ON "wallabag_user" (confirmation_token)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E592FC23A8 ON ' . $userTable . ' (username_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5A0D96FBF ON ' . $userTable . ' (email_canonical)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_1D63E7E5C05FB297 ON ' . $userTable . ' (confirmation_token)');
break;
case 'mysql':
$this->addSql('ALTER TABLE `wallabag_user`CHANGE backupCodes backupCodes JSON DEFAULT NULL COMMENT \'(DC2Type:json_array)\'');
case $platform instanceof MySQLPlatform:
$this->addSql('ALTER TABLE ' . $userTable . ' CHANGE backupCodes backupCodes JSON DEFAULT NULL COMMENT \'(DC2Type:json_array)\'');
break;
case 'postgresql':
$this->addSql('ALTER TABLE "wallabag_user" ALTER backupCodes TYPE TEXT');
case $platform instanceof PostgreSQLPlatform:
$this->addSql('ALTER TABLE ' . $userTable . ' ALTER backupCodes TYPE TEXT');
break;
}
}

View File

@ -3,7 +3,7 @@
========================================================================== */
main {
#content {
div#content {
padding: 0 0.5rem;
}
}

View File

@ -52,6 +52,7 @@
height: 100%;
vertical-align: middle;
opacity: initial;
z-index: 10;
}
.toggle-checkbox:not(:checked) + .mass-action,

View File

@ -21,7 +21,7 @@
}
@media screen and (min-width: 993px) {
.entry #content {
.entry main div#content {
padding-left: 70px;
}
}

View File

@ -23,8 +23,6 @@ framework:
csrf_protection: ~
validation:
enable_annotations: true
templating:
engines: ['twig']
default_locale: "%locale%"
trusted_hosts: ~
session:
@ -43,7 +41,6 @@ twig:
strict_variables: "%kernel.debug%"
form_themes:
- "@LexikFormFilter/Form/form_div_layout.html.twig"
exception_controller: Wallabag\CoreBundle\Controller\ExceptionController:showAction
globals:
registration_enabled: '%fosuser_registration%'
@ -87,8 +84,13 @@ doctrine_migrations:
executed_at_column_name: 'executed_at'
fos_rest:
zone:
- { path: ^/api }
- { path: ^/annotations }
param_fetcher_listener: true
body_listener: true
exception:
serializer_error_renderer: true
view:
mime_types:
csv:
@ -117,9 +119,6 @@ fos_rest:
- { path: "^/api/entries/([0-9]+)/export.(.*)", priorities: ['epub', 'mobi', 'pdf', 'txt', 'csv'], fallback_format: json, prefer_extension: false }
- { path: "^/api", priorities: ['json', 'xml'], fallback_format: json, prefer_extension: false }
- { path: "^/annotations", priorities: ['json', 'xml'], fallback_format: json, prefer_extension: false }
# for an unknown reason, EACH REQUEST goes to FOS\RestBundle\EventListener\FormatListener
# so we need to add custom rule for custom api export but also for all other routes of the application...
- { path: '^/', priorities: ['text/html', '*/*'], fallback_format: html, prefer_extension: false }
nelmio_api_doc:
areas:
@ -201,15 +200,15 @@ scheb_two_factor:
lifetime: 2592000
backup_codes:
enabled: "%twofactor_auth%"
enabled: true
google:
enabled: "%twofactor_auth%"
enabled: true
issuer: "%server_name%"
template: "@WallabagUser/Authentication/form.html.twig"
email:
enabled: "%twofactor_auth%"
enabled: true
sender_email: "%twofactor_sender%"
digits: 6
template: "@WallabagUser/Authentication/form.html.twig"

View File

@ -34,7 +34,6 @@ parameters:
secret: CHANGE_ME_TO_SOMETHING_SECRET_AND_RANDOM
# two factor stuff
twofactor_auth: true
twofactor_sender: no-reply@wallabag.org
# fosuser stuff

View File

@ -12,7 +12,7 @@ services:
autoconfigure: true
public: true
bind:
$rootDir: '%kernel.root_dir%'
$projectDir: '%kernel.project_dir%'
$debug: '%kernel.debug%'
$defaultLocale: '%kernel.default_locale%'
$wallabagUrl: '%domain_name%'

View File

@ -1,5 +1,5 @@
wallabag_core:
version: 2.6.1
version: 2.6.3
paypal_url: "https://liberapay.com/wallabag/donate"
languages:
en: 'English'

View File

@ -2,16 +2,16 @@ const path = require('path');
const webpack = require('webpack');
const StyleLintPlugin = require('stylelint-webpack-plugin');
const rootDir = path.resolve(__dirname, '../../../');
const projectDir = path.resolve(__dirname, '../../../');
module.exports = {
entry: {
material: path.join(rootDir, './app/Resources/static/themes/material/index.js'),
public: path.join(rootDir, './app/Resources/static/themes/_global/share.js'),
material: path.join(projectDir, './app/Resources/static/themes/material/index.js'),
public: path.join(projectDir, './app/Resources/static/themes/_global/share.js'),
},
output: {
filename: '[name].js',
path: path.resolve(rootDir, 'web/wallassets'),
path: path.resolve(projectDir, 'web/wallassets'),
publicPath: '',
},
plugins: [
@ -31,7 +31,7 @@ module.exports = {
],
resolve: {
alias: {
jquery: path.join(rootDir, 'node_modules/jquery/dist/jquery.js'),
jquery: path.join(projectDir, 'node_modules/jquery/dist/jquery.js'),
},
},
};

View File

@ -3,7 +3,7 @@
use Symfony\Bundle\FrameworkBundle\Console\Application;
use Symfony\Component\Console\Input\ArgvInput;
use Symfony\Component\Debug\Debug;
use Symfony\Component\ErrorHandler\Debug;
// if you don't want to setup permissions the proper way, just uncomment the following PHP line
// read https://symfony.com/doc/current/setup.html#checking-symfony-application-configuration-and-setup

View File

@ -1,33 +1,38 @@
{
"name": "wallabag/wallabag",
"type": "project",
"description": "open source self hostable read-it-later web application",
"license": "MIT",
"type": "project",
"keywords": [
"poche",
"wallabag",
"read-it-later",
"read it later"
],
"homepage": "https://github.com/wallabag/wallabag",
"license": "MIT",
"authors": [
{
"name": "Nicolas Lœuillet",
"email": "nicolas@loeuillet.org",
"homepage": "http://www.cdetc.fr",
"homepage": "https://nicolas.loeuillet.org",
"role": "Developer"
},
{
"name": "Thomas Citharel",
"homepage": "http://tcit.fr",
"homepage": "https://tcit.fr",
"role": "Developer"
},
{
"name": "Jérémy Benoist",
"homepage": "https://www.j0k3r.net",
"role": "Developer"
},
{
"name": "Kevin Decherf",
"homepage": "https://kdecherf.com/",
"role": "Developer"
}
],
"homepage": "https://github.com/wallabag/wallabag",
"support": {
"email": "hello@wallabag.org",
"issues": "https://github.com/wallabag/wallabag/issues"
@ -81,7 +86,6 @@
"kphoen/rulerz": "^0.21",
"kphoen/rulerz-bundle": "~0.13",
"laminas/laminas-code": "^4.7",
"laminas/laminas-diactoros": "^2.3",
"lcobucci/jwt": "~4.1.5",
"lexik/form-filter-bundle": "^7.0",
"mgargano/simplehtmldom": "~1.5",
@ -111,13 +115,34 @@
"scheb/2fa-qr-code": "^5.13",
"scheb/2fa-trusted-device": "^5.13",
"sensio/framework-extra-bundle": "^6.2",
"sentry/sentry-symfony": "4.9.2",
"sentry/sentry-symfony": "4.10.0",
"stof/doctrine-extensions-bundle": "^1.2",
"symfony/dom-crawler": "^4.0",
"symfony/mailer": "^4.0",
"symfony/asset": "^4.4",
"symfony/config": "^4.4",
"symfony/console": "^4.4",
"symfony/debug": "^4.4",
"symfony/dependency-injection": "^4.4",
"symfony/doctrine-bridge": "^4.4",
"symfony/dom-crawler": "^4.4",
"symfony/error-handler": "^4.4",
"symfony/event-dispatcher": "^4.4",
"symfony/finder": "^4.4",
"symfony/form": "^4.4",
"symfony/framework-bundle": "^4.4",
"symfony/http-foundation": "^4.4",
"symfony/http-kernel": "^4.4",
"symfony/mailer": "^4.4",
"symfony/mime": "^4.4",
"symfony/monolog-bundle": "^3.1",
"symfony/options-resolver": "^4.4",
"symfony/proxy-manager-bridge": "^4.4",
"symfony/symfony": "^4.0",
"symfony/routing": "^4.4",
"symfony/security-bundle": "^4.4",
"symfony/security-core": "^4.4",
"symfony/security-http": "^4.4",
"symfony/templating": "^4.4",
"symfony/twig-bundle": "^4.4",
"symfony/validator": "^4.4",
"tecnickcom/tcpdf": "^6.3.0",
"twig/extra-bundle": "^3.4",
"twig/string-extra": "^3.4",
@ -130,6 +155,7 @@
"require-dev": {
"dama/doctrine-test-bundle": "^7.1",
"doctrine/doctrine-fixtures-bundle": "~3.0",
"ergebnis/composer-normalize": "^2.28",
"friendsofphp/php-cs-fixer": "~3.4",
"friendsoftwig/twigcs": "^6.0",
"m6web/redis-mock": "^5.0",
@ -139,31 +165,20 @@
"phpstan/phpstan-doctrine": "^1.3",
"phpstan/phpstan-phpunit": "^1.1",
"phpstan/phpstan-symfony": "^1.2",
"symfony/browser-kit": "^4.4",
"symfony/css-selector": "^4.4",
"symfony/debug-bundle": "^4.4",
"symfony/maker-bundle": "^1.18",
"symfony/phpunit-bridge": "~6.0"
"symfony/phpunit-bridge": "~6.0",
"symfony/var-dumper": "^4.4",
"symfony/web-profiler-bundle": "^4.4",
"symfony/web-server-bundle": "^4.4"
},
"suggest": {
"ext-imagick": "To keep GIF animation when downloading image is enabled"
},
"scripts": {
"post-cmd": [
"Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
"bin/console cache:clear --no-warmup",
"bin/console assets:install web --symlink --relative"
],
"post-install-cmd": [
"@post-cmd"
],
"post-update-cmd": [
"@post-cmd"
]
},
"extra": {
"incenteev-parameters": {
"file": "app/config/parameters.yml"
},
"public-dir": "web"
},
"minimum-stability": "dev",
"prefer-stable": true,
"autoload": {
"psr-4": {
"Wallabag\\": "src/Wallabag/"
@ -176,22 +191,37 @@
"autoload-dev": {
"psr-4": {
"Tests\\": "tests/"
},
"files": [
"vendor/symfony/symfony/src/Symfony/Component/VarDumper/Resources/functions/dump.php"
]
}
},
"config": {
"allow-plugins": {
"phpstan/extension-installer": true,
"php-http/discovery": true,
"ergebnis/composer-normalize": true
},
"bin-dir": "bin",
"platform": {
"php": "7.4.29"
},
"sort-packages": true,
"allow-plugins": {
"phpstan/extension-installer": true,
"php-http/discovery": true
}
"sort-packages": true
},
"minimum-stability": "dev",
"prefer-stable": true
"extra": {
"incenteev-parameters": {
"file": "app/config/parameters.yml"
},
"public-dir": "web"
},
"scripts": {
"post-install-cmd": [
"@post-cmd"
],
"post-update-cmd": [
"@post-cmd"
],
"post-cmd": [
"Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
"bin/console cache:clear --no-warmup",
"bin/console assets:install web --symlink --relative"
]
}
}

5505
composer.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -1,4 +1,4 @@
FROM php:7.4-fpm AS rootless
FROM php:8.1-fpm AS rootless
ARG DEBIAN_FRONTEND=noninteractive
ARG NODE_VERSION=16
@ -33,7 +33,8 @@ RUN apt-get update && apt-get install -y \
zlib1g-dev \
git \
build-essential \
nodejs
nodejs \
npm
RUN docker-php-ext-configure gd --with-freetype --with-jpeg --with-webp
RUN docker-php-ext-install -j "$(nproc)" \
bcmath \

View File

@ -6,7 +6,7 @@ parameters:
database_name: ${DATABASE_NAME:-symfony}
database_user: ${DATABASE_USER:-root}
database_password: ${DATABASE_PASSWORD:-~}
database_path: '${DATABASE_PATH:-"%kernel.root_dir%/data/db/wallabag.sqlite"}'
database_path: '${DATABASE_PATH:-"%kernel.project_dir%/data/db/wallabag.sqlite"}'
database_table_prefix: ${DATABASE_TABLE_PREFIX:-wallabag_}
database_socket: null
database_charset: ${DATABASE_CHARSET:-utf8}
@ -22,7 +22,6 @@ parameters:
secret: ${SECRET:-~}
# two factor stuff
twofactor_auth: ${TWOFACTOR_AUTH:-true}
twofactor_sender: ${TWOFACTOR_SENDER:-no-reply@wallabag.org}
# fosuser stuff

View File

@ -1,6 +1,6 @@
{
"name": "wallabag",
"version": "2.5.0",
"version": "2.6.0",
"description": "wallabag is a self hostable application for saving web pages",
"private": true,
"directories": {
@ -17,17 +17,22 @@
{
"name": "Nicolas Lœuillet",
"email": "nicolas@loeuillet.org",
"homepage": "http://www.cdetc.fr",
"homepage": "https://nicolas.loeuillet.org",
"role": "Developer"
},
{
"name": "Thomas Citharel",
"homepage": "http://tcit.fr",
"homepage": "https://tcit.fr",
"role": "Developer"
},
{
"name": "Jérémy Benoist",
"homepage": "http://www.j0k3r.net",
"homepage": "https://www.j0k3r.net",
"role": "Developer"
},
{
"name": "Kevin Decherf",
"homepage": "https://kdecherf.com/",
"role": "Developer"
}
],
@ -36,34 +41,34 @@
"url": "https://github.com/wallabag/wallabag/issues"
},
"devDependencies": {
"@babel/core": "^7.22.5",
"@babel/eslint-parser": "^7.22.5",
"@babel/preset-env": "^7.22.5",
"autoprefixer": "^10.4.14",
"babel-loader": "^9.1.2",
"@babel/core": "^7.22.10",
"@babel/eslint-parser": "^7.22.10",
"@babel/preset-env": "^7.22.10",
"autoprefixer": "^10.4.15",
"babel-loader": "^9.1.3",
"css-loader": "^6.8.1",
"eslint": "^8.43.0",
"eslint": "^8.47.0",
"eslint-config-airbnb-base": "^15.0.0",
"eslint-plugin-import": "^2.27.5",
"eslint-plugin-import": "^2.28.1",
"eslint-webpack-plugin": "^4.0.1",
"file-loader": "^6.2.0",
"lato-font": "^3.0.0",
"mini-css-extract-plugin": "^2.7.6",
"node-sass": "^9.0.0",
"postcss": "^8.4.24",
"postcss": "^8.4.28",
"postcss-loader": "^7.3.3",
"postcss-scss": "^4.0.6",
"sass": "^1.63.4",
"postcss-scss": "^4.0.7",
"sass": "^1.66.1",
"sass-loader": "^13.3.2",
"style-loader": "^3.3.3",
"stylelint": "^15.8.0",
"stylelint-config-standard": "^33.0.0",
"stylelint-config-standard-scss": "^9.0.0",
"stylelint-scss": "^5.0.1",
"stylelint": "^15.10.3",
"stylelint-config-standard": "^34.0.0",
"stylelint-config-standard-scss": "^10.0.0",
"stylelint-scss": "^5.1.0",
"stylelint-webpack-plugin": "^4.1.1",
"terser-webpack-plugin": "^5.3.9",
"url-loader": "^4.1.1",
"webpack": "^5.87.0",
"webpack": "^5.88.2",
"webpack-cli": "^5.1.4",
"webpack-dev-server": "^4.15.1",
"webpack-manifest-plugin": "^5.0.0",
@ -79,7 +84,7 @@
"jquery.cookie": "^1.4.1",
"jr-qrcode": "^1.0.7",
"material-design-icons-iconfont": "^6.7.0",
"materialize-css": "^0.98.1",
"materialize-css": "^0.100.2",
"mathjax": "^3.2.2",
"mousetrap": "^1.6.0",
"ptsans-npm-webfont": "^0.0.4",

View File

@ -7,3 +7,9 @@ if [ ! -f composer.phar ]; then
else
COMPOSER_COMMAND='./composer.phar'
fi
# Check for git
command -v git >/dev/null 2>&1 ||
{ echo >&2 "git is not installed. We can't install wallabag";
exit 1
}

View File

@ -7,7 +7,9 @@ use Doctrine\Common\DataFixtures\DependentFixtureInterface;
use Doctrine\Persistence\ObjectManager;
use Wallabag\AnnotationBundle\Entity\Annotation;
use Wallabag\CoreBundle\DataFixtures\EntryFixtures;
use Wallabag\CoreBundle\Entity\Entry;
use Wallabag\UserBundle\DataFixtures\UserFixtures;
use Wallabag\UserBundle\Entity\User;
class AnnotationFixtures extends Fixture implements DependentFixtureInterface
{
@ -16,8 +18,8 @@ class AnnotationFixtures extends Fixture implements DependentFixtureInterface
*/
public function load(ObjectManager $manager)
{
$annotation1 = new Annotation($this->getReference('admin-user'));
$annotation1->setEntry($this->getReference('entry1'));
$annotation1 = new Annotation($this->getReference('admin-user', User::class));
$annotation1->setEntry($this->getReference('entry1', Entry::class));
$annotation1->setText('This is my annotation /o/');
$annotation1->setQuote('content');
@ -25,8 +27,8 @@ class AnnotationFixtures extends Fixture implements DependentFixtureInterface
$this->addReference('annotation1', $annotation1);
$annotation2 = new Annotation($this->getReference('admin-user'));
$annotation2->setEntry($this->getReference('entry2'));
$annotation2 = new Annotation($this->getReference('admin-user', User::class));
$annotation2->setEntry($this->getReference('entry2', Entry::class));
$annotation2->setText('This is my 2nd annotation /o/');
$annotation2->setQuote('content');
@ -34,8 +36,8 @@ class AnnotationFixtures extends Fixture implements DependentFixtureInterface
$this->addReference('annotation2', $annotation2);
$annotation3 = new Annotation($this->getReference('bob-user'));
$annotation3->setEntry($this->getReference('entry3'));
$annotation3 = new Annotation($this->getReference('bob-user', User::class));
$annotation3->setEntry($this->getReference('entry3', Entry::class));
$annotation3->setText('This is my first annotation !');
$annotation3->setQuote('content');

View File

@ -69,12 +69,16 @@ class DeveloperController extends AbstractController
/**
* Remove a client.
*
* @Route("/developer/client/delete/{id}", requirements={"id" = "\d+"}, name="developer_delete_client")
* @Route("/developer/client/delete/{id}", requirements={"id" = "\d+"}, name="developer_delete_client", methods={"POST"})
*
* @return RedirectResponse
*/
public function deleteClientAction(Client $client, EntityManagerInterface $entityManager, TranslatorInterface $translator)
public function deleteClientAction(Request $request, Client $client, EntityManagerInterface $entityManager, TranslatorInterface $translator)
{
if (!$this->isCsrfTokenValid('delete-client', $request->request->get('token'))) {
throw $this->createAccessDeniedException('Bad CSRF token.');
}
if (null === $this->getUser() || $client->getUser()->getId() !== $this->getUser()->getId()) {
throw $this->createAccessDeniedException('You can not access this client.');
}
@ -99,6 +103,9 @@ class DeveloperController extends AbstractController
*/
public function howtoFirstAppAction()
{
return $this->render('@WallabagCore/Developer/howto_app.html.twig');
return $this->render('@WallabagCore/Developer/howto_app.html.twig',
[
'wallabag_url' => $this->getParameter('domain_name'),
]);
}
}

View File

@ -8,6 +8,7 @@ use FOS\UserBundle\Event\UserEvent;
use FOS\UserBundle\FOSUserEvents;
use FOS\UserBundle\Model\UserManagerInterface;
use JMS\Serializer\SerializationContext;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Operation;
use OpenApi\Annotations as OA;
use Symfony\Component\EventDispatcher\EventDispatcherInterface;
@ -28,7 +29,8 @@ class UserRestController extends WallabagRestController
* summary="Retrieve current logged in user informations.",
* @OA\Response(
* response="200",
* description="Returned when successful"
* description="Returned when successful",
* @Model(type=User::class, groups={"user_api"}))
* )
* )
*
@ -52,32 +54,45 @@ class UserRestController extends WallabagRestController
* @OA\RequestBody(
* @OA\JsonContent(
* type="object",
* required={"username", "password", "email", "client_name"},
* required={"username", "password", "email"},
* @OA\Property(
* property="username",
* description="The user's username",
* @OA\Schema(type="string")
* type="string",
* example="wallabag",
* ),
* @OA\Property(
* property="password",
* description="The user's password",
* @OA\Schema(type="string")
* type="string",
* example="hidden_value",
* ),
* @OA\Property(
* property="email",
* description="The user's email",
* @OA\Schema(type="string")
* type="string",
* example="wallabag@wallabag.io",
* ),
* @OA\Property(
* property="client_name",
* description="The client name (to be used by your app)",
* @OA\Schema(type="string")
* type="string",
* example="Fancy App",
* ),
* )
* ),
* @OA\Response(
* response="200",
* description="Returned when successful"
* response="201",
* description="Returned when successful",
* @Model(type=User::class, groups={"user_api_with_client"})),
* ),
* @OA\Response(
* response="403",
* description="Server doesn't allow registrations"
* ),
* @OA\Response(
* response="400",
* description="Request is incorrectly formatted"
* )
* )
*

View File

@ -7,6 +7,7 @@ use Doctrine\ORM\EntityManagerInterface;
use FOS\RestBundle\Controller\AbstractFOSRestController;
use JMS\Serializer\SerializationContext;
use JMS\Serializer\SerializerInterface;
use Nelmio\ApiDocBundle\Annotation\Model;
use Nelmio\ApiDocBundle\Annotation\Operation;
use OpenApi\Annotations as OA;
use Symfony\Component\HttpFoundation\JsonResponse;
@ -15,6 +16,7 @@ use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInt
use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;
use Symfony\Component\Security\Core\Exception\AccessDeniedException;
use Symfony\Contracts\Translation\TranslatorInterface;
use Wallabag\ApiBundle\Entity\ApplicationInfo;
use Wallabag\UserBundle\Entity\User;
class WallabagRestController extends AbstractFOSRestController
@ -38,11 +40,16 @@ class WallabagRestController extends AbstractFOSRestController
* Retrieve version number.
*
* @Operation(
* tags={"Informations"},
* tags={"Information"},
* summary="Retrieve version number.",
* @OA\Response(
* response="200",
* description="Returned when successful"
* description="Returned when successful",
* @OA\JsonContent(
* description="Version number of the application.",
* type="string",
* example="2.5.2",
* )
* )
* )
*
@ -61,14 +68,13 @@ class WallabagRestController extends AbstractFOSRestController
}
/**
* Retrieve information about the wallabag instance.
*
* @Operation(
* tags={"Informations"},
* summary="Retrieve information about the wallabag instance.",
* tags={"Information"},
* summary="Retrieve information about the running wallabag application.",
* @OA\Response(
* response="200",
* description="Returned when successful"
* description="Returned when successful",
* @Model(type=ApplicationInfo::class),
* )
* )
*
@ -78,11 +84,10 @@ class WallabagRestController extends AbstractFOSRestController
*/
public function getInfoAction(Config $craueConfig)
{
$info = [
'appname' => 'wallabag',
'version' => $this->getParameter('wallabag_core.version'),
'allowed_registration' => $this->getParameter('fosuser_registration') && $craueConfig->get('api_user_registration'),
];
$info = new ApplicationInfo(
$this->getParameter('wallabag_core.version'),
$this->getParameter('fosuser_registration') && $craueConfig->get('api_user_registration'),
);
return (new JsonResponse())->setJson($this->serializer->serialize($info, 'json'));
}

View File

@ -0,0 +1,44 @@
<?php
namespace Wallabag\ApiBundle\Entity;
use OpenApi\Annotations as OA;
class ApplicationInfo
{
/**
* @var string
* @OA\Property(
* description="Name of the application.",
* type="string",
* example="wallabag",
* )
*/
public $appname;
/**
* @var string
* @OA\Property(
* description="Version number of the application.",
* type="string",
* example="2.5.2",
* )
*/
public $version;
/**
* @var bool
* @OA\Property(
* description="Indicates whether registration is allowed. See PUT /api/user.",
* type="boolean"
* )
*/
public $allowed_registration;
public function __construct($version, $allowed_registration)
{
$this->appname = 'wallabag';
$this->version = $version;
$this->allowed_registration = $allowed_registration;
}
}

View File

@ -7,6 +7,7 @@ use FOS\OAuthServerBundle\Entity\Client as BaseClient;
use JMS\Serializer\Annotation\Groups;
use JMS\Serializer\Annotation\SerializedName;
use JMS\Serializer\Annotation\VirtualProperty;
use OpenApi\Annotations as OA;
use Wallabag\UserBundle\Entity\User;
/**
@ -27,6 +28,12 @@ class Client extends BaseClient
*
* @ORM\Column(name="name", type="text", nullable=false)
*
* @OA\Property(
* description="Name of the API client",
* type="string",
* example="Default Client",
* )
*
* @Groups({"user_api_with_client"})
*/
protected $name;
@ -44,6 +51,12 @@ class Client extends BaseClient
/**
* @var string
*
* @OA\Property(
* description="Client secret used for authorization",
* type="string",
* example="2lmubx2m9vy80ss8c4wwcsg8ok44s88ocwcc8wo0w884oc8440",
* )
*
* @SerializedName("client_secret")
* @Groups({"user_api_with_client"})
*/
@ -94,6 +107,13 @@ class Client extends BaseClient
/**
* @VirtualProperty
*
* @OA\Property(
* description="Client secret used for authorization",
* type="string",
* example="3_1lpybsn0od40css4w4ko8gsc8cwwskggs8kgg448ko0owo4c84",
* )
*
* @SerializedName("client_id")
* @Groups({"user_api_with_client"})
*/

View File

@ -4,6 +4,9 @@ namespace Wallabag\CoreBundle\Command;
use Doctrine\DBAL\Connection;
use Doctrine\DBAL\Exception\DriverException;
use Doctrine\DBAL\Platforms\MySQLPlatform;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Platforms\SqlitePlatform;
use Doctrine\ORM\EntityManagerInterface;
use FOS\UserBundle\Event\UserEvent;
use FOS\UserBundle\FOSUserEvents;
@ -138,7 +141,7 @@ class InstallCommand extends Command
$help = '';
// now check if MySQL isn't too old to handle utf8mb4
if ($conn->isConnected() && 'mysql' === $conn->getDatabasePlatform()->getName()) {
if ($conn->isConnected() && $conn->getDatabasePlatform() instanceof MySQLPlatform) {
$version = $conn->query('select version()')->fetchOne();
$minimalVersion = '5.5.4';
@ -150,7 +153,7 @@ class InstallCommand extends Command
}
// testing if PostgreSQL > 9.1
if ($conn->isConnected() && 'postgresql' === $conn->getDatabasePlatform()->getName()) {
if ($conn->isConnected() && $conn->getDatabasePlatform() instanceof PostgreSQLPlatform) {
// return version should be like "PostgreSQL 9.5.4 on x86_64-apple-darwin15.6.0, compiled by Apple LLVM version 8.0.0 (clang-800.0.38), 64-bit"
$version = $conn->query('SELECT version();')->fetchOne();
@ -391,7 +394,7 @@ class InstallCommand extends Command
}
// custom verification for sqlite, since `getListDatabasesSQL` doesn't work for sqlite
if ('sqlite' === $schemaManager->getDatabasePlatform()->getName()) {
if ($connection->getDatabasePlatform() instanceof SqlitePlatform) {
$params = $connection->getParams();
if (isset($params['path']) && file_exists($params['path'])) {

View File

@ -246,7 +246,6 @@ class ConfigController extends AbstractController
'username' => $user->getUsername(),
'token' => $config->getFeedToken(),
],
'twofactor_auth' => $this->getParameter('twofactor_auth'),
'wallabag_url' => $this->getParameter('domain_name'),
'enabled_users' => $userRepository->getSumEnabledUsers(),
]);
@ -259,10 +258,6 @@ class ConfigController extends AbstractController
*/
public function disableOtpEmailAction()
{
if (!$this->getParameter('twofactor_auth')) {
return $this->createNotFoundException('two_factor not enabled');
}
$user = $this->getUser();
$user->setEmailTwoFactor(false);
@ -283,10 +278,6 @@ class ConfigController extends AbstractController
*/
public function otpEmailAction()
{
if (!$this->getParameter('twofactor_auth')) {
return $this->createNotFoundException('two_factor not enabled');
}
$user = $this->getUser();
$user->setGoogleAuthenticatorSecret(null);
@ -310,10 +301,6 @@ class ConfigController extends AbstractController
*/
public function disableOtpAppAction()
{
if (!$this->getParameter('twofactor_auth')) {
return $this->createNotFoundException('two_factor not enabled');
}
$user = $this->getUser();
$user->setGoogleAuthenticatorSecret('');
@ -336,10 +323,6 @@ class ConfigController extends AbstractController
*/
public function otpAppAction(GoogleAuthenticatorInterface $googleAuthenticator)
{
if (!$this->getParameter('twofactor_auth')) {
return $this->createNotFoundException('two_factor not enabled');
}
$user = $this->getUser();
$secret = $googleAuthenticator->generateSecret();
@ -377,10 +360,6 @@ class ConfigController extends AbstractController
*/
public function otpAppCancelAction()
{
if (!$this->getParameter('twofactor_auth')) {
return $this->createNotFoundException('two_factor not enabled');
}
$user = $this->getUser();
$user->setGoogleAuthenticatorSecret(null);
$user->setBackupCodes(null);
@ -544,12 +523,16 @@ class ConfigController extends AbstractController
/**
* Remove all annotations OR tags OR entries for the current user.
*
* @Route("/reset/{type}", requirements={"id" = "annotations|tags|entries"}, name="config_reset")
* @Route("/reset/{type}", requirements={"id" = "annotations|tags|entries"}, name="config_reset", methods={"POST"})
*
* @return RedirectResponse
*/
public function resetAction(string $type, AnnotationRepository $annotationRepository, EntryRepository $entryRepository)
public function resetAction(Request $request, string $type, AnnotationRepository $annotationRepository, EntryRepository $entryRepository)
{
if (!$this->isCsrfTokenValid('reset-area', $request->request->get('token'))) {
throw $this->createAccessDeniedException('Bad CSRF token.');
}
switch ($type) {
case 'annotations':
$annotationRepository->removeAllByUserId($this->getUser()->getId());
@ -636,7 +619,7 @@ class ConfigController extends AbstractController
$this->entityManager->persist($user);
$this->entityManager->flush();
return $this->redirect($request->headers->get('referer'));
return $this->redirect($request->getSession()->get('prevUrl'));
}
/**

View File

@ -128,7 +128,7 @@ class EntryController extends AbstractController
$this->entityManager->flush();
}
$redirectUrl = $this->redirectHelper->to($request->headers->get('referer'));
$redirectUrl = $this->redirectHelper->to($request->getSession()->get('prevUrl'));
return $this->redirect($redirectUrl);
}
@ -390,6 +390,7 @@ class EntryController extends AbstractController
public function viewAction(Entry $entry)
{
$this->checkUserAction($entry);
$this->get('session')->set('prevUrl', $this->generateUrl('view', ['id' => $entry->getId()]));
return $this->render(
'@WallabagCore/Entry/entry.html.twig',
@ -451,7 +452,7 @@ class EntryController extends AbstractController
$message
);
$redirectUrl = $this->redirectHelper->to($request->headers->get('referer'));
$redirectUrl = $this->redirectHelper->to($request->getSession()->get('prevUrl'));
return $this->redirect($redirectUrl);
}
@ -481,7 +482,7 @@ class EntryController extends AbstractController
$message
);
$redirectUrl = $this->redirectHelper->to($request->headers->get('referer'));
$redirectUrl = $this->redirectHelper->to($request->getSession()->get('prevUrl'));
return $this->redirect($redirectUrl);
}
@ -517,8 +518,8 @@ class EntryController extends AbstractController
);
// don't redirect user to the deleted entry (check that the referer doesn't end with the same url)
$referer = $request->headers->get('referer');
$to = (1 !== preg_match('#' . $url . '$#i', $referer) ? $referer : null);
$prev = $request->getSession()->get('prevUrl');
$to = (1 !== preg_match('#' . $url . '$#i', $prev) ? $prev : null);
$redirectUrl = $this->redirectHelper->to($to);
@ -616,6 +617,7 @@ class EntryController extends AbstractController
{
$searchTerm = (isset($request->get('search_entry')['term']) ? $request->get('search_entry')['term'] : '');
$currentRoute = (null !== $request->query->get('currentRoute') ? $request->query->get('currentRoute') : '');
$request->getSession()->set('prevUrl', $request->getRequestUri());
$formOptions = [];

View File

@ -1,40 +0,0 @@
<?php
namespace Wallabag\CoreBundle\Controller;
use Symfony\Bundle\TwigBundle\Controller\ExceptionController as BaseExceptionController;
use Symfony\Component\HttpFoundation\Request;
/**
* This controller allow us to customize the error template.
* The only modified line from the parent template is for "WallabagCoreBundle".
*/
class ExceptionController extends BaseExceptionController
{
protected function findTemplate(Request $request, $format, $code, $showException)
{
$name = $showException ? 'exception' : 'error';
if ($showException && 'html' === $format) {
$name = 'exception_full';
}
// For error pages, try to find a template for the specific HTTP status code and format
if (!$showException) {
$template = sprintf('@WallabagCore/Exception/%s.%s.twig', $name, $format);
if ($this->templateExists($template)) {
return $template;
}
}
// try to find a template for the given format
$template = sprintf('@Twig/Exception/%s.%s.twig', $name, $format);
if ($this->templateExists($template)) {
return $template;
}
// default to a generic HTML exception
$request->setRequestFormat('html');
return sprintf('@Twig/Exception/%s.html.twig', $showException ? 'exception_full' : $name);
}
}

View File

@ -61,13 +61,21 @@ class ExportController extends AbstractController
*
* @return Response
*/
public function downloadEntriesAction(Request $request, EntryRepository $entryRepository, TagRepository $tagRepository, EntriesExport $entriesExport, string $format, string $category)
public function downloadEntriesAction(Request $request, EntryRepository $entryRepository, TagRepository $tagRepository, EntriesExport $entriesExport, string $format, string $category, int $entry = 0)
{
$method = ucfirst($category);
$methodBuilder = 'getBuilderFor' . $method . 'ByUser';
$title = $method;
if ('tag_entries' === $category) {
if ('same_domain' === $category) {
$entries = $entryRepository->getBuilderForSameDomainByUser(
$this->getUser()->getId(),
$request->get('entry')
)->getQuery()
->getResult();
$title = 'Same domain';
} elseif ('tag_entries' === $category) {
$tag = $tagRepository->findOneBySlug($request->query->get('tag'));
$entries = $entryRepository->findAllByTagId(

View File

@ -104,7 +104,7 @@ class TagController extends AbstractController
$this->entityManager->flush();
}
$redirectUrl = $this->redirectHelper->to($request->headers->get('referer'), '', true);
$redirectUrl = $this->redirectHelper->to($request->getSession()->get('prevUrl'), '', true);
return $this->redirect($redirectUrl);
}
@ -185,7 +185,7 @@ class TagController extends AbstractController
$form = $this->createForm(RenameTagType::class, new Tag());
$form->handleRequest($request);
$redirectUrl = $this->redirectHelper->to($request->headers->get('referer'), '', true);
$redirectUrl = $this->redirectHelper->to($request->getSession()->get('prevUrl'), '', true);
if ($form->isSubmitted() && $form->isValid()) {
$newTag = new Tag();
@ -257,7 +257,7 @@ class TagController extends AbstractController
$this->entityManager->flush();
}
return $this->redirect($this->redirectHelper->to($request->headers->get('referer'), '', true));
return $this->redirect($this->redirectHelper->to($request->getSession()->get('prevUrl'), '', true));
}
/**
@ -279,8 +279,7 @@ class TagController extends AbstractController
$this->entityManager->remove($tag);
$this->entityManager->flush();
}
$redirectUrl = $this->redirectHelper->to($request->headers->get('referer'), '', true);
$redirectUrl = $this->redirectHelper->to($request->getSession()->get('prevUrl'), '', true);
return $this->redirect($redirectUrl);
}

View File

@ -7,6 +7,7 @@ use Doctrine\Common\DataFixtures\DependentFixtureInterface;
use Doctrine\Persistence\ObjectManager;
use Wallabag\CoreBundle\Entity\Config;
use Wallabag\UserBundle\DataFixtures\UserFixtures;
use Wallabag\UserBundle\Entity\User;
class ConfigFixtures extends Fixture implements DependentFixtureInterface
{
@ -15,7 +16,7 @@ class ConfigFixtures extends Fixture implements DependentFixtureInterface
*/
public function load(ObjectManager $manager): void
{
$adminConfig = new Config($this->getReference('admin-user'));
$adminConfig = new Config($this->getReference('admin-user', User::class));
$adminConfig->setItemsPerPage(30);
$adminConfig->setReadingSpeed(200);
@ -29,7 +30,7 @@ class ConfigFixtures extends Fixture implements DependentFixtureInterface
$this->addReference('admin-config', $adminConfig);
$bobConfig = new Config($this->getReference('bob-user'));
$bobConfig = new Config($this->getReference('bob-user', User::class));
$bobConfig->setItemsPerPage(10);
$bobConfig->setReadingSpeed(200);
$bobConfig->setLanguage('fr');
@ -42,7 +43,7 @@ class ConfigFixtures extends Fixture implements DependentFixtureInterface
$this->addReference('bob-config', $bobConfig);
$emptyConfig = new Config($this->getReference('empty-user'));
$emptyConfig = new Config($this->getReference('empty-user', User::class));
$emptyConfig->setItemsPerPage(10);
$emptyConfig->setReadingSpeed(100);
$emptyConfig->setLanguage('en');

View File

@ -6,7 +6,9 @@ use Doctrine\Bundle\FixturesBundle\Fixture;
use Doctrine\Common\DataFixtures\DependentFixtureInterface;
use Doctrine\Persistence\ObjectManager;
use Wallabag\CoreBundle\Entity\Entry;
use Wallabag\CoreBundle\Entity\Tag;
use Wallabag\UserBundle\DataFixtures\UserFixtures;
use Wallabag\UserBundle\Entity\User;
class EntryFixtures extends Fixture implements DependentFixtureInterface
{
@ -87,7 +89,7 @@ class EntryFixtures extends Fixture implements DependentFixtureInterface
];
foreach ($entries as $reference => $item) {
$entry = new Entry($this->getReference($item['user']));
$entry = new Entry($this->getReference($item['user'], User::class));
$entry->setUrl($item['url']);
$entry->setReadingTime($item['reading_time']);
$entry->setDomainName($item['domain']);
@ -98,7 +100,7 @@ class EntryFixtures extends Fixture implements DependentFixtureInterface
if (isset($item['tags'])) {
foreach ($item['tags'] as $tag) {
$entry->addTag($this->getReference($tag));
$entry->addTag($this->getReference($tag, Tag::class));
}
}

View File

@ -7,6 +7,7 @@ use Doctrine\Common\DataFixtures\DependentFixtureInterface;
use Doctrine\Persistence\ObjectManager;
use Wallabag\CoreBundle\Entity\IgnoreOriginUserRule;
use Wallabag\UserBundle\DataFixtures\UserFixtures;
use Wallabag\UserBundle\Entity\User;
class IgnoreOriginUserRuleFixtures extends Fixture implements DependentFixtureInterface
{
@ -17,7 +18,7 @@ class IgnoreOriginUserRuleFixtures extends Fixture implements DependentFixtureIn
{
$rule = new IgnoreOriginUserRule();
$rule->setRule('host = "example.fr"');
$rule->setConfig($this->getReference('admin-user')->getConfig());
$rule->setConfig($this->getReference('admin-user', User::class)->getConfig());
$manager->persist($rule);

View File

@ -10,6 +10,7 @@ use Symfony\Component\DependencyInjection\ContainerInterface;
use Wallabag\CoreBundle\Entity\SiteCredential;
use Wallabag\CoreBundle\Helper\CryptoProxy;
use Wallabag\UserBundle\DataFixtures\UserFixtures;
use Wallabag\UserBundle\Entity\User;
class SiteCredentialFixtures extends Fixture implements DependentFixtureInterface, ContainerAwareInterface
{
@ -28,14 +29,14 @@ class SiteCredentialFixtures extends Fixture implements DependentFixtureInterfac
*/
public function load(ObjectManager $manager): void
{
$credential = new SiteCredential($this->getReference('admin-user'));
$credential = new SiteCredential($this->getReference('admin-user', User::class));
$credential->setHost('.super.com');
$credential->setUsername($this->container->get(CryptoProxy::class)->crypt('.super'));
$credential->setPassword($this->container->get(CryptoProxy::class)->crypt('bar'));
$manager->persist($credential);
$credential = new SiteCredential($this->getReference('admin-user'));
$credential = new SiteCredential($this->getReference('admin-user', User::class));
$credential->setHost('paywall.example.com');
$credential->setUsername($this->container->get(CryptoProxy::class)->crypt('paywall.example'));
$credential->setPassword($this->container->get(CryptoProxy::class)->crypt('bar'));

View File

@ -5,6 +5,7 @@ namespace Wallabag\CoreBundle\DataFixtures;
use Doctrine\Bundle\FixturesBundle\Fixture;
use Doctrine\Common\DataFixtures\DependentFixtureInterface;
use Doctrine\Persistence\ObjectManager;
use Wallabag\CoreBundle\Entity\Config;
use Wallabag\CoreBundle\Entity\TaggingRule;
class TaggingRuleFixtures extends Fixture implements DependentFixtureInterface
@ -17,14 +18,14 @@ class TaggingRuleFixtures extends Fixture implements DependentFixtureInterface
$tr1 = new TaggingRule();
$tr1->setRule('content matches "spurs"');
$tr1->setTags(['sport']);
$tr1->setConfig($this->getReference('admin-config'));
$tr1->setConfig($this->getReference('admin-config', Config::class));
$manager->persist($tr1);
$tr2 = new TaggingRule();
$tr2->setRule('content matches "basket"');
$tr2->setTags(['sport']);
$tr2->setConfig($this->getReference('admin-config'));
$tr2->setConfig($this->getReference('admin-config', Config::class));
$manager->persist($tr2);
@ -32,28 +33,28 @@ class TaggingRuleFixtures extends Fixture implements DependentFixtureInterface
$tr3->setRule('title matches "wallabag"');
$tr3->setTags(['wallabag']);
$tr3->setConfig($this->getReference('admin-config'));
$tr3->setConfig($this->getReference('admin-config', Config::class));
$manager->persist($tr3);
$tr4 = new TaggingRule();
$tr4->setRule('content notmatches "basket"');
$tr4->setTags(['foot']);
$tr4->setConfig($this->getReference('admin-config'));
$tr4->setConfig($this->getReference('admin-config', Config::class));
$manager->persist($tr4);
$tr5 = new TaggingRule();
$tr5->setRule('readingTime <= 5');
$tr5->setTags(['shortread']);
$tr5->setConfig($this->getReference('empty-config'));
$tr5->setConfig($this->getReference('empty-config', Config::class));
$manager->persist($tr5);
$tr6 = new TaggingRule();
$tr6->setRule('readingTime > 5');
$tr6->setTags(['longread']);
$tr6->setConfig($this->getReference('empty-config'));
$tr6->setConfig($this->getReference('empty-config', Config::class));
$manager->persist($tr6);

View File

@ -2,6 +2,7 @@
namespace Wallabag\CoreBundle\Doctrine;
use Doctrine\DBAL\Platforms\PostgreSQLPlatform;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
use Symfony\Component\DependencyInjection\ContainerAwareInterface;
@ -49,7 +50,7 @@ abstract class WallabagMigration extends AbstractMigration implements ContainerA
}
// escape table name is handled using " on postgresql
if ('postgresql' === $this->connection->getDatabasePlatform()->getName()) {
if ($this->connection->getDatabasePlatform() instanceof PostgreSQLPlatform) {
return '"' . $table . '"';
}

View File

@ -3,7 +3,7 @@
namespace Wallabag\CoreBundle\Event\Listener;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
use Symfony\Component\HttpKernel\Event\GetResponseEvent;
use Symfony\Component\HttpKernel\Event\RequestEvent;
use Symfony\Component\HttpKernel\KernelEvents;
/**
@ -18,7 +18,7 @@ class LocaleListener implements EventSubscriberInterface
$this->defaultLocale = $defaultLocale;
}
public function onKernelRequest(GetResponseEvent $event)
public function onKernelRequest(RequestEvent $event)
{
$request = $event->getRequest();
if (!$request->hasPreviousSession()) {

View File

@ -9,10 +9,11 @@ use Http\Client\Common\HttpMethodsClient;
use Http\Client\Common\Plugin\ErrorPlugin;
use Http\Client\Common\Plugin\RedirectPlugin;
use Http\Client\Common\PluginClient;
use Http\Client\HttpClient;
use Http\Discovery\MessageFactoryDiscovery;
use Http\Message\MessageFactory;
use Http\Discovery\Psr17FactoryDiscovery;
use Psr\Http\Client\ClientInterface;
use Psr\Http\Message\RequestFactoryInterface;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\StreamFactoryInterface;
use Psr\Log\LoggerInterface;
use Symfony\Component\DomCrawler\Crawler;
use Symfony\Component\Finder\Finder;
@ -28,9 +29,9 @@ class DownloadImages
private $mimeTypes;
private $wallabagUrl;
public function __construct(HttpClient $client, $baseFolder, $wallabagUrl, LoggerInterface $logger, MessageFactory $messageFactory = null)
public function __construct(ClientInterface $client, $baseFolder, $wallabagUrl, LoggerInterface $logger, RequestFactoryInterface $requestFactory = null, StreamFactoryInterface $streamFactory = null)
{
$this->client = new HttpMethodsClient(new PluginClient($client, [new ErrorPlugin(), new RedirectPlugin()]), $messageFactory ?: MessageFactoryDiscovery::find());
$this->client = new HttpMethodsClient(new PluginClient($client, [new ErrorPlugin(), new RedirectPlugin()]), $requestFactory ?: Psr17FactoryDiscovery::findRequestFactory(), $streamFactory ?: Psr17FactoryDiscovery::findStreamFactory());
$this->baseFolder = $baseFolder;
$this->wallabagUrl = rtrim($wallabagUrl, '/');
$this->logger = $logger;

View File

@ -209,38 +209,36 @@
{{ form_widget(form.user.save, {'attr': {'class': 'btn waves-effect waves-light'}}) }}
{% if twofactor_auth %}
<br/>
<br/>
<div class="row">
<h5>{{ 'config.otp.page_title'|trans }}</h5>
<br/>
<br/>
<div class="row">
<h5>{{ 'config.otp.page_title'|trans }}</h5>
<p>{{ 'config.form_user.two_factor_description'|trans }}</p>
<p>{{ 'config.form_user.two_factor_description'|trans }}</p>
<table>
<thead>
<tr>
<th>{{ 'config.form_user.two_factor.table_method'|trans }}</th>
<th>{{ 'config.form_user.two_factor.table_state'|trans }}</th>
<th>{{ 'config.form_user.two_factor.table_action'|trans }}</th>
</tr>
</thead>
<table>
<thead>
<tr>
<th>{{ 'config.form_user.two_factor.table_method'|trans }}</th>
<th>{{ 'config.form_user.two_factor.table_state'|trans }}</th>
<th>{{ 'config.form_user.two_factor.table_action'|trans }}</th>
</tr>
</thead>
<tbody>
<tr>
<td>{{ 'config.form_user.two_factor.emailTwoFactor_label'|trans }}</td>
<td>{% if app.user.isEmailTwoFactor %}<b>{{ 'config.form_user.two_factor.state_enabled'|trans }}</b>{% else %}{{ 'config.form_user.two_factor.state_disabled'|trans }}{% endif %}</td>
<td><a href="{{ path('config_otp_email') }}" class="waves-effect waves-light btn{% if app.user.isEmailTwoFactor %} disabled{% endif %}">{{ 'config.form_user.two_factor.action_email'|trans }}</a> {% if app.user.isEmailTwoFactor %}<a href="{{ path('disable_otp_email') }}" class="waves-effect waves-light btn red">Disable</a>{% endif %}</td>
</tr>
<tr>
<td>{{ 'config.form_user.two_factor.googleTwoFactor_label'|trans }}</td>
<td>{% if app.user.isGoogleTwoFactor %}<b>{{ 'config.form_user.two_factor.state_enabled'|trans }}</b>{% else %}{{ 'config.form_user.two_factor.state_disabled'|trans }}{% endif %}</td>
<td><a href="{{ path('config_otp_app') }}" class="waves-effect waves-light btn{% if app.user.isGoogleTwoFactor %} disabled{% endif %}">{{ 'config.form_user.two_factor.action_app'|trans }}</a> {% if app.user.isGoogleTwoFactor %}<a href="{{ path('disable_otp_app') }}" class="waves-effect waves-light btn red">Disable</a>{% endif %}</td>
</tr>
</tbody>
</table>
</div>
{% endif %}
<tbody>
<tr>
<td>{{ 'config.form_user.two_factor.emailTwoFactor_label'|trans }}</td>
<td>{% if app.user.isEmailTwoFactor %}<b>{{ 'config.form_user.two_factor.state_enabled'|trans }}</b>{% else %}{{ 'config.form_user.two_factor.state_disabled'|trans }}{% endif %}</td>
<td><a href="{{ path('config_otp_email') }}" class="waves-effect waves-light btn{% if app.user.isEmailTwoFactor %} disabled{% endif %}">{{ 'config.form_user.two_factor.action_email'|trans }}</a> {% if app.user.isEmailTwoFactor %}<a href="{{ path('disable_otp_email') }}" class="waves-effect waves-light btn red">Disable</a>{% endif %}</td>
</tr>
<tr>
<td>{{ 'config.form_user.two_factor.googleTwoFactor_label'|trans }}</td>
<td>{% if app.user.isGoogleTwoFactor %}<b>{{ 'config.form_user.two_factor.state_enabled'|trans }}</b>{% else %}{{ 'config.form_user.two_factor.state_disabled'|trans }}{% endif %}</td>
<td><a href="{{ path('config_otp_app') }}" class="waves-effect waves-light btn{% if app.user.isGoogleTwoFactor %} disabled{% endif %}">{{ 'config.form_user.two_factor.action_app'|trans }}</a> {% if app.user.isGoogleTwoFactor %}<a href="{{ path('disable_otp_app') }}" class="waves-effect waves-light btn red">Disable</a>{% endif %}</td>
</tr>
</tbody>
</table>
</div>
{{ form_widget(form.user._token) }}
</form>
</div>
@ -554,18 +552,34 @@
<div class="row">
<h5>{{ 'config.reset.title'|trans }}</h5>
<p>{{ 'config.reset.description'|trans }}</p>
<a href="{{ path('config_reset', {type: 'annotations'}) }}" onclick="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" class="waves-effect waves-light btn red">
{{ 'config.reset.annotations'|trans }}
</a>
<a href="{{ path('config_reset', {type: 'tags'}) }}" onclick="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" class="waves-effect waves-light btn red">
{{ 'config.reset.tags'|trans }}
</a>
<a href="{{ path('config_reset', {type: 'archived'}) }}" onclick="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" class="waves-effect waves-light btn red">
{{ 'config.reset.archived'|trans }}
</a>
<a href="{{ path('config_reset', {type: 'entries'}) }}" onclick="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" class="waves-effect waves-light btn red">
{{ 'config.reset.entries'|trans }}
</a>
<p>
<form action="{{ path('config_reset', {type: 'annotations'}) }}" method="post" onsubmit="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" name="reset-annotations">
<input type="hidden" name="token" value="{{ csrf_token('reset-area') }}" />
<button class="waves-effect waves-light btn red" type="submit">{{ 'config.reset.annotations'|trans }}</button>
</form>
</p>
<p>
<form action="{{ path('config_reset', {type: 'tags'}) }}" method="post" onsubmit="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" name="reset-tags">
<input type="hidden" name="token" value="{{ csrf_token('reset-area') }}" />
<button class="waves-effect waves-light btn red" type="submit">{{ 'config.reset.tags'|trans }}</button>
</form>
</p>
<p>
<form action="{{ path('config_reset', {type: 'archived'}) }}" method="post" onsubmit="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" name="reset-archived">
<input type="hidden" name="token" value="{{ csrf_token('reset-area') }}" />
<button class="waves-effect waves-light btn red" type="submit">{{ 'config.reset.archived'|trans }}</button>
</form>
</p>
<p>
<form action="{{ path('config_reset', {type: 'entries'}) }}" method="post" onsubmit="return confirm('{{ 'config.reset.confirm'|trans|escape('js') }}')" name="reset-entries">
<input type="hidden" name="token" value="{{ csrf_token('reset-area') }}" />
<button class="waves-effect waves-light btn red" type="submit">{{ 'config.reset.entries'|trans }}</button>
</form>
</p>
</div>
{% if enabled_users > 1 %}

View File

@ -2,11 +2,6 @@
{% block title %}{{ 'developer.howto.page_title'|trans }}{% endblock %}
{% block css %}
{{ parent() }}
<link rel="stylesheet" href="{{ asset('https://cdnjs.cloudflare.com/ajax/libs/prism/1.4.1/themes/prism-dark.min.css') }}">
{% endblock %}
{% block content %}
<div class="row">
<div class="col s12">
@ -18,7 +13,7 @@
<p>{{ 'developer.howto.description.paragraph_3'|trans({'%link%': path('developer_create_client')})|raw }}</p>
<p>{{ 'developer.howto.description.paragraph_4'|trans }}</p>
<p>
<pre><code class="language-bash">http POST https://app.wallabag.it/oauth/v2/token \
<pre><code class="language-bash">http POST {{ wallabag_url }}/oauth/v2/token \
grant_type=password \
client_id=12_5um6nz50ceg4088c0840wwc0kgg44g00kk84og044ggkscso0k \
client_secret=3qd12zpeaxes8cwg8c0404g888co4wo8kc4gcw0occww8cgw4k \
@ -47,7 +42,7 @@ X-Powered-By: PHP/5.5.9-1ubuntu4.13
</p>
<p>{{ 'developer.howto.description.paragraph_6'|trans }}</p>
<p>
<pre><code class="language-bash">http GET https://app.wallabag.it/api/entries.json \
<pre><code class="language-bash">http GET {{ wallabag_url }}/api/entries.json \
"Authorization:Bearer ZWFjNjA3ZWMwYWVmYzRkYTBlMmQ3NTllYmVhOGJiZDE0ZTg1NjE4MjczOTVlNzM0ZTRlMWQ0MmRlMmYwNTk5Mw"</code></pre>
</p>
<p>{{ 'developer.howto.description.paragraph_7'|trans }}</p>
@ -58,6 +53,4 @@ X-Powered-By: PHP/5.5.9-1ubuntu4.13
</div>
</div>
</div>
<script src="{{ asset('https://cdnjs.cloudflare.com/ajax/libs/prism/1.4.1/prism.min.js') }}"></script>
<script src="{{ asset('https://cdnjs.cloudflare.com/ajax/libs/prism/1.4.1/components/prism-bash.min.js') }}"></script>
{% endblock %}

View File

@ -57,9 +57,11 @@
<p>{{ 'developer.remove.warn_message_1'|trans({'%name%': client.name}) }}</p>
<p>{{ 'developer.remove.warn_message_2'|trans({'%name%': client.name}) }}</p>
<p>
<a class="waves-effect waves-light red btn" href="{{ path('developer_delete_client', {'id': client.id}) }}">{{ 'developer.remove.action'|trans({'%name%': client.name}) }}</a>
</p>
<form action="{{ path('developer_delete_client', {id: client.id}) }}" method="post" name="delete-client">
<input type="hidden" name="token" value="{{ csrf_token('delete-client') }}" />
<button class="waves-effect waves-light btn red" type="submit">{{ 'developer.remove.action'|trans({'%name%': client.name}) }}</button>
</form>
</div>
</li>
{% endfor %}

View File

@ -9,6 +9,6 @@
{% set feed_route = feed_route ~ '_feed' %}
{% set slug = null %}
{% endif %}
{% if feed_route %}
{% if feed_route is defined %}
<a rel="alternate" type="application/atom+xml" href="{{ path(feed_route, {'username': app.user.username, 'token': app.user.config.feedToken, 'slug': slug}) }}" class="results-item"><i class="material-icons">rss_feed</i></a>
{% endif %}

View File

@ -28,7 +28,7 @@
<form name="form_mass_action" action="{{ path('mass_action') }}" method="post">
<div class="results">
<div class="nb-results">
{{ 'entry.list.number_on_the_page'|transchoice(entries.count) }}
{{ 'entry.list.number_on_the_page'|trans({'%count%': entries.count}) }}
{% if entries.count > 0 %}
<a class="results-item" href="{{ path('switch_view_mode') }}"><i class="material-icons">{% if list_mode == 0 %}view_list{% else %}view_module{% endif %}</i></a>
{% endif %}
@ -96,16 +96,17 @@
{% if searchTerm is defined %}
{% set export_search_term = searchTerm %}
{% endif %}
{% set entry = app.request.attributes.get('id') %}
{% set previous_route = app.request.attributes.get('currentRoute') %}
<h4 class="center">{{ 'entry.list.export_title'|trans }}</h4>
<ul>
{% if craue_setting('export_epub') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'epub', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route}) }}">EPUB</a></li>{% endif %}
{% if craue_setting('export_mobi') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'mobi', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route}) }}">MOBI (deprecated)</a></li>{% endif %}
{% if craue_setting('export_pdf') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'pdf', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route}) }}">PDF</a></li>{% endif %}
{% if craue_setting('export_json') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'json', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route}) }}">JSON</a></li>{% endif %}
{% if craue_setting('export_csv') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'csv', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route}) }}">CSV</a></li>{% endif %}
{% if craue_setting('export_txt') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'txt', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route}) }}">TXT</a></li>{% endif %}
{% if craue_setting('export_xml') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'xml', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route}) }}">XML</a></li>{% endif %}
{% if craue_setting('export_epub') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'epub', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route, 'entry': entry}) }}">EPUB</a></li>{% endif %}
{% if craue_setting('export_mobi') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'mobi', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route, 'entry': entry}) }}">MOBI (deprecated)</a></li>{% endif %}
{% if craue_setting('export_pdf') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'pdf', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route, 'entry': entry}) }}">PDF</a></li>{% endif %}
{% if craue_setting('export_json') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'json', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route, 'entry': entry}) }}">JSON</a></li>{% endif %}
{% if craue_setting('export_csv') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'csv', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route, 'entry': entry}) }}">CSV</a></li>{% endif %}
{% if craue_setting('export_txt') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'txt', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route, 'entry': entry}) }}">TXT</a></li>{% endif %}
{% if craue_setting('export_xml') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', {'category': current_route, 'format': 'xml', 'tag': current_tag, 'search_entry[term]': export_search_term, 'currentRoute': previous_route, 'entry': entry}) }}">XML</a></li>{% endif %}
</ul>
</div>

View File

@ -54,7 +54,7 @@
</li>
<li class="bold">
<a class="waves-effect collapsible-header" title="{{ 'entry.view.left_menu.re_fetch_content'|trans }}" href="{{ path('reload_entry', {'id': entry.id}) }}" id="reload">
<a class="waves-effect collapsible-header" onclick="return confirm('{{ 'entry.confirm.reload'|trans|escape('js') }}')" title="{{ 'entry.view.left_menu.re_fetch_content'|trans }}" href="{{ path('reload_entry', {'id': entry.id}) }}" id="reload">
<i class="material-icons small">refresh</i>
<span>{{ 'entry.view.left_menu.re_fetch_content'|trans }}</span>
</a>
@ -269,7 +269,7 @@
{% if entry.annotations|length %}
<li>
<i class="material-icons grey-text">comment</i>
{{ 'entry.view.annotations_on_the_entry'|transchoice(entry.annotations|length) }}
{{ 'entry.view.annotations_on_the_entry'|trans({'%count%': entry.annotations|length}) }}
</li>
{% endif %}
{% if entry.originUrl is not empty %}

View File

@ -4,7 +4,7 @@
{% block content %}
<div class="results clearfix">
{{ 'tag.list.number_on_the_page'|transchoice(tags|length) }}
{{ 'tag.list.number_on_the_page'|trans({'%count%': tags|length}) }}
</div>
<div class="row">

View File

@ -19,16 +19,16 @@ class WallabagExtension extends AbstractExtension implements GlobalsInterface
private $tagRepository;
private $lifeTime;
private $translator;
private $rootDir;
private $projectDir;
public function __construct(EntryRepository $entryRepository, TagRepository $tagRepository, TokenStorageInterface $tokenStorage, $lifeTime, TranslatorInterface $translator, string $rootDir)
public function __construct(EntryRepository $entryRepository, TagRepository $tagRepository, TokenStorageInterface $tokenStorage, $lifeTime, TranslatorInterface $translator, string $projectDir)
{
$this->entryRepository = $entryRepository;
$this->tagRepository = $tagRepository;
$this->tokenStorage = $tokenStorage;
$this->lifeTime = $lifeTime;
$this->translator = $translator;
$this->rootDir = $rootDir;
$this->projectDir = $projectDir;
}
public function getGlobals(): array
@ -174,7 +174,7 @@ class WallabagExtension extends AbstractExtension implements GlobalsInterface
public function assetFileExists($name)
{
return file_exists(realpath($this->rootDir . '/../web/' . $name));
return file_exists(realpath($this->projectDir . '/web/' . $name));
}
public function themeClass()

View File

@ -4,13 +4,13 @@ namespace Wallabag\ImportBundle\Controller;
use Craue\ConfigBundle\Util\Config;
use Predis\Client;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;
use Wallabag\ImportBundle\Consumer\RabbitMQConsumerTotalProxy;
use Wallabag\ImportBundle\Import\ImportChain;
class ImportController extends Controller
class ImportController extends AbstractController
{
private RabbitMQConsumerTotalProxy $rabbitMQConsumerTotalProxy;

View File

@ -6,10 +6,11 @@ use Http\Client\Common\HttpMethodsClient;
use Http\Client\Common\Plugin\ErrorPlugin;
use Http\Client\Common\PluginClient;
use Http\Client\Exception\RequestException;
use Http\Client\HttpClient;
use Http\Discovery\MessageFactoryDiscovery;
use Http\Message\MessageFactory;
use Http\Discovery\Psr17FactoryDiscovery;
use Psr\Http\Client\ClientInterface;
use Psr\Http\Message\RequestFactoryInterface;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\StreamFactoryInterface;
use Wallabag\CoreBundle\Entity\Entry;
class PocketImport extends AbstractImport
@ -152,9 +153,9 @@ class PocketImport extends AbstractImport
/**
* Set the Http client.
*/
public function setClient(HttpClient $client, MessageFactory $messageFactory = null)
public function setClient(ClientInterface $client, RequestFactoryInterface $requestFactory = null, StreamFactoryInterface $streamFactory = null)
{
$this->client = new HttpMethodsClient(new PluginClient($client, [new ErrorPlugin()]), $messageFactory ?: MessageFactoryDiscovery::find());
$this->client = new HttpMethodsClient(new PluginClient($client, [new ErrorPlugin()]), $requestFactory ?: Psr17FactoryDiscovery::findRequestFactory(), $streamFactory ?: Psr17FactoryDiscovery::findStreamFactory());
}
/**

View File

@ -85,19 +85,17 @@ class ManageController extends AbstractController
$form->handleRequest($request);
// `googleTwoFactor` isn't a field within the User entity, we need to define it's value in a different way
if ($this->getParameter('twofactor_auth') && true === $user->isGoogleAuthenticatorEnabled() && false === $form->isSubmitted()) {
if (true === $user->isGoogleAuthenticatorEnabled() && false === $form->isSubmitted()) {
$form->get('googleTwoFactor')->setData(true);
}
if ($form->isSubmitted() && $form->isValid()) {
// handle creation / reset of the OTP secret if checkbox changed from the previous state
if ($this->getParameter('twofactor_auth')) {
if (true === $form->get('googleTwoFactor')->getData() && false === $user->isGoogleAuthenticatorEnabled()) {
$user->setGoogleAuthenticatorSecret($googleAuthenticator->generateSecret());
$user->setEmailTwoFactor(false);
} elseif (false === $form->get('googleTwoFactor')->getData() && true === $user->isGoogleAuthenticatorEnabled()) {
$user->setGoogleAuthenticatorSecret(null);
}
if (true === $form->get('googleTwoFactor')->getData() && false === $user->isGoogleAuthenticatorEnabled()) {
$user->setGoogleAuthenticatorSecret($googleAuthenticator->generateSecret());
$user->setEmailTwoFactor(false);
} elseif (false === $form->get('googleTwoFactor')->getData() && true === $user->isGoogleAuthenticatorEnabled()) {
$user->setGoogleAuthenticatorSecret(null);
}
$userManager->updateUser($user);
@ -114,7 +112,6 @@ class ManageController extends AbstractController
'user' => $user,
'edit_form' => $form->createView(),
'delete_form' => $deleteForm->createView(),
'twofactor_auth' => $this->getParameter('twofactor_auth'),
]);
}

View File

@ -8,6 +8,8 @@ use FOS\UserBundle\Model\User as BaseUser;
use JMS\Serializer\Annotation\Accessor;
use JMS\Serializer\Annotation\Groups;
use JMS\Serializer\Annotation\XmlRoot;
use Nelmio\ApiDocBundle\Annotation\Model;
use OpenApi\Annotations as OA;
use Scheb\TwoFactorBundle\Model\BackupCodeInterface;
use Scheb\TwoFactorBundle\Model\Email\TwoFactorInterface as EmailTwoFactorInterface;
use Scheb\TwoFactorBundle\Model\Google\TwoFactorInterface as GoogleTwoFactorInterface;
@ -40,6 +42,12 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
* @ORM\Id
* @ORM\GeneratedValue(strategy="AUTO")
*
* @OA\Property(
* description="The unique numeric id of the user",
* type="int",
* example=12,
* )
*
* @Groups({"user_api", "user_api_with_client"})
*/
protected $id;
@ -49,6 +57,12 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
*
* @ORM\Column(name="name", type="text", nullable=true)
*
* @OA\Property(
* description="The personal Name of the user",
* type="string",
* example="Walla Baggger",
* )
*
* @Groups({"user_api", "user_api_with_client"})
*/
protected $name;
@ -56,6 +70,12 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
/**
* @var string
*
* @OA\Property(
* description="The unique username of the user",
* type="string",
* example="wallabag",
* )
*
* @Groups({"user_api", "user_api_with_client"})
*/
protected $username;
@ -63,6 +83,12 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
/**
* @var string
*
* @OA\Property(
* description="E-mail address of the user",
* type="string",
* example="wallabag@wallabag.io",
* )
*
* @Groups({"user_api", "user_api_with_client"})
*/
protected $email;
@ -72,6 +98,12 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
*
* @ORM\Column(name="created_at", type="datetime")
*
* @OA\Property(
* description="Creation date of the user account. (In ISO 8601 format)",
* type="string",
* example="2023-06-27T19:25:44+0000",
* )
*
* @Groups({"user_api", "user_api_with_client"})
*/
protected $createdAt;
@ -81,6 +113,12 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
*
* @ORM\Column(name="updated_at", type="datetime")
*
* @OA\Property(
* description="Update date of the user account. (In ISO 8601 format)",
* type="string",
* example="2023-06-27T19:37:30+0000",
* )
*
* @Groups({"user_api", "user_api_with_client"})
*/
protected $updatedAt;
@ -112,6 +150,11 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
/**
* @see getFirstClient() below
*
* @OA\Property(
* description="Default client created during user registration. Used for further authorization",
* ref=@Model(type=Client::class, groups={"user_api_with_client"})
* )
*
* @Groups({"user_api_with_client"})
* @Accessor(getter="getFirstClient")
*/

View File

@ -47,7 +47,6 @@
</div>
</div>
{% if twofactor_auth %}
<div class="row">
<div class="input-field col s12">
{{ form_widget(edit_form.emailTwoFactor) }}
@ -60,7 +59,6 @@
{{ form_errors(edit_form.googleTwoFactor) }}
</div>
</div>
{% endif %}
<br/>

View File

@ -5,7 +5,7 @@ namespace Tests\Wallabag\AnnotationBundle;
use FOS\UserBundle\Model\UserInterface;
use FOS\UserBundle\Model\UserManager;
use FOS\UserBundle\Security\LoginManager;
use Symfony\Bundle\FrameworkBundle\Client;
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
use Symfony\Component\BrowserKit\Cookie;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
@ -14,7 +14,7 @@ use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInt
abstract class WallabagAnnotationTestCase extends WebTestCase
{
/**
* @var Client
* @var KernelBrowser
*/
protected $client = null;
@ -42,7 +42,7 @@ abstract class WallabagAnnotationTestCase extends WebTestCase
}
/**
* @return Client
* @return KernelBrowser
*/
protected function createAuthorizedClient()
{

View File

@ -104,20 +104,16 @@ class DeveloperControllerTest extends WallabagCoreTestCase
$this->assertStringContainsString('no_client', $client->getResponse()->getContent());
$this->logInAs('bob');
$client->request('GET', '/developer/client/delete/' . $adminApiClient->getId());
$client->request('POST', '/developer/client/delete/' . $adminApiClient->getId());
$this->assertSame(403, $client->getResponse()->getStatusCode());
// Try to remove the admin's client with the good user
$this->logInAs('admin');
$crawler = $client->request('GET', '/developer');
$link = $crawler
->filter('div[class=collapsible-body] p a')
->eq(0)
->link()
;
$form = $crawler->filter('form[name=delete-client]')->form();
$client->click($link);
$client->submit($form);
$this->assertSame(302, $client->getResponse()->getStatusCode());
$this->assertNull(

View File

@ -6,7 +6,7 @@ use Doctrine\ORM\EntityManagerInterface;
use FOS\UserBundle\Model\UserInterface;
use FOS\UserBundle\Model\UserManager;
use FOS\UserBundle\Security\LoginManager;
use Symfony\Bundle\FrameworkBundle\Client;
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
use Symfony\Component\BrowserKit\Cookie;
use Symfony\Component\HttpFoundation\Session\SessionInterface;
@ -16,7 +16,7 @@ use Wallabag\UserBundle\Entity\User;
abstract class WallabagApiTestCase extends WebTestCase
{
/**
* @var Client
* @var KernelBrowser
*/
protected $client = null;
@ -32,7 +32,7 @@ abstract class WallabagApiTestCase extends WebTestCase
}
/**
* @return Client
* @return KernelBrowser
*/
protected function createAuthorizedClient()
{

View File

@ -929,7 +929,8 @@ class ConfigControllerTest extends WallabagCoreTestCase
$this->assertSame(200, $client->getResponse()->getStatusCode());
$crawler = $client->click($crawler->selectLink('config.reset.annotations')->link());
$form = $crawler->filter('form[name=reset-annotations]')->form();
$client->submit($form);
$this->assertSame(302, $client->getResponse()->getStatusCode());
$this->assertStringContainsString('flashes.config.notice.annotations_reset', $client->getContainer()->get(SessionInterface::class)->getFlashBag()->get('notice')[0]);
@ -945,7 +946,8 @@ class ConfigControllerTest extends WallabagCoreTestCase
$this->assertSame(200, $client->getResponse()->getStatusCode());
$crawler = $client->click($crawler->selectLink('config.reset.tags')->link());
$form = $crawler->filter('form[name=reset-tags]')->form();
$client->submit($form);
$this->assertSame(302, $client->getResponse()->getStatusCode());
$this->assertStringContainsString('flashes.config.notice.tags_reset', $client->getContainer()->get(SessionInterface::class)->getFlashBag()->get('notice')[0]);
@ -961,7 +963,8 @@ class ConfigControllerTest extends WallabagCoreTestCase
$this->assertSame(200, $client->getResponse()->getStatusCode());
$crawler = $client->click($crawler->selectLink('config.reset.entries')->link());
$form = $crawler->filter('form[name=reset-entries]')->form();
$client->submit($form);
$this->assertSame(302, $client->getResponse()->getStatusCode());
$this->assertStringContainsString('flashes.config.notice.entries_reset', $client->getContainer()->get(SessionInterface::class)->getFlashBag()->get('notice')[0]);
@ -1027,7 +1030,8 @@ class ConfigControllerTest extends WallabagCoreTestCase
$this->assertSame(200, $client->getResponse()->getStatusCode());
$crawler = $client->click($crawler->selectLink('config.reset.archived')->link());
$form = $crawler->filter('form[name=reset-archived]')->form();
$client->submit($form);
$this->assertSame(302, $client->getResponse()->getStatusCode());
$this->assertStringContainsString('flashes.config.notice.archived_reset', $client->getContainer()->get(SessionInterface::class)->getFlashBag()->get('notice')[0]);
@ -1086,7 +1090,8 @@ class ConfigControllerTest extends WallabagCoreTestCase
$this->assertSame(200, $client->getResponse()->getStatusCode());
$crawler = $client->click($crawler->selectLink('config.reset.entries')->link());
$form = $crawler->filter('form[name=reset-entries]')->form();
$client->submit($form);
$this->assertSame(302, $client->getResponse()->getStatusCode());
$this->assertStringContainsString('flashes.config.notice.entries_reset', $client->getContainer()->get(SessionInterface::class)->getFlashBag()->get('notice')[0]);

View File

@ -1654,7 +1654,7 @@ class EntryControllerTest extends WallabagCoreTestCase
// As long as the deletion link of a tag is following
// a link to the tag view, we take the second one to retrieve
// the deletion link of the first tag
$link = $crawler->filter('body div#article div.tools ul.tags li.chip a')->extract('href')[1];
$link = $crawler->filter('body div#article div.tools ul.tags li.chip a')->extract(['href'])[1];
$this->assertSame(sprintf('/remove-tag/%s/%s', $entry->getId(), $tag->getId()), $link);
}

View File

@ -10,6 +10,8 @@ class ExportControllerTest extends WallabagCoreTestCase
{
private $adminEntry;
private $bobEntry;
private $sameDomainEntry;
private $sameDomainEntry2;
public function testLogin()
{
@ -326,6 +328,26 @@ class ExportControllerTest extends WallabagCoreTestCase
$this->assertNotEmpty('updated_at', (string) $content->entry[0]->updated_at);
}
public function testJsonExportFromSameDomain()
{
$this->logInAs('admin');
$client = $this->getTestClient();
ob_start();
$crawler = $client->request('GET', '/export/same_domain.json?entry=1');
ob_end_clean();
$this->assertSame(200, $client->getResponse()->getStatusCode());
$headers = $client->getResponse()->headers;
$this->assertSame('application/json', $headers->get('content-type'));
$this->assertSame('attachment; filename="Same domain articles.json"', $headers->get('content-disposition'));
$this->assertSame('UTF-8', $headers->get('content-transfer-encoding'));
$content = json_decode($client->getResponse()->getContent(), true);
$this->assertCount(4, $content);
}
private function setUpForJsonExportFromSearch()
{
$client = $this->getTestClient();

View File

@ -237,14 +237,18 @@ class FeedControllerTest extends WallabagCoreTestCase
$entry1->setCreatedAt($day1);
$entry4->setCreatedAt($day2);
$property = (new \ReflectionObject($entry1))->getProperty('updatedAt');
$property->setAccessible(true);
$property->setValue($entry1, $day4);
$property = (new \ReflectionObject($entry4))->getProperty('updatedAt');
$property->setAccessible(true);
$property->setValue($entry4, $day3);
// We have to flush and sleep here to be sure that $entry1 and $entry4 have different updatedAt values
$em->flush();
sleep(2);
$property = (new \ReflectionObject($entry1))->getProperty('updatedAt');
$property->setAccessible(true);
$property->setValue($entry1, $day4);
$em->flush();
$client = $this->getTestClient();

View File

@ -32,12 +32,6 @@ class SecurityControllerTest extends WallabagCoreTestCase
{
$client = $this->getTestClient();
if (!$client->getContainer()->getParameter('twofactor_auth')) {
$this->markTestSkipped('twofactor_auth is not enabled.');
return;
}
$client->followRedirects();
$em = $client->getContainer()->get(EntityManagerInterface::class);
@ -65,12 +59,6 @@ class SecurityControllerTest extends WallabagCoreTestCase
{
$client = $this->getTestClient();
if (!$client->getContainer()->getParameter('twofactor_auth')) {
$this->markTestSkipped('twofactor_auth is not enabled.');
return;
}
$client->followRedirects();
$em = $client->getContainer()->get(EntityManagerInterface::class);

View File

@ -4,7 +4,7 @@ namespace Tests\Wallabag\CoreBundle\Controller;
use Craue\ConfigBundle\Util\Config;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Bundle\FrameworkBundle\Client;
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
use Tests\Wallabag\CoreBundle\WallabagCoreTestCase;
use Wallabag\CoreBundle\Entity\SiteCredential;
@ -139,7 +139,7 @@ class SiteCredentialControllerTest extends WallabagCoreTestCase
$this->assertStringContainsString('flashes.site_credential.notice.deleted', $crawler->filter('body')->extract(['_text'])[0]);
}
private function createSiteCredential(Client $client)
private function createSiteCredential(KernelBrowser $client)
{
$credential = new SiteCredential($this->getLoggedInUser());
$credential->setHost('google.io');

View File

@ -124,7 +124,7 @@ class TagControllerTest extends WallabagCoreTestCase
// We make a first request to set an history and test redirection after tag deletion
$client->request('GET', '/view/' . $entry->getId());
$entryUri = $client->getRequest()->getUri();
$entryUri = $client->getRequest()->getRequestUri();
$client->request('GET', '/remove-tag/' . $entry->getId() . '/' . $tag->getId());
$this->assertSame(302, $client->getResponse()->getStatusCode());

View File

@ -7,7 +7,7 @@ use Symfony\Component\EventDispatcher\EventDispatcher;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Session\Session;
use Symfony\Component\HttpFoundation\Session\Storage\MockArraySessionStorage;
use Symfony\Component\HttpKernel\Event\GetResponseEvent;
use Symfony\Component\HttpKernel\Event\RequestEvent;
use Symfony\Component\HttpKernel\HttpKernelInterface;
use Symfony\Component\HttpKernel\KernelEvents;
use Wallabag\CoreBundle\Event\Listener\LocaleListener;
@ -82,6 +82,6 @@ class LocaleListenerTest extends TestCase
->disableOriginalConstructor()
->getMock();
return new GetResponseEvent($kernel, $request, HttpKernelInterface::MASTER_REQUEST);
return new RequestEvent($kernel, $request, HttpKernelInterface::MASTER_REQUEST);
}
}

View File

@ -3,8 +3,8 @@
namespace Tests\Wallabag\CoreBundle;
use Doctrine\ORM\EntityManagerInterface;
use Symfony\Bundle\FrameworkBundle\Client;
use Symfony\Bundle\FrameworkBundle\Console\Application;
use Symfony\Bundle\FrameworkBundle\KernelBrowser;
use Symfony\Bundle\FrameworkBundle\Test\WebTestCase;
use Symfony\Component\BrowserKit\Cookie;
use Symfony\Component\Console\Input\ArrayInput;
@ -16,12 +16,14 @@ use Wallabag\UserBundle\Entity\User;
abstract class WallabagCoreTestCase extends WebTestCase
{
/**
* @var Client|null
* @var KernelBrowser|null
*/
private $client = null;
protected function setUp(): void
{
static::ensureKernelShutdown();
parent::setUp();
$this->client = static::createClient();
@ -29,6 +31,8 @@ abstract class WallabagCoreTestCase extends WebTestCase
public function getNewClient()
{
static::ensureKernelShutdown();
return $this->client = static::createClient();
}
@ -37,7 +41,7 @@ abstract class WallabagCoreTestCase extends WebTestCase
return $this->client;
}
public function resetDatabase(Client $client)
public function resetDatabase(KernelBrowser $client)
{
$application = new Application($client->getKernel());
$application->setAutoExit(false);

View File

@ -74,7 +74,7 @@ class ManageControllerTest extends WallabagCoreTestCase
$client = $this->getTestClient();
$crawler = $client->request('GET', '/users/' . $this->getLoggedInUserId() . '/edit');
$disabled = $crawler->selectButton('user.form.delete')->extract('disabled');
$disabled = $crawler->selectButton('user.form.delete')->extract(['disabled']);
$this->assertSame('disabled', $disabled[0]);
}

View File

@ -320,6 +320,7 @@ entry:
delete: Are you sure you want to remove that article?
delete_tag: Are you sure you want to remove that tag from that article?
delete_entries: Are you sure you want to remove these articles?
reload: Are you sure you want to reload that article?
metadata:
reading_time: Estimated reading time
reading_time_minutes_short: '%readingTime% min'

View File

@ -88,6 +88,8 @@ config:
help_reading_speed: wallabag calcule une durée de lecture pour chaque article. Vous pouvez définir ici, grâce à cette liste déroulante, si vous lisez plus ou moins vite. wallabag recalculera la durée de lecture de chaque article.
help_language: Vous pouvez définir la langue de linterface de wallabag.
help_pocket_consumer_key: Nécessaire pour limport depuis Pocket. Vous pouvez le créer depuis votre compte Pocket.
help_display_thumbnails: Vous pouvez décidez d'afficher ou non les miniatures des articles. Utile pour les connexions lentes.
display_thumbnails_label: Afficher les miniatures des articles (utile pour les connexions lentes).
form_feed:
description: "Les flux Atom fournis par wallabag vous permettent de lire vos articles sauvegardés dans votre lecteur de flux préféré. Pour pouvoir les utiliser, vous devez dabord créer un jeton."
token_label: "Jeton de flux"
@ -145,7 +147,7 @@ config:
card:
new_tagging_rule: Créer une règle d'étiquetage
import_tagging_rules: Importer des règles
import_tagging_rules_detail: Vous devez sélectionné un fichier JSON que vous avez précédemment exporté.
import_tagging_rules_detail: Vous devez sélectionner un fichier JSON que vous avez précédemment exporté.
export_tagging_rules: Exporter les règles
export_tagging_rules_detail: Un fichier JSON sera téléchargé et vous pourrez l'utiliser pour ré-importer les règles ou comme sauvegarde.
file_label: Fichier JSON
@ -412,7 +414,7 @@ quickstart:
configure:
title: Configurez lapplication
description: Pour voir une application qui vous correspond, allez voir du côté de la configuration de wallabag.
language: Changez la langue et le design de lapplication
language: Changez la langue et l'interface
rss: Activez les flux RSS
tagging_rules: Écrivez des règles pour classer automatiquement vos articles
feed: Activer les flux RSS
@ -499,7 +501,7 @@ import:
description: Cet outil va importer tous vos articles dune autre instance de wallabag v2. Allez dans tous vos articles, puis, sur la barre latérale, cliquez sur « JSON ». Vous allez récupérer un fichier « All articles.json ».
readability:
page_title: Importer > Readability
description: Cet outil va importer toutes vos données de Readability. Sur la page des outils (https://www.readability.com/tools/), cliquez sur « Export your data » dans la section « Data Export ». Vous allez recevoir un courriel avec un lien pour télécharger le json (qui ne se finit pas par .json).
description: Cet outil va importer toutes vos données de Readability.
how_to: Choisissez le fichier de votre export Readability et cliquez sur le bouton ci-dessous pour limporter.
worker:
enabled: 'Les imports sont asynchrones. Une fois limport commencé un worker externe traitera les messages un par un. Le service activé est :'
@ -521,7 +523,7 @@ import:
description: Sur la page « Backup » (https://pinboard.in/settings/backup), cliquez sur « JSON » dans la section « Bookmarks ». Un fichier json (sans extension) sera téléchargé (« pinboard_export »).
how_to: Choisissez le fichier de votre export Pinboard et cliquez sur le bouton ci-dessous pour limporter.
elcurator:
description: Cet outil va importer tous vos articles depuis elCurator. Allez dans vos préférences sur elCurator et exportez vos contenus. Vous allez récupérer un fichier JSON.
description: Cet outil va importer tous vos articles depuis elCurator.
page_title: Importer > elCurator
delicious:
page_title: Importer > del.icio.us

View File

@ -451,10 +451,10 @@ import:
enabled: 'A importación faise de xeito asíncrono. Unha vez se inicia a tarefa de importación, un servizo externo ocuparase delas dunha en unha. O servizo actual é:'
readability:
how_to: Escolle o teu ficheiro de Readability e preme no botón inferior para subilo e importalo.
description: Este importador vai traer todos os teus artigos Readability. Nas ferramentas (https://www.readability.com/tools/), preme en "Exporta os teus datos" na sección "Exportar Datos". Obterás un email para descargar un json (que en realidade non remata en .json).
description: Este importador traerá todos os teus artigos en Readability.
page_title: Importar > Readability
elcurator:
description: Este importador traerá todos os teus ficheiros de elCurator. Vai ós axustes na túa conta elCurator e após exporta o teu contido. Obterás un ficheiro JSON.
description: Este importador traerá todos os teus artigos de elCurator.
page_title: Importar > elCurator
delicious:
page_title: Importar > del.icio.us
@ -519,7 +519,7 @@ quickstart:
configure:
tagging_rules: Establece regras para etiquetar automáticamente os artigos
feed: Activar fontes
language: Cambiar o idioma e deseño
language: Cambiar o idioma e interface
description: Para poder adaptar a aplicación ás túas preferencias, entra nos axustes de wallabag.
title: Configurar a aplicación
intro:

View File

@ -64,7 +64,7 @@ import:
readability:
how_to: Odaberi Readability izvoz i pritisni donji gumb za slanje i uvoz datoteke.
page_title: Uvoz > Readability
description: Ovaj uvoznik uvozi sve tvoje Readability članke. Na stranici alata (https://www.readability.com/tools/), pritisni „Izvezi svoje podatke” u odjeljku „Izvoz podataka”. Primit ćeš e-mail za preuzimanje json-a (što zapravo ne završava s .json).
description: Ovaj će uvoznik uvesti sve tvoje Readability članke.
worker:
enabled: 'Uvoz se vrši asinkrono. Nakon što se uvoz zadatak pokrene, jedna vanjska usluga obradit će poslove jedan po jedan. Trenutačna usluga je:'
download_images_warning: Aktivirao(la) si preuzimanje slika za članke. U kombinaciji s klasičnim uvozom, postupak može potrajati godinama (ili možda ne uspije). <strong>Preporučujemo</strong> aktivirati asinkroniziran uvoz za izbjegavanje grešaka.
@ -98,7 +98,7 @@ import:
action:
import_contents: Sadržaj uvoza
elcurator:
description: Ovaj će uvoznik uvesti sve tvoje elCurator članke. Prijeđi na postavke na tvom elCurator računu, a zatim izvezi sadržaj. Dobit ćete JSON datoteku.
description: Ovaj će uvoznik uvesti sve tvoje elCurator članke.
page_title: Uvezi > elCurator
delicious:
page_title: Uvoz > del.icio.us
@ -107,7 +107,7 @@ import:
about:
helping:
description: 'wallabag je slobodan softver otvorenog koda. Možeš nam pomoći:'
by_paypal: putem PayPal-a
by_paypal: putem Liberapay
who_behind_wallabag:
license: Licenca
website: web-stranica
@ -215,6 +215,8 @@ config:
items_per_page_label: Broj stavki po stranici
help_reading_speed: wallabag izračunava vrijeme čitanja za svaki članak. Ovdje možeš definirati, zahvaljujući ovom popisu, jesi li brz ili spor čitač. wallabag će izračunati vrijeme čitanja za svaki članak.
language_label: Jezik
help_display_thumbnails: Možeš odlučiti želiš li prikazivati minijature članaka. Korisno za spore veze.
display_thumbnails_label: Prikaži minijatue članaka (korisno za spore veze).
form_user:
delete:
confirm: Sigurno? (OVO JE NEPOVRATNA RADNJA)
@ -428,6 +430,7 @@ flashes:
notice:
tag_added: Oznaka dodana
tag_renamed: Oznaka preimenovana
too_much_tags: Za izbjegavanje problem s performansama, ne možeš dodati više od %tags% oznaka odjednom ili oznake koje imaju više od %characters% znakova.
ignore_origin_instance_rule:
notice:
deleted: Globalno pravilo za zanemarivanje izvora izbrisano
@ -495,6 +498,7 @@ entry:
assign_search_tag: Dodijeli ovo pretraživanje kao oznaku svakom rezultatu
mass_action_tags_input_placeholder: oznaka1, oznaka2, oznaka3
toggle_mass_action: Uklj./Isklj. grupne radnje
add_tags: Dodaj oznake
view:
left_menu:
set_as_starred: Uklj/Isklj omiljene
@ -547,6 +551,7 @@ entry:
delete: Stvarno želiš ukloniti taj članak?
delete_tag: Stvarno želiš ukloniti tu oznaku za taj članak?
delete_entries: Stvarno želiš ukloniti ove članke?
reload: Stvarno želiš ponovo učitati taj članak?
edit:
title_label: Naslov
url_label: Url
@ -614,7 +619,7 @@ quickstart:
description: Za dobivanje programa koji tebi najviše odgovara, pogledaj konfiguraciju wallabaga.
tagging_rules: Odredi pravila za automatsko označivanje članaka
title: Konfiguriraj program
language: Promijeni jezik i dizajn
language: Promijeni jezik i sučelje
feed: Aktiviraj feedove
developer:
description: 'Mislili smo i na pregramere: Docker, sučelje (API), prijevodi itd.'

View File

@ -430,7 +430,7 @@ quickstart:
configure:
title: Configurar l'aplicacion
description: Per fin d'aver una aplicacion que vos va ben, anatz veire la configuracion de wallabag.
language: Cambiar la lenga e l'estil de l'aplicacion
language: Cambiar la lenga e l'intterfàcia
rss: Activatz los fluxes RSS
tagging_rules: Escrivètz de règlas per classar automaticament vòstres articles
feed: Activar los flux RSS
@ -517,7 +517,7 @@ import:
description: Aquesta aisina importarà totas vòstras donadas d'una instància mai de wallabag v2. Anatz dins totes vòstres articles, puèi, sus la barra laterala, clicatz sus "JSON". Traparetz un fichièr "All articles.json".
readability:
page_title: Importar > Readability
description: Aquesta aisina importarà totas vòstres articles de Readability. Sus la pagina de l'aisina (https://www.readability.com/tools/), clicatz sus "Export your data" dins la seccion "Data Export". Recebretz un corrièl per telecargar un json (qu'acaba pas amb un .json de fach).
description: Aquesta aisina importarà totas vòstres articles de Readability.
how_to: Mercés de seleccionar vòstre Readability fichièr e de clicar sul boton dejós per lo telecargar e l'importar.
worker:
enabled: "L'importacion se fa de manièra asincròna. Un còp l'importacion lançada, una aisina extèrna s'ocuparà dels articles un per un. Lo servici actual es:"
@ -544,7 +544,7 @@ import:
how_to: Causissètz lo fichièr de vòstra exportacion Delicious e clicatz lo boton çai jos per limportar.
elcurator:
page_title: Importar > elCurator
description: Aquesta aisina importarà totes vòstres articles a partir de elCurator. Anatz a las preferéncias de elCurator e exportatz vòstres contenguts. Recuperaretz un fichièr JSON.
description: Aquesta aisina importarà totes vòstres articles a partir de elCurator.
developer:
page_title: Gestion dels clients API
welcome_message: Vos desirem la benvenguda sus l'API de wallabag

Some files were not shown because too many files have changed in this diff Show More