diff --git a/.github/SECURITY.md b/.github/SECURITY.md index ed2a7c4a..6957730e 100644 --- a/.github/SECURITY.md +++ b/.github/SECURITY.md @@ -2,7 +2,7 @@ ## Supported Versions -We only support the latest production version, deployed to . +We only support the latest production version, deployed to . This is usually the latest `master` commit. ## Reporting a Vulnerability diff --git a/app/blueprints/feeds/__init__.py b/app/blueprints/feeds/__init__.py index 900c36a1..ccae41ba 100644 --- a/app/blueprints/feeds/__init__.py +++ b/app/blueprints/feeds/__init__.py @@ -30,9 +30,9 @@ def _make_feed(title: str, feed_url: str, items: list): "version": "https://jsonfeed.org/version/1", "title": title, "description": gettext("Welcome to the best place to find Luanti mods, games, and texture packs"), - "home_page_url": "https://content.minetest.net/", + "home_page_url": "https://content.luanti.org/", "feed_url": feed_url, - "icon": "https://content.minetest.net/favicon-128.png", + "icon": "https://content.luanti.org/favicon-128.png", "expired": False, "items": items, } diff --git a/app/flatpages/help/api.md b/app/flatpages/help/api.md index a5e6e9dc..1aad0730 100644 --- a/app/flatpages/help/api.md +++ b/app/flatpages/help/api.md @@ -54,7 +54,7 @@ The response will be a dictionary with the following keys: Not all endpoints require authentication, but it is done using Bearer tokens: ```bash -curl https://content.minetest.net/api/whoami/ \ +curl https://content.luanti.org/api/whoami/ \ -H "Authorization: Bearer YOURTOKEN" ``` @@ -68,7 +68,7 @@ Tokens can be attained by visiting [Settings > API Tokens](/user/tokens/). ```bash # Logout -curl -X DELETE https://content.minetest.net/api/delete-token/ \ +curl -X DELETE https://content.luanti.org/api/delete-token/ \ -H "Authorization: Bearer YOURTOKEN" ``` @@ -167,20 +167,20 @@ curl -X DELETE https://content.minetest.net/api/delete-token/ \ You can download a package by building one of the two URLs: ``` -https://content.minetest.net/packages/${author}/${name}/download/` -https://content.minetest.net/packages/${author}/${name}/releases/${release}/download/` +https://content.luanti.org/packages/${author}/${name}/download/` +https://content.luanti.org/packages/${author}/${name}/releases/${release}/download/` ``` Examples: ```bash # Edit package -curl -X PUT https://content.minetest.net/api/packages/username/name/ \ +curl -X PUT https://content.luanti.org/api/packages/username/name/ \ -H "Authorization: Bearer YOURTOKEN" -H "Content-Type: application/json" \ -d '{ "title": "Foo bar", "tags": ["pvp", "survival"], "license": "MIT" }' # Remove website URL -curl -X PUT https://content.minetest.net/api/packages/username/name/ \ +curl -X PUT https://content.luanti.org/api/packages/username/name/ \ -H "Authorization: Bearer YOURTOKEN" -H "Content-Type: application/json" \ -d '{ "website": null }' ``` @@ -271,7 +271,7 @@ Examples: ```bash # Create release from Git -curl -X POST https://content.minetest.net/api/packages/username/name/releases/new/ \ +curl -X POST https://content.luanti.org/api/packages/username/name/releases/new/ \ -H "Authorization: Bearer YOURTOKEN" -H "Content-Type: application/json" \ -d '{ "method": "git", @@ -282,17 +282,17 @@ curl -X POST https://content.minetest.net/api/packages/username/name/releases/ne }' # Create release from zip upload -curl -X POST https://content.minetest.net/api/packages/username/name/releases/new/ \ +curl -X POST https://content.luanti.org/api/packages/username/name/releases/new/ \ -H "Authorization: Bearer YOURTOKEN" \ -F title="My Release" -F file=@path/to/file.zip # Create release from zip upload with commit hash -curl -X POST https://content.minetest.net/api/packages/username/name/releases/new/ \ +curl -X POST https://content.luanti.org/api/packages/username/name/releases/new/ \ -H "Authorization: Bearer YOURTOKEN" \ -F title="My Release" -F commit="8ef74deec170a8ce789f6055a59d43876d16a7ea" -F file=@path/to/file.zip # Delete release -curl -X DELETE https://content.minetest.net/api/packages/username/name/releases/3/ \ +curl -X DELETE https://content.luanti.org/api/packages/username/name/releases/3/ \ -H "Authorization: Bearer YOURTOKEN" ``` @@ -333,26 +333,26 @@ Examples: ```bash # Create screenshot -curl -X POST https://content.minetest.net/api/packages/username/name/screenshots/new/ \ +curl -X POST https://content.luanti.org/api/packages/username/name/screenshots/new/ \ -H "Authorization: Bearer YOURTOKEN" \ -F title="My Release" -F file=@path/to/screnshot.png # Create screenshot and set it as the cover image -curl -X POST https://content.minetest.net/api/packages/username/name/screenshots/new/ \ +curl -X POST https://content.luanti.org/api/packages/username/name/screenshots/new/ \ -H "Authorization: Bearer YOURTOKEN" \ -F title="My Release" -F file=@path/to/screnshot.png -F is_cover_image="true" # Delete screenshot -curl -X DELETE https://content.minetest.net/api/packages/username/name/screenshots/3/ \ +curl -X DELETE https://content.luanti.org/api/packages/username/name/screenshots/3/ \ -H "Authorization: Bearer YOURTOKEN" # Reorder screenshots -curl -X POST https://content.minetest.net/api/packages/username/name/screenshots/order/ \ +curl -X POST https://content.luanti.org/api/packages/username/name/screenshots/order/ \ -H "Authorization: Bearer YOURTOKEN" -H "Content-Type: application/json" \ -d "[13, 2, 5, 7]" # Set cover image -curl -X POST https://content.minetest.net/api/packages/username/name/screenshots/cover-image/ \ +curl -X POST https://content.luanti.org/api/packages/username/name/screenshots/cover-image/ \ -H "Authorization: Bearer YOURTOKEN" -H "Content-Type: application/json" \ -d "{ 'cover_image': 123 }" ``` diff --git a/app/flatpages/help/appealing_page.md b/app/flatpages/help/appealing_page.md index 87675be4..23835126 100644 --- a/app/flatpages/help/appealing_page.md +++ b/app/flatpages/help/appealing_page.md @@ -36,7 +36,7 @@ The target audience of your package page is end users. The long description should explain what your package is about, why the user should choose it, and how to use it if they download it. -[NodeCore](https://content.minetest.net/packages/Warr1024/nodecore/) is a good +[NodeCore](https://content.luanti.org/packages/Warr1024/nodecore/) is a good example of what to do. For inspiration, you might want to look at how games on Steam write their descriptions. diff --git a/app/flatpages/help/copyright.md b/app/flatpages/help/copyright.md index c8d9dfb9..1eb1061f 100644 --- a/app/flatpages/help/copyright.md +++ b/app/flatpages/help/copyright.md @@ -48,7 +48,7 @@ It's common to do this in README.md or LICENSE.md like so: * conquer_arrow_*.png from [Simple Shooter](https://github.com/stujones11/shooter) by Stuart Jones, CC0 1.0. * conquer_arrow.b3d from [Simple Shooter](https://github.com/stujones11/shooter) by Stuart Jones, CC-BY-SA 3.0. * conquer_arrow_head.png from MTG, CC-BY-SA 3.0. -* health_*.png from [Gauges](https://content.minetest.net/packages/Calinou/gauges/) by Calinou, CC0. +* health_*.png from [Gauges](https://content.luanti.org/packages/Calinou/gauges/) by Calinou, CC0. ``` if you have a lot of media, then you can split it up by author like so: diff --git a/app/flatpages/help/feeds.md b/app/flatpages/help/feeds.md index 162e2ed0..6ccecbc7 100644 --- a/app/flatpages/help/feeds.md +++ b/app/flatpages/help/feeds.md @@ -11,6 +11,6 @@ You can follow updates from ContentDB in your RSS feed reader. If in doubt, copy Follow new releases for a package: ``` -https://content.minetest.net/packages/AUTHOR/NAME/releases_feed.atom -https://content.minetest.net/packages/AUTHOR/NAME/releases_feed.json +https://content.luanti.org/packages/AUTHOR/NAME/releases_feed.atom +https://content.luanti.org/packages/AUTHOR/NAME/releases_feed.json ``` diff --git a/app/flatpages/help/oauth.md b/app/flatpages/help/oauth.md index 99487e29..a93cc163 100644 --- a/app/flatpages/help/oauth.md +++ b/app/flatpages/help/oauth.md @@ -27,7 +27,7 @@ ContentDB supports the Authorization Code OAuth2 method. Get the user to open the following URL in a web browser: ``` -https://content.minetest.net/oauth/authorize/ +https://content.luanti.org/oauth/authorize/ ?response_type=code &client_id={CLIENT_ID} &redirect_uri={REDIRECT_URL} @@ -52,7 +52,7 @@ Next, you'll need to exchange the auth for an access token. Do this by making a POST request to the `/oauth/token/` API: ```bash -curl -X POST https://content.minetest.net/oauth/token/ \ +curl -X POST https://content.luanti.org/oauth/token/ \ -F grant_type=authorization_code \ -F client_id="CLIENT_ID" \ -F client_secret="CLIENT_SECRET" \ @@ -98,6 +98,6 @@ Possible errors: Next, you should check the access token works by getting the user information: ```bash -curl https://content.minetest.net/api/whoami/ \ +curl https://content.luanti.org/api/whoami/ \ -H "Authorization: Bearer YOURTOKEN" ``` diff --git a/app/flatpages/help/release_webhooks.md b/app/flatpages/help/release_webhooks.md index 7d4c303c..f8aae5a3 100644 --- a/app/flatpages/help/release_webhooks.md +++ b/app/flatpages/help/release_webhooks.md @@ -39,7 +39,7 @@ Tag-based webhooks are accepted on any branch. 1. Create a ContentDB API Token at [Profile > API Tokens: Manage](/user/tokens/). 2. Copy the access token that was generated. 3. Go to the GitLab repository's settings > Webhooks > Add Webhook. -4. Set the payload URL to `https://content.minetest.net/github/webhook/` +4. Set the payload URL to `https://content.luanti.org/github/webhook/` 5. Set the content type to JSON. 6. Set the secret to the access token that you copied. 7. Set the events @@ -53,7 +53,7 @@ Tag-based webhooks are accepted on any branch. 1. Create a ContentDB API Token at [Profile > API Tokens: Manage](/user/tokens/). 2. Copy the access token that was generated. 3. Go to the GitLab repository's settings > Webhooks. -4. Set the URL to `https://content.minetest.net/gitlab/webhook/` +4. Set the URL to `https://content.luanti.org/gitlab/webhook/` 6. Set the secret token to the ContentDB access token that you copied. 7. Set the events * If you want a rolling release, choose "Push events". diff --git a/app/models/users.py b/app/models/users.py index b7909fba..7f80a4fc 100644 --- a/app/models/users.py +++ b/app/models/users.py @@ -260,7 +260,7 @@ class User(db.Model, UserMixin): return "/static/bot_avatar.png" else: from app.utils.gravatar import get_gravatar - return get_gravatar(self.email or f"{self.username}@content.minetest.net") + return get_gravatar(self.email or f"{self.username}@content.luanti.org") def check_perm(self, user, perm): if not user.is_authenticated: diff --git a/app/public/static/opensearch.xml b/app/public/static/opensearch.xml index fa2465c5..73afbed7 100644 --- a/app/public/static/opensearch.xml +++ b/app/public/static/opensearch.xml @@ -5,5 +5,5 @@ UTF-8 Search mods, games, and textures for Luanti. Luanti Minetest Mod Game Subgame Search - + diff --git a/app/tasks/pkgtasks.py b/app/tasks/pkgtasks.py index 0a6df834..d3f79d82 100644 --- a/app/tasks/pkgtasks.py +++ b/app/tasks/pkgtasks.py @@ -111,7 +111,7 @@ def clear_removed_packages(all_packages: bool): def _url_exists(url: str) -> str: try: headers = { - "User-Agent": "Mozilla/5.0 (compatible; ContentDB link checker; +https://content.minetest.net/)", + "User-Agent": "Mozilla/5.0 (compatible; ContentDB link checker; +https://content.luanti.org/)", } with requests.get(url, stream=True, headers=headers, timeout=10) as response: response.raise_for_status() diff --git a/app/templates/index.html b/app/templates/index.html index e8a7fe43..abd3ceb8 100644 --- a/app/templates/index.html +++ b/app/templates/index.html @@ -13,10 +13,10 @@ { "@context": "https://schema.org", "@type": "WebSite", - "url": "https://content.minetest.net/", + "url": "https://content.luanti.org/", "potentialAction": { "@type": "SearchAction", - "target": "https://content.minetest.net/packages?q={search_term_string}", + "target": "https://content.luanti.org/packages?q={search_term_string}", "query-input": "required name=search_term_string" } } diff --git a/docs/README.md b/docs/README.md index 00cda9c9..56eb04fc 100644 --- a/docs/README.md +++ b/docs/README.md @@ -3,4 +3,4 @@ This folder only contains technical documentation for those interested in the ContentDB source code. Documentation for using ContentDB, whether through the interface or API, is available at -. +. diff --git a/docs/minetest_client.md b/docs/minetest_client.md index 510642f4..0f3aa683 100644 --- a/docs/minetest_client.md +++ b/docs/minetest_client.md @@ -6,14 +6,14 @@ or for implementing ContentDB compatible servers. ## Package List API call -The client makes a single [API](https://content.minetest.net/help/api/) request to `/api/packages/`. +The client makes a single [API](https://content.luanti.org/help/api/) request to `/api/packages/`. The query arguments will include a list of supported types, the current -[engine version](https://content.minetest.net/api/minetest_versions/), -and any hidden [Content Flags](https://content.minetest.net/help/content_flags/). +[engine version](https://content.luanti.org/api/minetest_versions/), +and any hidden [Content Flags](https://content.luanti.org/help/content_flags/). Example URL: - + Example response: @@ -24,7 +24,7 @@ Example response: "name": "nodecore", "release": 1234, "short_description": "A short description", - "thumbnail": "https://content.minetest.net/thumbnails/1/abcdef.jpg", + "thumbnail": "https://content.luanti.org/thumbnails/1/abcdef.jpg", "title": "NodeCore", "type": "game" } @@ -50,7 +50,7 @@ The client can simply download the URL mentioned in `thumbnail`. The client downloads packages by constructing a URL for the release and downloading it: ``` -https://content.minetest.net/packages///releases//download/ +https://content.luanti.org/packages///releases//download/ ``` This supports redirects. @@ -104,5 +104,5 @@ response for Mobs Monster. The client will open the package in a browser by constructing the following URL ``` -https://content.minetest.net/packages/// +https://content.luanti.org/packages/// ``` diff --git a/utils/extract_translations.py b/utils/extract_translations.py index 0424b369..ed914d58 100755 --- a/utils/extract_translations.py +++ b/utils/extract_translations.py @@ -6,7 +6,7 @@ from typing import List import requests -base_url = "https://content.minetest.net" +base_url = "https://content.luanti.org" translations = []