2884 Commits

Author SHA1 Message Date
Redblueflame
38b7d9724e
feat(migration): Added automatic migration (#54) 2020-08-28 08:48:01 -07:00
Geometrically
2b1ed49e9a
Update Meilisearch SDK (#53)
* Update Meilisearch SDK

* Run Formatter

* Fixes
2020-08-27 17:53:40 -07:00
Geometrically
017cf9e464
Make CORS work (#52)
* Make CORS work

* Add use statement

* Add to TOML
2020-08-27 08:47:18 -07:00
Aeledfyr
781f0c843e
Implement more database methods and basic API routes (#50)
* feat: Implement more database methods & add mod and version routes

* feat: Implement deleting mods/versions & implement categories

* feat: Implement routes for categories, game versions & loaders

* feat: Reorganize API routes in a (hopefully) usable way
2020-08-12 12:54:03 -07:00
Geometrically
e2bf474332
Version Creation (#47)
* Creation Stuff

* Make it work

* Response structs + Mod ID validation

* Run code formatter

* Push local changes

* Finish up version creation - fix comments, impl file creation

* fix: Add sqlx prepare data

Co-authored-by: Aeledfyr <aeledfyr@gmail.com>
2020-08-12 11:05:49 -07:00
AppleTheGolden
7e2f1c9a8b
Update rust version in dockerfile (#49) 2020-08-02 09:48:02 -07:00
Aeledfyr
8e798dde48
feat(search): Faceted search based on mod host (curse/modrinth) (#48)
This also adds a commandline argument library (gumdrop) for dealing
with indices - reseting, reconfiguring, and skipping them. I don't
know which library is best for this case, but gumdrop has shorter
compile times and many fewer dependencies than clap, which is why
I chose it.
2020-07-31 18:18:23 -07:00
Aeledfyr
c05ae6e94c
fix(postgres): Fix sqlx's misinterpretation of Ids, update sqlx (#46) 2020-07-30 20:45:22 -07:00
Aeledfyr
ff28ea8fa8
Refactor Meilisearch, update to latest SDK, and implement faceted search (#44)
* feat(indexing): Reindex curseforge & local database at an interval

* fix(indexing): Use strings for meilisearch primary key

Fixes #17 by prefixing curseforge ids with "curse-" and local ids
with "local-".

* feat(indexing): Add newly created mods to the index more quickly

* feat(indexing): Implement faceted search, update to meilisearch master

Fixes #9, but only uses faceted search for categories.  It should
be reasonably simple to add support for versions, but it may not
be as useful due to the large number of versions and the large
number of supported versions for each mod.

* feat(indexing): Allow skipping initial indexing

Co-authored-by: Geometrically <18202329+Geometrically@users.noreply.github.com>
2020-07-27 16:54:10 -07:00
Charalampos Fanoulis
7914e89212
fix: quote the numbers on the github label (#43) 2020-07-23 23:26:53 +02:00
Valentin Ricard
558ff90e27
fix/ci: Fix build matrix (#42)
* ci: Test #1

* ci: Test #2

* ci: Fix an unrelated issue

* ci: Restore the branch filter
2020-07-23 23:18:36 +02:00
AppleTheGolden
ee69653a83
Switch to Postgres (#39)
* WIP Switch to Postgres

* feat(postgres): more work on porting to postgres, now compiles

* feat(docker-compose): Changed the docker-compose.yml file to use postgres.

* Update docker, documentation, gh actions...

* Remove bson dependency

* Remove bson import

* feat: move mock filehost to trait rather than cargo feature

* feat(postgres): transactions for mod creation, multipart refactor

* fix: Add Cargo.lock so that sqlx functions

* Update sqlx offline build data

* fix: Use SQLX_OFFLINE to force sqlx into offline mode for CI

* Default release channels

* feat(postgres): refactor database models to fit postgres models

* fix: Fix sqlx prepare, fix double allocation in indexing

* Add dockerfile (#40)

Co-authored-by: Charalampos Fanoulis <charalampos.fanoulis@gmail.com>

Co-authored-by: Aeledfyr <aeledfyr@gmail.com>
Co-authored-by: redblueflame <contact@redblueflame.com>
Co-authored-by: Jai A <jai.a@tuta.io>
Co-authored-by: Valentin Ricard <redblueflame1@gmail.Com>
Co-authored-by: Charalampos Fanoulis <charalampos.fanoulis@gmail.com>
2020-07-23 22:46:33 +02:00
Siphalor
2d7760e67c
Add line ending configuration (#4) 2020-07-17 20:38:16 +03:00
Aeledfyr
95339a8338
Create a mock file host for dev, Fix mod creation route (#38)
* fix(mod-creation): fix actix server data & mod creation route

* feat(file-host): implement mock file hosting

This implements a mock file hosting system backed by the system's
filesystem.  It mirrors the API of the backblaze integration, but
puts the files directly on disk in the path specified by the
MOCK_FILE_PATH environment variable (defaults to /tmp/modrinth).

The mock file hosting is enabled by default using cargo features
to allow people to work on modrinth without access to a valid
backblaze account and setup.  To enable backblaze, specify the
cargo feature "backblaze" when running, ex. `cargo run --features
backblaze`.

* feat(file-hosting): implement basic backblaze API error handling

* fix(mod-creation): fix extension parsing, use base62 ids for paths
fix(file-hosting): reduce unnecessary allocations

* fix: fix auth with docker mongodb

* fix: fix failing checks

* fix: remove testing files
2020-07-16 21:06:58 -07:00
Geometrically
39b1435725
Mod Creation (#34)
* Inital creation stuff

* File Reader

* Upload bodies

* Major rework:

* Finish Multiple Files

* Proper Error Handling

* Switch to database models

* Run formatter

* Make dependencies dependent on Versions over mods

* Fixes

* Fix clippy

* Run lint one last time

* Update src/models/mods.rs

Co-authored-by: AppleTheGolden <scotsbox@protonmail.com>

Co-authored-by: AppleTheGolden <scotsbox@protonmail.com>
2020-07-16 10:16:35 -07:00
Aeledfyr
b1d3e258bd
fix(indexing): chunk adding documents to indexing server (#36)
This should prevent adding too many mods and going over
meilisearch's request size limit by attempting to add all mods in
one request.
2020-07-15 15:01:49 -07:00
Mikhail Oleynikov
c915926e0f Merge branch 'master' of github.com:modrinth/dungeon 2020-07-14 16:43:03 +03:00
Mikhail Oleynikov
25203934e6 Switch to Nuxt 2020-07-14 16:42:46 +03:00
Aeledfyr
6ff7fa74e2
Improve error handling (#33)
* refactor: improve error handling

* fix: specify bind address instead of port

* fix: remove temporary testing file

* fix(errors): change error names to snake_case

* refactor(errors): split indexing error types, remove unused errors

* feat: add env variable checking at program start

This just checks whether the enviroment variables exist and can
parse to the given type and gives a warning if they can't. This
should prevent cases where the program fails at runtime due to
checking an environment variable that doesn't exist.
2020-07-03 10:44:39 -07:00
Geometrically
91305262f1
Add Backblaze Driver (#32)
* Backblaze Driver

* Update action to work with new tests

* Fix minor issues

* Run Formatter + Switch to reqwest json parser
2020-07-02 14:00:04 +02:00
Aeledfyr
6d16b68f11
Create schema for the API (#28)
* feat(schema): add basic structs for schema

* feat(schema): implement base62 id parsing

* docs(schema): add documentation for schema structs
fix(schema): prevent integer overflow in base62 decoding

* refactor(schema): move ids into submodules, reexport from ids mod

* feat(schema): add random generation of base62 ids
style: run rustfmt
2020-07-01 22:24:42 +02:00
Charalampos Fanoulis
f22e4f1cc7
feat: Add label syncing. (#30)
* ci: Add label syncing

* ci: add more label sprinkles
2020-07-01 11:32:23 -07:00
Geometrically
4b1b2878ea Create LICENSE.md 2020-07-01 11:15:45 +03:00
MulverineX
2851d12357
readme edits (#29)
* Update README.md

* Update README.md
2020-07-01 08:43:44 +02:00
Valentin Ricard
73968e4277
fix(env): Hotfixed the env name (#27) 2020-06-30 20:00:41 +02:00
Valentin Ricard
7a6ecd86c6
Rewrite the app (#23)
* chore: Removed everything not needed, and added base for rewrite
feat(error_handling): Added 404 general cache
feat(index): Added informations about the app in the / route.

* feat(indexing): Brought back the indexing, with conditions to make it easier

* fix: Fixed build error with a forgotten call

* feat: Add Docker development enviroment (#19)

* ci: add a *lot* of new actions

* fix: rename linting action

* fix: invalid yaml begone(?)

* ci: Added cache to speed up build times

* fix(ci): 🦀ed the yaml errors

* fix(ci): fixed a missing hyphen

* ci: Added matrix of rust versions, and changed way to install rust toolchain

* fix(ci): Added names to build with the matrix so it's easier to find the source of the problem

* style(ci): Added eof lines

* refactor: Finished moving the search.rs file to a separate module.

* Search Endpoint

* refactor: Moved around functions and struct for a better understanding of what it does.

* chore: Change env default settings to resolve conversation

* refactor: Removed #[use_macros]
fix: Fixed meilisearch address from env

* chore: Added email to Aeledfyr

* fix: Brought back the dotenv variables

* style: Ran `cargo fmt`

Co-authored-by: Charalampos Fanoulis <charalampos.fanoulis@gmail.com>
Co-authored-by: Jai A <jai.a@tuta.io>
2020-06-30 19:23:52 +02:00
Mikhail Oleynikov
b11d5514b9 Initial commit 2020-06-29 11:56:46 +03:00
Jai A
1ff2a08d19 Final push before rewrite 2020-06-28 13:53:03 -07:00
Geometrically
d1efd62e7b
Merge pull request #14 from Aeledfyr/master
Minify icons and implement SVG spritesheets
2020-06-27 20:18:01 -07:00
Aeledfyr
366c95cd3c
Fix a few display bugs 2020-06-27 17:30:35 -05:00
Aeledfyr
7e03f3958e
Implement SVG sprite sheet for icons, use thumbnails for mod icons 2020-06-27 17:30:34 -05:00
Aeledfyr
e069184721
Compress/Minify icons 2020-06-27 17:26:59 -05:00
Geometrically
5182441cb3
Merge pull request #12 from joaoh1/master
Make category badges more generic
2020-06-27 15:06:02 -07:00
joaoh1
0de55a8ff5 Make category badges more generic 2020-06-27 16:22:09 -03:00
Jai A
0900d7c764 Add staging popup 2020-06-27 10:29:49 -07:00
Jai A
8540e09ba7 Fix #11 and Cleanup dependencies 2020-06-26 22:35:20 -07:00
Jai A
6e301601f9 Fix minor styling issues 2020-06-25 22:40:29 -07:00
Geometrically
1bf0eab2d9
Merge pull request #7 from Aeledfyr/master
Improve styling for narrower screens
2020-06-25 19:23:16 -07:00
Aeledfyr
d560f656f4
Reduce duplication of Forge logo using svg <use>
This uses svg <use href="#..."> to avoid having to duplicate the
logo at every use.  Surprisingly this just works with the current
theme css, and doesn't require any changes.
2020-06-25 21:14:50 -05:00
Aeledfyr
0bc256aa23
Miscellaneous fixes and requested changes 2020-06-25 20:19:07 -05:00
Aeledfyr
ebc073a52e
Tweak styles for narrower screens, add indicator for no results
Makes the styles of search results work better with narrower
screens.  The category badges on each result collapse to just an
icon (with title text) when the screen is too narrow.

Adds a text label for the Forge/Fabric icons.

Adds a message for when a query returns no results.
2020-06-25 17:14:12 -05:00
Jai A
23503dc439 Base creation page 2020-06-22 21:04:17 -07:00
Geometrically
1f4985c7dd
Merge pull request #6 from emilyploszaj/master
Implemented a dark theme
2020-06-22 19:57:37 -07:00
emilyploszaj
ed88d9e10d Implemented a dark theme 2020-06-22 21:48:42 -05:00
Jai A
906196bac3 Staging Test 2020-06-20 18:19:19 -07:00
Jai A
cb9751be04 Add CONTRIBUTING.md 2020-06-19 20:19:19 -07:00
Geometrically
09e03d579b
Merge pull request #4 from Geometrically/dependabot/add-v2-config-file
Create Dependabot config file
2020-06-18 22:21:47 -07:00
dependabot-preview[bot]
9fcca2698e
Create Dependabot config file 2020-06-19 05:21:30 +00:00
Geometrically
bba8cd9b58
Merge pull request #2 from Geometrically/dependabot/cargo/bson-1.0.0
Update bson requirement from 0.14.1 to 1.0.0
2020-06-18 22:21:07 -07:00
dependabot-preview[bot]
c8bb30289a
Update bson requirement from 0.14.1 to 1.0.0
Updates the requirements on [bson](https://github.com/mongodb/bson-rust) to permit the latest version.
- [Release notes](https://github.com/mongodb/bson-rust/releases)
- [Commits](https://github.com/mongodb/bson-rust/compare/v0.14.1...v1.0.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-06-19 05:13:06 +00:00