* remove dependencies that use syscall.Syscall*
OpenBSD will be removing direct access to `syscall(2)` soon.
Shiori will stop working because of this, as some of its dependencies
rely heavily on the use of `syscall.Syscall*`, which ends up using
`syscall(2)`. This commit removes those dependencies by reverting back
to use github.com/mattn/go-sqlite3 instead of modernc.org/sqlite to deal
with the sqlite database backend.
* add ~emersion/go-sqlite3-fts5
* enable cgo to check ci
* fts5 build flag
* split sqlite logic using build flags
* disable cgo again
* added ci test for bsd systems
* remove openbsd ci
* Revert "remove openbsd ci"
This reverts commit f394148385.
* fix makefile go_test_flags
---------
Co-authored-by: Felipe M <me@fmartingr.com>
Co-authored-by: Felipe Martin <812088+fmartingr@users.noreply.github.com>
* return corrent path in windows with usiing path lib
* ci: run tests in windows and macos too
* avoid testing mysql/psql in windows and macos
* windows & macos matrix
* disable gotestfmt
* replace which in shell script
* handle error in test db removal
* fix expected path baseed on platform
* add leading seprator
* proper temporary storage dir and db cleanup
* fix failed to create destination dir file does not exist in windows
* move temp to /tmp
* update temp folder
* fix config tests in windows
* apply patch for db
* revert temp dir creation.
* unify account db tests pach
* remove TmpDir for sqlite tests
* try to force CGO disable with enviroment variable
* Remove unneeded log
Co-authored-by: Felipe Martin <812088+fmartingr@users.noreply.github.com>
* remove unneeded comment
Co-authored-by: Felipe Martin <812088+fmartingr@users.noreply.github.com>
* fix file path for download images
* change way to create temp directory
* use diffrent file name for each test
* fix typo
* fix absolute path in successful download image
* correct filename with png
* change test to download image from internet instead of local machine
* remvoe unneeded import
* remove os.RemoveAll(.env)
* unify variable names in unit test
* return CGO_ENABLED=0
* test other way to set enviroment variable
* try to set enviroment variable sepratly in macos and windows
* set enviroment variable before run commands in windows
* fix windows test name
* combine two workflow for windows and macos again
* fix typo
* remove env
* change env path
* cleanup unneeded env
* general CGO_ENABLED environ
* use absolute path to run fileserver instead of relative
* serve file test from internet shiori repository
* check file existance after download and unify varibale name from temp to tmpDir
* remove unneeded log
---------
Co-authored-by: Felipe M <me@fmartingr.com>
Co-authored-by: Felipe Martin <812088+fmartingr@users.noreply.github.com>
* fix: disable direct os lookuper
* config.setdefaults call config.http.setdefaults
* tests
* log level default in local run server
* store log level in configuration
* migrate bookmark content route to new http server
* new archive page
* remove unused go generate comment
* database mock
* utils cleanup
* unused var
* domains refactor and tests
* fixed secret key type
* redirect to login on ui errors
* fixed archive folder with storage domain
* webroot documentation
* some bookmark route tests
* fixed error in bookmark domain for non existant bookmarks
* centralice errors
* add coverage data to unittests
* added tests, refactor storage to use afero
* removed mock to avoid increasing complexity
* using deps to copy files around
* remove config usage (to deps)
* remove handler-ui file
* add new api
* UI use new API
* remove legacy route
* fix request to new api destination and read that response
* feat: allow authentication using cookies
* fix: return proper error on validatesession
* typo: secret key envionment variable in makefile
* serve ebook file with new api
* cache update use new api path
* add skipexist and batch download use same route as cache
* fix bug - update hasebook status
* remove unneeded part of code
* add swagger documentation
* fix swagger documentation
* fix swagger response
* better statuscode
* fix swagger documentation
* covert to snake_case
* recover coverage.txt that remove
---------
Co-authored-by: Felipe M <me@fmartingr.com>
Co-authored-by: Felipe Martin <812088+fmartingr@users.noreply.github.com>
* go 1.21
* update dependencies
* Updated direct dependencies
* -count=1 to test flags
* group dependabot updates into one PR
* get swag version from go.mod
* show changes in swagger check
* go mod tidy
* updated swag generated files
* use go version from go.mod
* remove stray \
* proper grep
* refactor: swagger docs into a folder
* added scripts for the swaggger tasks
* check version and fmt
* CI
* formatted swag comments
* using custom delims
* revert custom delims
* swag 1.16.1
* update swagger docs
* avoid make swagger output
* swagger check
* test
* swag-fmt
* swagger run
* gofmt
* avoid swag-fmt check for now due to inconsistencies with gofmt
* re-enabled by using go fmt afterwards
* use newer swag in CI
* add gopath to path
* using go binary instead of unset env
* alternative
* correct swag version
* formatted
* formatted
* correct go fmt command
* make swagger
* swagger-check -> swag-check
* run swag-check on lint