Commit Graph

115 Commits

Author SHA1 Message Date
Alexandre Alapetite
49013bf716 Cherry pick from 2335 (#2356)
Cherry pick bug fix from https://github.com/FreshRSS/FreshRSS/pull/2335
This code is currently not used.
2019-04-07 14:01:05 +02:00
Alexandre Alapetite
9cc72c0c48 Fix EntryDAO tags warning for Fever API
https://github.com/FreshRSS/FreshRSS/issues/2239
2019-02-03 21:24:06 +01:00
Alexandre Alapetite
34fe41ac78 Merge branch 'FreshRSS/dev' into FreshRSS/dev-1.14.0 2019-01-17 21:36:29 +01:00
Alexandre Alapetite
743c1b740b Export labels (#2217)
* Export labels

https://github.com/FreshRSS/FreshRSS/issues/2196

* Small fixes

* Backport code from 1.14.0

4888f919f1

* More fixes
2019-01-16 22:26:43 +01:00
Alexandre Alapetite
4888f919f1 Prepare for batch mark as read 2018-12-25 01:30:28 +01:00
Alexandre Alapetite
b672fc190d Tweaks for Vienna RSS (#2093)
* Tweaks for Vienna RSS

https://github.com/FreshRSS/FreshRSS/issues/2091
https://github.com/ViennaRSS/vienna-rss/issues/1197

* Fix get feed by URL

* Fix get item ids returning starred elements

* API add item ids by feed URL

* Add API filter `it`

https://feedhq.readthedocs.io/en/latest/api/reference.html#stream-items-ids

* API add `nt=` filter + refactoring

* No ; prefix for author

https://github.com/FreshRSS/FreshRSS/issues/2091#issuecomment-435562495

* Add id long form prefix and accept short id form

https://github.com/FreshRSS/FreshRSS/issues/2091#issuecomment-435631259

* Fix quote problem

https://github.com/FreshRSS/FreshRSS/issues/2091#issuecomment-435683930

* Isolate bug fix for News+

https://github.com/FreshRSS/FreshRSS/issues/2091#issuecomment-435687041

* Rework encoding conventions

https://github.com/FreshRSS/FreshRSS/issues/2091#issuecomment-437441834

* Unicode escaping alternative

Alternative approach to encode XML special characters and other
problematic characters into their Unicode fullwidth version when we
cannot use HTML-encoding because clients disagree wether they should
HTML-decode or not.
https://github.com/FreshRSS/FreshRSS/issues/2091#issuecomment-436059559
2018-11-11 17:31:50 +01:00
Alexandre Alapetite
cf899d8d25 TT-RSS import (#2099)
* TT-RSS import

Import of Tiny Tiny RSS favourites
https://github.com/FreshRSS/FreshRSS/issues/2018#issuecomment-432710462

* Fallback feed_url

* Simpler JSON

* TT-RSS import custom labels

* Fix syntax
2018-11-05 18:10:38 +01:00
Alexandre Alapetite
c8b54ae807 Fix MySQL create table feeds (#2047)
https://github.com/FreshRSS/FreshRSS/issues/2042
2018-10-14 13:48:59 +02:00
Alexandre Alapetite
8ee8a573f1 Custom labels (#2027)
* First draft of custom tags

https://github.com/FreshRSS/FreshRSS/issues/928
https://github.com/FreshRSS/FreshRSS/issues/1367

* SMALLINT to BIGINT for id_entry

And uppercase SQL types

* Fix layout for unreads

* Start UI menu

* Change menu order

* Clean database helpers

https://github.com/FreshRSS/FreshRSS/pull/2027#discussion_r217971535

* Travis rules do not understand PostgreSQL constants

Grrr

* Tag controller + UI

* Add column attributes to tags

* Use only favicon for now, for label

* Fix styling for different themes

* Constant for maximum InnoDB index length in Unicode

https://github.com/FreshRSS/FreshRSS/pull/2027#discussion_r219052200
(I would have personnally prefered keeping the readability of a real
value instead of a constant, in this case of many SQL fields)

* Use FreshRSS_Factory::createCategoryDao

* Add view of all articles containing any tag

* Fix search in tags

* Mark as read tags

* Partial auto-update unread tags

* More auto update tag unreads

* Add tag deletion

* Do not purge tagged articles

* Minor comment

* Fix SQLite and UI bug

* Google Reader API support for user tags

Add SQL check that tag names must be distinct from category names

* whitespace

* Add missing API for EasyRSS

* Compatibility SQLite

Problematic parentheses

* Add SQL DISTINCT for cases with multiple tags

* Fix for PostgreSQL

PostgreSQL needs some additional type hint to avoid "could not determine
data type of parameter $1"

http://www.postgresql-archive.org/Could-not-determine-data-type-of-parameter-1-tp2171092p2171094.html
2018-09-29 20:47:17 +02:00
Alexandre Alapetite
c65f535890 Fix count unreads in SQLite (#2009)
* Fix count unreads in SQLite

Was wrong in e.g. `./cli/user-info.php` because UNION output order in
MySQL and SQLite is differents...

* Changelog 2009
2018-09-08 23:05:56 +02:00
Alexandre Alapetite
d3f5bd840d Add mark-as-unread (#1995)
* Add mark-as-unread

https://github.com/FreshRSS/FreshRSS/issues/1966

* Change sentence

https://github.com/FreshRSS/FreshRSS/pull/1995#discussion_r214515954

* Enable mark-as-unread only when unread articles are shown

In order to prevent erroneous marking-as-unread.
We might find a better logic later.

* Disable instead of hide mark-as-unread option

To make it easier to discover
2018-09-03 20:48:04 +02:00
Alexandre Alapetite
32d9c3b790 Use mb_strcut (#1996)
* Use mb_strcut

Avoid cutting in the middle of a multi-byte UTF-8 character

* Forgotten php5-*

* Typo

* Whitespace

* More mb_strcut
2018-09-02 13:19:58 +02:00
Alexandre Alapetite
c0f2df3ef0 Fever fixes (#1931)
* Fever fixes

Was hardcoded for MySQL. Bug in "before" parameter. Bug in mark all as
read.

* Fix construct

* Changelog 1930

https://github.com/FreshRSS/FreshRSS/issues/193
https://github.com/FreshRSS/FreshRSS/pull/1931
2018-06-12 21:11:43 +02:00
Kevin Papst
8f1bad60d0 Add Fever API and user documentation (#1836)
* added fever api and documentation

* spaces to tabs

* fixed code format

* added links

* added utf8 to header

* removed XML support

* removed before check, as we have to convert it afterwards

* added sandboxed setting (currently disabled)
added support for extensions using entry_before_display

* listFeedsOrderUpdate LIMIT

https://github.com/FreshRSS/FreshRSS/pull/1836/files#r175287881

* removed custom sql by using FreshRSS_FeedDAO::listFeedsOrderUpdate()

* fixed mark all as read

* replaced custom sql for getUnread() and getStarred() with dao functions

* removed sanitization functions

* Rework fever login

* Fix config bug

Plus documentation

* Fix array syntax

For compatibility with PHP 5.3

* Disable cookies and session for API

* Fix currentUser

* added response header and error log

* adjusted phpdoc to match new authentication

* Mechanism to delete old keys

* replace PHP_INT_MAX with zero to disable limit

* replace method_exists with check for explicit methods

* removed Press support and smaller refactoring + updated docu

* Rewrite bindParamArray

Avoid one of the SQL injection risks

* Docs and readme

* Fix API link

* Simplify reverse key check

Using userConfig
2018-05-24 21:53:47 +02:00
Alexandre Alapetite
84d891f8cf Light Boolean search implementation (#1828)
* Light Boolean search implementation

"Hello intitle:World OR date:P1D example"
https://github.com/FreshRSS/FreshRSS/issues/879

* Doc Boolean search

* Doc typos
2018-03-14 17:20:41 +01:00
Alexandre Alapetite
5872a11eb7 cleanOldEntries call autoUpdateDb (#1804)
* cleanOldEntries call autoUpdateDb

https://github.com/FreshRSS/FreshRSS/issues/1803

* Fix feedDAO autoUpdateDb

* Move cleanOldEntries to EntryDAO

Only the entry table is concerned
2018-03-01 19:25:40 +01:00
Alexandre Alapetite
79f8b440d1 API /reader/api/0/stream/items/contents (#1774)
* API /reader/api/0/stream/items/contents

For FeedMe

* Fix continuation

* Continuation in stream/items/ids

* Fix multiple continuations

* Allow empty POST tokens

For FeedMe.
This token is not used by e.g. The Old Reader API.
There is the Authorization header anyway.
TODO: Check security consequences

* API compatibility FeedMe: add/remove feed

FeedMe uses GET for some parameters typically given by POST

* A bit of sanitization

* Links to FeedMe

* API favicons more robust when base_url is not set

* Changelog FeedMe
2018-02-08 20:11:05 +01:00
Alexis Degrugillier
8c2113f9e6 Add mute strategy configuration (#1750) 2018-01-01 20:34:06 +01:00
Alexandre Alapetite
f632a34626 CLI optimize database (#1663)
CLI optimize database https://github.com/FreshRSS/FreshRSS/issues/1583
And VACUUM in SQLite https://github.com/FreshRSS/FreshRSS/issues/918
Add VACUUM for PostgreSQL (Not tested yet)
2017-10-12 20:11:06 +02:00
Frans de Jonge
4e174ed9dd [ci] Add Travis (#1619)
* [ci] Add Travis

* Exclude some libs

* Semi-auto whitespace fixes

* line length in SQLite

* Exclude tests from line length

* Feed.php line length

* Feed.php: get rid of unnecessary concat

* Feed.php: line length

* bootstrap.php: no newline at end of file

* Allow concatenating across multiple lines

* Add Travis badge

* do-install line length

* update-or-create-user line length

* cli/create-user line length

* tests/app/Models/SearchTest.php fix indentation

* tests/app/Models/UserQueryTest.php fix indentation

* tests/app/Models/CategoryTest.php fix indentation

* [fix] PHP 5.3 on precise

* cli/do-install no spaces

* cli/list-users line length

* cli/reconfigure line length

* empty catch statements

* api/index line length nonsense

* spaces before semicolon

* app/Models/EntryDAO bunch of indentation

* extra blank lines

* spaces before comma in function call

* testing tabwidth

* increase to 10

* comment out tabwidth line

* try older phpcs version 3.0.0RC4

* line length exception for app/install.php

* proper spaces

* stray spaces in i18n

* Minz/ModelPdo line length

* Minz whitespace

* greader line length

* greader elseif placement

* app/Models/Feed.php spacing in function argument

* ignore php 5.3

* app/Models/ConfigurationSetter.php stray whitespace

* EntryDAOSQLite line length

* I vote for higher max line length =P

* ignore SQL

* remove classname complaint

* line length/more legible SQL

* ignore line length nonsense

* greader line length

* feedController issues

* uppercase TRUE, FALSE, NULL

* revert

* importExportController lowercase null

* Share.php default value not necessary because ! is_array () a few lines down

* CategoryDAO constants should be UPPERCASE

* EntryDAO reduce line length

* contentious autofix

* Allow failures on all versions of PHP except 7.1 because reasons
2017-09-22 12:13:46 +02:00
Alexandre Alapetite
aadba9fb70 Negative searches
https://github.com/FreshRSS/FreshRSS/issues/1381
Possibility to exclude authors, titles, tags, urls, words by prefixing
them by ! or - (like Google Search):

* !intitle:unwanted
* -intitle:unwanted
* -author:unwanted
* -#unwanted
* -unwanted

And one can use many of each and combine them with positive searches
2017-04-01 23:41:19 +02:00
Alexandre Alapetite
d9c0d25b85 Improve search: intitle, author, inurl
Allow multiple values of intitle: , author:, inurl:

Note: Tests for UserQueryTest are broken due to
https://github.com/sebastianbergmann/phpunit/wiki/Release-Announcement-for-PHPUnit-4.0.0#backwards-compatibility-issues
2017-04-01 22:31:12 +02:00
Alexandre Alapetite
fbdc22f75a Merge branch 'FreshRSS/dev' into defered-insertion 2017-03-26 19:36:44 +02:00
Alexandre Alapetite
7a6751b50d PDO fix PHP 7.1
http://php.net/manual/migration71.changed-functions.php#migration71.changed-functions.pdo
2017-03-26 18:48:34 +02:00
Alexandre Alapetite
cc235c6af3 SimplePie light manual update 2017-03-26 15:02:35 +02:00
Alexandre Alapetite
e956aee53d More defered insertion. New SQL index
New index entry_feed_read_index
TODO: Auto add this index to existing version
2017-03-26 14:07:06 +02:00
Alexandre Alapetite
a20fd9db9f Defered insertion MySQL bug
The update of cached values remains to be optimized
2017-03-26 01:41:08 +01:00
Alexandre Alapetite
22b41f3bfc Candidate implementation of defered insertion
https://github.com/FreshRSS/FreshRSS/issues/530
2017-03-26 00:01:11 +01:00
Thomas Citharel
ae5a8572d5 postgres fixes 2017-01-27 10:26:31 +01:00
Alexandre Alapetite
f59de4e2b6 Stream JSON export
Avoid large in-memory copies
https://github.com/FreshRSS/FreshRSS/issues/1372
2016-11-15 20:43:06 +01:00
Alexandre Alapetite
aeda49a7d2 Add CLI for user information + Fix last user activity
https://github.com/FreshRSS/FreshRSS/issues/1345
2016-11-05 20:48:46 +01:00
Alexandre Alapetite
8a410969dd Use bindValue instead of bindParam
https://github.com/FreshRSS/FreshRSS/issues/1349
We should later replace all bindParam by bindValue
2016-11-02 21:29:21 +01:00
Alexandre Alapetite
7f2b0439ec Extract function safe_ascii() 2016-10-20 01:38:23 +02:00
Alexandre Alapetite
1893fc61e0 guid and urls should not contain low/high characters
It looks like SimplePie does not always filter everything
Having a character not in latin1 would create MySQL collate errors
2016-10-20 01:19:59 +02:00
Alexandre Alapetite
38289beb66 Fix updateEntry warning
https://github.com/FreshRSS/FreshRSS/issues/1325
2016-10-16 15:19:11 +02:00
Alexandre Alapetite
d184478fb4 PostgreSQL compatibility boolean
https://github.com/FreshRSS/FreshRSS/issues/1311
2016-10-14 23:05:05 +02:00
Alexandre Alapetite
50827447e3 Better error message in markReadFeed
https://github.com/FreshRSS/FreshRSS/issues/1299
2016-10-11 19:34:46 +02:00
Alexandre Alapetite
05cabe99ae Take better advantage of other users refresh 2016-10-05 00:39:54 +02:00
Alexandre Alapetite
32ac41439a PostgreSQL case-insensitivity bug 2016-10-01 19:31:43 +02:00
Alexandre Alapetite
a7b605f2a5 Bug updateEntry() 2016-10-01 15:14:37 +02:00
Alexandre Alapetite
1d8c24c73f BindParam bug 2016-10-01 14:50:17 +02:00
Alexandre Alapetite
548250620b PostgreSQL updateEntry() 2016-10-01 10:09:28 +02:00
Alexandre Alapetite
9f04e2bf32 MySQL use unhex instead of hex litteral
X' syntax did not work well with bind values
2016-09-06 09:15:32 +02:00
Alexandre Alapetite
f66be86e41 Quoted upper-cases instead of string replace 2016-08-31 21:47:12 +02:00
Alexandre Alapetite
c25fdbcc09 More PostgreSQL 2016-08-23 00:02:54 +02:00
Alexandre Alapetite
2af3abc89e Merge branch 'FreshRSS/dev' into PostgreSQL 2016-08-20 12:22:56 +02:00
Alexandre Alapetite
edd4516178 More SQLite fix for mark search as read 2016-08-19 14:33:08 +02:00
Alexandre Alapetite
6afa36e7e1 SQLite fix for mark search as read
https://github.com/FreshRSS/FreshRSS/issues/1220
https://github.com/FreshRSS/FreshRSS/pull/1218
https://github.com/FreshRSS/FreshRSS/issues/608
2016-08-19 11:05:24 +02:00
Alexandre Alapetite
32c734ef62 SQL mark search as read
https://github.com/FreshRSS/FreshRSS/issues/608
2016-08-18 00:00:08 +02:00
Alexandre Alapetite
7c1b5e322c PostgreSQL draft
https://github.com/FreshRSS/FreshRSS/issues/416
Based on @Damstre work https://github.com/FreshRSS/FreshRSS/pull/1071
Not tested
2016-08-02 22:49:35 +02:00