diff --git a/eleventy.config.js b/eleventy.config.js index 2097d5c..c7a0b37 100644 --- a/eleventy.config.js +++ b/eleventy.config.js @@ -55,6 +55,7 @@ export default function (eleventyConfig) { eleventyConfig.addPassthroughCopy({ "src/favicon/*" : "/" }); eleventyConfig.addGlobalData("pathPrefix", pathPrefix); eleventyConfig.addGlobalData("buildTime", buildTime); + eleventyConfig.addGlobalData("isProduction", isProd); eleventyConfig.addCollection("projects", function(collection) { const col = collection.getFilteredByGlob("src/projects/*/*.md"); diff --git a/src/_includes/author.njk b/src/_includes/author.njk index ff23671..03a3588 100644 --- a/src/_includes/author.njk +++ b/src/_includes/author.njk @@ -4,7 +4,9 @@ styles: ["project"] ---
Adrian Victor, 2025 (Unlicense)
diff --git a/src/_virtual/releases.njk b/src/_virtual/releases.njk index 21eb1f9..a0c9cb7 100644 --- a/src/_virtual/releases.njk +++ b/src/_virtual/releases.njk @@ -19,49 +19,53 @@ layout: base.njk {% endif %} {% if project.data.releaseType %} -{% if project.data.releaseType == "github" %} -{% set releases = project.data.githubRepoOwner | githubReleases(project.data.githubRepoName) %} -{{ releases | length }} releases fetched from GitHub at {{ buildTime }}.
-{{ release.tag_name }} for {{ project.data.gameLoaders or "unknown loader" }} {{ project.data.gameVersions or "unknow version" }}
- -{{ project.data.releases | length }} releases.
-Version {{ release.version }} for {{ release.gameLoaders or project.data.gameLoaders }} {{ release.gameVersions or project.data.gameVersions }}
- {% if release.downloads %} -Sorry, but this instance of neoBeta cannot fetch GitHub releases, please follow this link to see them.
+"Take us down, and we keep trying
Forty thousand feet, keep flying"
Fetched from GitHub at {{ buildTime }}.
+ {% else %} + {% set releases = project.data.releases %} {% endif %} -{{ releases | length }} releases.
+{{ release.tag_name }} for {{ project.data.gameLoaders or "unknown loader" }} {{ project.data.gameVersions or "unknow version" }}
+ {% else %} +Version {{ release.version }} for {{ project.data.gameLoaders or "unknown loader" }} {{ project.data.gameVersions or "unknow version" }}
+ {% endif %} +Could not find any release for this project...
+Could not find any release for this project...
{% endif %} diff --git a/src/contribute.md b/src/contribute.md deleted file mode 100644 index e96b1ec..0000000 --- a/src/contribute.md +++ /dev/null @@ -1,72 +0,0 @@ ---- -layout: "base.njk" ---- -## How can I get my project here? - -neoBeta is an open-source content management system. There are various ways you can put your plugin/mod on our catalog: - - Clone [neoBeta's repository](https://github.com/adrianvic/neoBeta), create your project folder inside the /projects directory with the necessary metadata (index.md for project description, index.json for metadata and any other file your project may depend on) and make a pull request. Less manual work on our side, so review should be quickier. - - Open an issue on our GitHub repository with the project information. This may take longer as a contributor will have to spend time creating the project files, but is useful if you're not confortable using Git. - - Host your own instance of neoBeta. - -### Required metadata fields - - *name* - project name. - - *subtitle* - project's brief description. - - *author* - your author name, must be consistent across all your submissions. - - *tags* - whether your project is a plugin or mod. - -### Optional metadata fields -Please fill as many fields as possible. - - *images* - lists of image files names or URLs that will appear in the project page. - - *logo* - your logo file name or URL. - - *gameVersions* - taget Minecraft versions. - - *gameLoaders* - supported modloaders. - -### Releases metadata - - *releasesType* - wheter your project uses `local` releases or `github`. - -For local releases: - - *releases* - a list of relases labels and links. - - *name* - name of the release. - - *version* - version of the release. - - *gameVersions* - taget Minecraft versions (overrides default value). - - *gameLoaders* - supported modloaders (overrides default value). - - *downloads* - list of download links for this release. - -For GitHub releases: - - *githubRepoOwner* - username of the repo owner. - - *githubReponame* - name of the repository. - -### Config file example -``` -{ - "name": "Ghosts 'n Stuff", - "subtitle": "Miscellaneous additions to your Minecraft server.", - "author": "tenkuma", - "downloadLink": "https://modrinth.com/plugin/ghosts/versions", - "images": ["anti-spam.png", "rainbow-chat.png", "skibidi-blocker.png"], - "logo": "logo.png", - "tags": ["plugin"], - "links": { - "GitHub": "https://github.com/adrianvic/ghostsandstuff", - "Disroot Git": "https://git.disroot.org/adrianvictor/ghostsandstuff" - }, - "docs": { - "Installation" : "docs/installation" - }, - "releaseType": "github or local", - "githubRepoOwner": "adrianvic", - "githubRepoName": "ghostsandstuff", - "gameLoaders": ["Craftbukkit"] - "releases": [ - { - "name": "The first release.", - "version": "1.0.0", - "gameVersions": ["b1.7.3"], - "downloads": { - "GitHub": "https://example.com", - "Modrinth": "https://modrinth.com" - } - } - ] -} -``` \ No newline at end of file