mirror of
https://github.com/Ryubing/Website.git
synced 2025-05-13 03:00:37 +01:00
add workflow to check for new releases everyday
This commit is contained in:
parent
476af381a2
commit
0e259aa954
7 changed files with 38 additions and 16 deletions
26
.github/workflows/fetch-releases.yml
vendored
Normal file
26
.github/workflows/fetch-releases.yml
vendored
Normal file
|
@ -0,0 +1,26 @@
|
|||
name: fetch releases
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '0 0 * * *'
|
||||
|
||||
jobs:
|
||||
fetch-release:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout Repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: '16'
|
||||
|
||||
- name: install dependencies
|
||||
run: |
|
||||
npm install
|
||||
|
||||
- name: run fetchreleases
|
||||
run: |
|
||||
npx tsx src/lib/fetchReleases.ts
|
|
@ -9,7 +9,7 @@ import StyleConstants from "./styleconstants.astro"
|
|||
<meta charset="UTF-8" />
|
||||
<meta
|
||||
name="description"content="Ryubing/Ryujinx is a fork of the discontinued Nintendo Switch emulator, written in C#. It offers excellent accuracy, high performance, a user-friendly interface, and consistent builds."/>
|
||||
<meta name="keywords" content="Ryujinx, switch emulator, fork, emulator, switch, ryubing, ldn, open-source"/>
|
||||
<meta name="keywords" content="Ryujinx, nintendo switch emulator, nintendo switch, switch, switch emulator, emulator fork, ryubing, ldn, open-source"/>
|
||||
<meta name="author" content="Ryujinx" />
|
||||
<meta name="viewport" content="width=device-width initial-scale=1.0" />
|
||||
<link rel="icon" type="image/png" href="/favicon.png" />
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
export default class Consts {
|
||||
static readonly WINDOWS_URL = "https://github.com/Ryubing/Ryujinx/releases/download/1.2.82/ryujinx-1.2.82-win_x64.zip" as const;
|
||||
static readonly MACOS_URL = "https://github.com/Ryubing/Ryujinx/releases/download/1.2.82/ryujinx-1.2.82-macos_universal.app.tar.gz" as const;
|
||||
static readonly LINUX_URL = "https://github.com/Ryubing/Ryujinx/releases/download/1.2.82/ryujinx-1.2.82-linux_x64.tar.gz" as const;
|
||||
static readonly LINUXARM_URL = "https://github.com/Ryubing/Ryujinx/releases/download/1.2.82/ryujinx-1.2.82-linux_arm64.tar.gz" as const;
|
||||
static readonly GITHUB_URL = "https://github.com/Ryubing/Ryujinx/releases" as const;
|
||||
}
|
||||
static readonly WINDOWS_URL = "https://github.com/Ryubing/Stable-Releases/releases/download/1.2.86/ryujinx-1.2.86-win_x64.zip" as const;
|
||||
static readonly MACOS_URL = "https://github.com/Ryubing/Stable-Releases/releases/download/1.2.86/ryujinx-1.2.86-macos_universal.app.tar.gz" as const;
|
||||
static readonly LINUX_URL = "https://github.com/Ryubing/Stable-Releases/releases/download/1.2.86/ryujinx-1.2.86-linux_x64.tar.gz" as const;
|
||||
static readonly LINUXARM_URL = "https://github.com/Ryubing/Stable-Releases/releases/download/1.2.86/ryujinx-1.2.86-linux_arm64.tar.gz" as const;
|
||||
static readonly GITHUB_URL = "https://github.com/Ryubing/Stable-Releases/releases/" as const;
|
||||
}
|
|
@ -1,6 +0,0 @@
|
|||
export type ChangelogProduct = "web" | "android" | "ios" | "api" | "all"
|
||||
export type Store = {
|
||||
name: string
|
||||
url: string
|
||||
primary: boolean
|
||||
}
|
|
@ -4,7 +4,7 @@ import path from "path";
|
|||
|
||||
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
||||
|
||||
const GITHUB_REPO = "Ryubing/Ryujinx";
|
||||
const GITHUB_REPO = "Ryubing/Stable-Releases";
|
||||
const API_URL = `https://api.github.com/repos/${GITHUB_REPO}/releases/latest`;
|
||||
|
||||
interface ReleaseAsset {
|
||||
|
@ -29,6 +29,7 @@ async function fetchLatestRelease() {
|
|||
MACOS_URL: assets.find(asset => asset.name.includes("macos_universal.app.tar.gz"))?.browser_download_url || "",
|
||||
LINUX_URL: assets.find(asset => asset.name.includes("linux_x64.tar.gz"))?.browser_download_url || "",
|
||||
LINUXARM_URL: assets.find(asset => asset.name.includes("linux_arm64.tar.gz"))?.browser_download_url || "",
|
||||
GITHUB_URL: "https://github.com/Ryubing/Stable-Releases/releases/"
|
||||
};
|
||||
|
||||
// update Consts class
|
||||
|
@ -37,6 +38,7 @@ async function fetchLatestRelease() {
|
|||
static readonly MACOS_URL = "${downloads.MACOS_URL}" as const;
|
||||
static readonly LINUX_URL = "${downloads.LINUX_URL}" as const;
|
||||
static readonly LINUXARM_URL = "${downloads.LINUXARM_URL}" as const;
|
||||
static readonly GITHUB_URL = "${downloads.GITHUB_URL}" as const;
|
||||
}`;
|
||||
|
||||
fs.writeFileSync(path.join(__dirname, "../lib/consts.ts"), constsContent);
|
||||
|
|
|
@ -10,7 +10,7 @@ export const prerender = false;
|
|||
<title>Ryujinx - Donate</title>
|
||||
<meta
|
||||
name="description"content="Donate to support the Ryujinx project and help us continue improving the emulator.">
|
||||
<meta name="keywords" content="Ryujinx, switch emulator, fork, emulator, switch, ryubing, ldn, open-source"/>
|
||||
<meta name="keywords" content="Ryujinx, nintendo switch emulator, nintendo switch, switch, switch emulator, emulator fork, ryubing, ldn, open-source"/>
|
||||
<meta name="robots" content="max-snippet:-1, max-image-preview:large, max-video-preview:-1">
|
||||
<meta name="author" content="Ryujinx" />
|
||||
<meta name="viewport" content="width=device-width" />
|
||||
|
|
|
@ -13,7 +13,7 @@ export const prerender = false;
|
|||
<title>Ryujinx - Download</title>
|
||||
<meta
|
||||
name="description"content="Download Ryujinx for Windows, MacOS, Linux, and Linux ARM.">
|
||||
<meta name="keywords" content="Ryujinx, switch emulator, fork, emulator, switch, ryubing, ldn, open-source"/>
|
||||
<meta name="keywords" content="Ryujinx, nintendo switch emulator, nintendo switch, switch, switch emulator, emulator fork, ryubing, ldn, open-source"/>
|
||||
<meta name="robots" content="max-snippet:-1, max-image-preview:large, max-video-preview:-1">
|
||||
<meta name="author" content="Ryujinx" />
|
||||
<meta name="viewport" content="width=device-width" />
|
||||
|
|
Loading…
Reference in a new issue