Commit graph

440 commits

Author SHA1 Message Date
hulb
821b69d76c
fix err in keyword searching (#494) 2022-10-09 17:05:01 +02:00
Felipe Martin Garcia
d15dc18674
Update issue templates 2022-10-08 13:12:02 +02:00
Felipe Martin Garcia
460014581c
fix(import): check for no rows error (#487) 2022-10-04 13:54:33 +02:00
hulb
09f2465065
refactor:pass ctx to db layer, return err instead of recover panic (#450) 2022-09-30 12:19:36 +02:00
Bastien Rivière
39cb64222f
docs: fix remember represented as a number instead of a bool (#472)
Changed in pull request: https://github.com/go-shiori/shiori/pull/346
2022-09-30 12:17:05 +02:00
Felipe Martin Garcia
3deeda7151
feat: upgrade to go 1.19 (#469)
* feat: upgrade to go 1.19

* fix: ioutil deprecation notice
2022-08-11 14:22:10 +02:00
Felipe Martin Garcia
c8fec2a265
fix: remove manual transaction on sqlite migration 2 (#468) 2022-08-11 13:40:17 +02:00
Andriy Kushnir
0246e10dff
feat: improve performance for sqlite queries (#425)
* [sqlite] Added has_content column and relevant migration

* Fix typo in docstring

* [sqlite] Fetch content for bookmarks separately

* [sqlite] Store has_content alongside with bookmark

* [sqlite] Rename variable to distinguish it from main query

* [sqlite] Use by-reference instead of no-op copy

* [sqlite] Reduce queries count from ≈30 to 1 to fetch tags

* Lint fixes

* Make minor logging improvements

* Wrap entire migration in transaction block

* Added «down» migration

* Drop workaround for old SQLite versions
2022-08-08 20:52:33 +02:00
Kim Kar
f5652a5bbf
Fix docker migration script example (#451)
The example docker command given was invalid, as `docker run` operates on images, not containers.
2022-07-23 12:26:32 +02:00
Felipe Martin Garcia
cba5046231
feat: session expire time from backend (#437)
* feat: session expire time from backend

Deduplicated logic from backend and frontend where we needed to take the
login checkbox into account for both back and front codebases. Now the
backend will send the frontend the expire time calculated only in one
place.

This is part of a multi-step process that will store sessions in
database, but this will ease the maintenance of this section for now.

* chore: remove test logger
2022-07-23 11:32:53 +02:00
hulb
7e1824a8b5
fix invalid assets path when use webroot (#448)
Co-authored-by: hulb <hulb@RD-NeoHu.netis.com.cn>
2022-07-08 11:26:37 +02:00
jmbmkn
f000f11bfa
Update Usage.md (#435)
Fix tiny typo in Wallabag import commands
2022-06-23 09:08:05 +02:00
Felipe Martin Garcia
3422035bfa
docs: updated pocket import script
The import script was pointing to a faulty gist with an error, I've forked and fixed the error as @questor pointed out in the comments and #426.

Fixes #426
2022-05-26 21:42:55 +02:00
Felipe Martin
f72f050835
docs: fixed outdated volume path reference 2022-05-26 21:35:29 +02:00
Felipe Martin Garcia
0bf1a4875c
docs: migrate documentation from the wiki (#394)
* docs: migrate documentation from the wiki

* docs: updated docker image url

* docs: added migrations section

* docs: fixed index link
2022-05-26 19:49:30 +02:00
hulb
2b1ddd093d
replace assets generation with embed (#423) 2022-05-26 19:36:23 +02:00
Felipe Martin Garcia
9397832485
fix: amd64 build paths (#429) 2022-05-26 19:29:11 +02:00
Felipe Martin Garcia
7394b1060a
chore: update go dependencies (#424) 2022-05-05 21:15:52 +02:00
hulb
8732fd7b6d
implement migration for mysql & postgres (#422) 2022-05-03 23:30:28 +02:00
Felipe Martin Garcia
ce8a172682
fix: bookmark content download (#413)
Fixed a bug where the content of the article would archive but the
reader version would not be saved due to variable passing. Also made the
code easier to follow by following return principles.

Fixes #406
2022-03-27 21:01:49 +02:00
Felipe Martin Garcia
0fe24d2598
fix: url modification when query param is empty (#411)
This commit fixes URL malformation when trying to remove the utm social
query parameters from an URL, which upon finishing and reconstructing
would attach the equal symbol even if the original URL didn't have it.

This is a known Go "bug" [1] that isn't going to be "fixed". I quote
that because server side should behave the same for `?a=&b=1` and
`?a&b=1` for the `a` parameter, but sometimes that's not the case.

[1]: https://github.com/golang/go/issues/20820

Fixes #409
2022-03-27 21:01:39 +02:00
Felipe Martin Garcia
81d52a2e24
feat: sqlite migrations (#398)
- Moved migrations from code to SQL files
- Using golang-migrate/v4
- Added a new CLI command: migrate
2022-03-26 08:33:57 +01:00
Tung Le
ca3cc11b2d
sqlite: remove unneeded LEFT JOIN to improve performance (#387)
* sqlite: remove unneeded LEFT JOIN to improve performance

* Fix handling join clause in GetBookmarks

* Revert changes in GetBookmarks
2022-03-10 23:32:58 +01:00
My6UoT9
b68092c6b4
Heroku buildpack support in go.mod (#388) 2022-03-01 13:40:42 +01:00
Felipe Martin Garcia
560a677f50
fix: trying to mkdir over an incorrect data path (#378) 2022-02-23 19:00:16 +01:00
Emmanuel Frecon
e1e2c7bfd8
Web Server and CI Improvements (#374)
* Fix for infinite redirect loop

path.Join trims the trailing slash if the path isn't /, use configured
root instead.

* Add repo root independence

This makes the workflows agnostic of the repository root, making it
possible to build in forked repos.

* Add HTTP request logging

* Fix proper RootPath handler

* Add logging for all resources

This adds proper logging for all resources, including errors. Logging
is on by default, but can be turned off.

* Report effective length of written data
2022-02-19 08:22:50 +01:00
Felipe M
feb150f8c6
ci: github action to notify releases via irc 2022-02-15 17:39:02 +01:00
Felipe M
3c8a66f8f8
chore: updated readme 2022-02-14 20:00:45 +01:00
n8225
2b4fd9f0cb
Remove unneeded alter table transactions from sqlite (#372) 2022-02-14 19:49:46 +01:00
Felipe Martin Garcia
0bd297d63c
fix: update bookmark on sqlite database (#367)
It used an update and insert at the same time, since the virtual table
cannot have constrants nor upserts we need to try an update the
bookmark content to check for it's existence, inserting it only if the
update fails (don't affect any rows).

This will need to be improved in the future, since not all bookmark
updates require modification of the content table (in my case, I was
testing only updating tags).
2022-02-13 21:28:40 +01:00
Felipe Martin Garcia
fb0bf38b7e
feat: async content download when creating via api (#368)
* feat: async content download when creating via api

Invoking the content download code in a goroutine after saving the
bookmark, this way we can return a response to the user quickly while
the webpage is donwloaded and archived.

Cache api endpont (/api/cache) remains untouched until I understand
the logic behind it.

Also updated the API endpoint for the extension, though I'm unsure why
there's a difference between the "regular" API and the webext API,
they should be using the same APIs.
2022-02-13 21:09:42 +01:00
n8225
d05d1ad2c0
Setup new CI/CD workflows (#365)
* CI/CD setup
* Setup for go-shiori
* Fix docker image
* Dockerfile adjustments
2022-02-13 16:38:54 +01:00
Felipe Martin Garcia
a76b121098
fix: golangci-lint errors (#366) 2022-02-13 16:38:27 +01:00
Felipe M
2ca628b7fe
hotfix: fixes session duration from #346 2022-02-11 16:00:38 +01:00
Felipe M
2dc462b010
docs: updated readme docker links 2022-02-11 14:12:15 +01:00
Felipe Martin Garcia
d56993292b
fix: remember me session duration (#346)
- Default session duration is 1h
- Increased session duration (when remember me is checked) is
  increased to 30d.
2022-02-11 14:05:34 +01:00
n8225
f1c98a8e98
Update Dependencies and Replace mattn/go-sqlite with modernc.org/sqlite (#345)
* No more CGO

* Update all dependencies to current

* Only test against go 1.17.
2022-02-11 13:59:49 +01:00
Felipe M
91e1bc85b4
chore: stalebot for pull requests 2022-02-10 23:03:49 +01:00
Felipe M
d70a8f2692
chore: configuration for stale bot 2022-02-10 22:55:54 +01:00
Felipe Martin Garcia
cf88489187
Merge pull request #341 from n8225/updateDockerfile
Remove golang from final docker image
2022-02-07 08:46:31 +01:00
Nathan W Rew
748b306563
Remove golang from final image 2022-02-06 09:38:02 -06:00
Felipe Martin Garcia
50ecb90c2b
docs: updated disclaimer
Removed maintenance message and added a link to the announcements section and the IRC chat
2022-02-04 21:47:42 +01:00
Dean Jackson
a950bfec4c
Merge pull request #264 from lapwat/master
bug: Docker build
2020-08-20 18:38:54 +02:00
lapwat
83e3621af6 bug: Docker build 2020-08-11 22:51:30 +00:00
Dean Jackson
4ff6ddd65a
Merge pull request #246 from Midek/master
update url also when offline mode
2020-08-06 22:28:04 +02:00
Dean Jackson
3d74038326 Update links and email addresses 2020-08-06 22:26:59 +02:00
Dean Jackson
ee877b8c9f Remove Radhi's accounts from GitHub Sponsors 2020-08-06 22:15:45 +02:00
Dean Jackson
ff5c464156
Merge pull request #259 from go-shiori/fix/exit-status
Exit with non-zero status when commands fail
2020-08-06 21:28:57 +02:00
Dean Jackson
a0ce725167 Exit with non-zero status when add fails 2020-08-06 21:12:34 +02:00
Dean Jackson
7124dc2e08
Merge pull request #258 from go-shiori/ci
Add GitHub Action to lint code and run unit tests on supported platforms + Go versions.
2020-08-06 21:11:19 +02:00