Commit graph

27 commits

Author SHA1 Message Date
Felipe M 59f16a1853
allow version bump from custom ref 2023-07-19 18:04:10 +02:00
Felipe M 86cd9f2bb9
added workflow to delete dangling tags 2023-07-19 12:10:16 +02:00
Felipe M a4b984510c
Get correct pull request number 2023-07-19 11:45:52 +02:00
Felipe M c96a83007f
event -> event_name 2023-07-19 11:42:11 +02:00
Felipe M 8f19332b2e
pull request condition 2023-07-19 11:29:11 +02:00
Felipe M a2d2f0ac08
avoid releasing if lint/test fails 2023-07-19 11:29:04 +02:00
Felipe M 65a66e8682
trigger build on prs 2023-07-19 10:37:59 +02:00
Felipe M d2a5c7e8e6
server as default command 2023-07-18 19:24:02 +02:00
Felipe Martin 6f19c12c95
Start working on new REST API. Refactor logic in domains. (#497)
* added 404 template

* added auth domain

* added embed file for frontend

* added base config and dependencies

* added basic new http server

* added separated server command

* updated go modules

* removed modd file

* Added shortcut to send internal server error response

* Added JWT support to Auth Domain

* Added JWT support to API

* docs: added comments to response struct

* naming

* inline returns

* updated dependencies

* production logger

* bookmarks endpoint

* reverted old views api path

* frontend for api v1

* proper 404 error (not working atm)

* use response

* removed 404 html

* server error handler

* login and basic auth

* adjusted session duration

* properly retrieve tags

* properly delete bookmark

* cleanup

* archiver domain

* debug routes

* bookmark routes

* expiration by parameter

* move to logrus

* logout

* frontend cache

* updated dependencies

* http: migrated to gin

* linted

* Added version command

* unit tests, docs

* response test utils and tests

* remove logout handler

* auth

* createtag

* improved http test utilities

* assert message equals

* Remove 1.19 from test matrix

* moved api to v1 folder

* docs: contribute docs

* updated makefile

* updated usage docs

* warn in server command

* updaed docs with shiori version command

* Updated documentation

* deps: update
2023-07-17 14:30:18 +01:00
Felipe M e839b69875
fix: goreleaser use go version from go.mod file and fix typo 2023-07-02 13:02:46 +02:00
Felipe Martin 8e9324ae8b
deps: update to go 1.20 + dependencies. Fixes CI (#628)
* deps: update go1.20 and dependencies

* fix: goreleaser archives

* ci: removed unused notify irc action

* ci: updated workflow dependency versions

* fix: typo
2023-07-02 12:50:29 +02:00
Felipe Martin 85534b62f8
Update dependencies (#616)
* Added contribute docs for tests
* deps: update
* mariadb using healthcheck script
* Restored health retries to 5
2023-06-11 21:10:15 +02:00
Felipe Martin f6f3faf130
deps: update direct deps (#567)
* deps: update direct deps

* test on 1.20
2023-02-05 11:19:53 +01:00
Felipe Martin 9344bbeb27
ci: fix goreleaser snapshots (#553) 2023-01-10 13:05:00 +01:00
dependabot[bot] 04a79dcf84
chore(deps): bump goreleaser/goreleaser-action from 3 to 4 (#544)
Bumps [goreleaser/goreleaser-action](https://github.com/goreleaser/goreleaser-action) from 3 to 4.
- [Release notes](https://github.com/goreleaser/goreleaser-action/releases)
- [Commits](https://github.com/goreleaser/goreleaser-action/compare/v3...v4)

---
updated-dependencies:
- dependency-name: goreleaser/goreleaser-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-01-10 12:46:48 +01:00
dependabot[bot] 23e87f8430
chore(deps): bump actions/download-artifact from 2 to 3 (#523)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 2 to 3.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-10-28 09:10:49 +02:00
dependabot[bot] 8efbc94007
chore(deps): bump actions/setup-go from 2 to 3 (#522)
Bumps [actions/setup-go](https://github.com/actions/setup-go) from 2 to 3.
- [Release notes](https://github.com/actions/setup-go/releases)
- [Commits](https://github.com/actions/setup-go/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/setup-go
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-10-28 09:10:31 +02:00
Felipe Martin Garcia 4ea81a446a
chore(deps): updated go and github actions dependencies (#511)
* deps(go): updated dependencies

* deps(github_actions): updated dependencies
2022-10-12 00:10:55 +02:00
Felipe Martin Garcia 05fee53bd0
fix: saving bookmarks inconsistencies (#500)
* chore: updated go-migrate dependencies

* fix: specify if we're saving bookmarks expecting a creation

up until now the SaveBookmarks method was doing some "magic" to do
"upserts" on the databases, but consistency between engines was scarce
and not knowing if we were expecting saving a new bookmark or updating
an existing one was leading to errors and inconsistencies in logic all
around the place. Now we need to specify a creation boolean when
saving and a differnt query will be make (INSERT vs UPDATE).

* fix(api): using incorrect bookmark for content downlaod

* test(db): added test pipeline for databases

Added functions that will share logic among the engines and will be
called on fresh databases on each test run

* dev: added basic docker-compose for development

* chore: uncommented tests

* ci(test): added mysql service

* typo

* test(mysql): select database after reset

* fix(mysql): ignore empty row errors when parsing tags

* fix(mysql): handle insert errors

* chore: added mysql variables to compose

* ci: explicit mysql service port exposed
2022-10-11 23:47:38 +02:00
Felipe Martin Garcia dc73cd825b
fix(psql): save bookmarks not using passed bookmark id for the insert (#484)
* fix(psql): get last inserted id from insert query

book.ID was not being used, so inserts were failing.
the check for book.ID was removed and it is filled with the returning
id from the insert query

* test(psql): added save bookmarks simple test

* ci: added postgresql service

* fix(typo): QueryRow -> QueryRowContext

* ci: explicit postgresql port

* ci(test): 1.19 only

* ci: bind psql to localhost

* test(pg): migrate before test

* test(pg): migrate database before test

* fix(pg): check no rows error on get query
2022-10-09 17:05:30 +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 9397832485
fix: amd64 build paths (#429) 2022-05-26 19:29:11 +02: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
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
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
Dean Jackson c5fd20040a Add GitHub Action for tests & coverage 2020-08-06 21:08:43 +02:00