mirror of
https://github.com/5rahim/seanime
synced 2026-04-18 22:24:55 +02:00
feat: update workflow
This commit is contained in:
4
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
4
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
@@ -14,7 +14,7 @@ body:
|
||||
My version of the app is the latest available
|
||||
required: true
|
||||
- label: >-
|
||||
I have checked open and closed [issues](https://github.com/1sailor/sea/issues)
|
||||
I have checked open and closed [issues](https://github.com/5rahim/seanime/issues)
|
||||
required: true
|
||||
- label: >-
|
||||
I have checked the [docs](https://seanime.rahim.app/docs/faq) for a fix
|
||||
@@ -49,7 +49,7 @@ body:
|
||||
- Offline mode
|
||||
- AniList
|
||||
- UI / Web Interface
|
||||
- Desktop app
|
||||
- Denshi (Desktop app)
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
|
||||
2
.github/scripts/generate_updater_latest.go
vendored
2
.github/scripts/generate_updater_latest.go
vendored
@@ -9,7 +9,7 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
DownloadUrl = "https://github.com/1sailor/sea/releases/latest/download/"
|
||||
DownloadUrl = "https://github.com/5rahim/seanime/releases/latest/download/"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
||||
26
.github/workflows/electron-build.yml
vendored
26
.github/workflows/electron-build.yml
vendored
@@ -2,9 +2,9 @@ name: Build Electron App
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
secrets:
|
||||
SUBMODULE_PAT:
|
||||
required: true
|
||||
# secrets:
|
||||
# SUBMODULE_PAT:
|
||||
# required: true
|
||||
outputs:
|
||||
appVersion:
|
||||
description: "The version of the app"
|
||||
@@ -46,9 +46,9 @@ jobs:
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: recursive
|
||||
lfs: true
|
||||
token: ${{ secrets.SUBMODULE_PAT }}
|
||||
# submodules: recursive
|
||||
# lfs: true
|
||||
# token: ${{ secrets.SUBMODULE_PAT }}
|
||||
|
||||
- name: Setup Node.js 📦
|
||||
uses: actions/setup-node@v4
|
||||
@@ -69,13 +69,13 @@ jobs:
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y libgtk-3-dev libnss3-dev libxss-dev libasound2-dev
|
||||
|
||||
# # Download the web folders
|
||||
# # TODO Uncomment if building web
|
||||
# - name: Download web folder artifact 📥
|
||||
# uses: actions/download-artifact@v4
|
||||
# with:
|
||||
# name: web-denshi
|
||||
# path: web-denshi
|
||||
# Download the web folders
|
||||
# TODO Uncomment if building web
|
||||
- name: Download web folder artifact 📥
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: web-denshi
|
||||
path: web-denshi
|
||||
|
||||
# Move web-denshi folder into seanime-denshi
|
||||
- name: Move web-denshi folder 🚚
|
||||
|
||||
102
.github/workflows/release-draft-new.yml
vendored
102
.github/workflows/release-draft-new.yml
vendored
@@ -11,49 +11,49 @@ permissions:
|
||||
|
||||
jobs:
|
||||
|
||||
# build-webapp: # TODO Uncomment if building web
|
||||
# runs-on: ubuntu-latest
|
||||
#
|
||||
# steps:
|
||||
# - name: Checkout code
|
||||
# uses: actions/checkout@v4
|
||||
# with:
|
||||
# fetch-depth: 0
|
||||
#
|
||||
# # Web
|
||||
# - name: Set up Node.js
|
||||
# uses: actions/setup-node@v4
|
||||
# with:
|
||||
# node-version: '20'
|
||||
#
|
||||
# # outputs in "seanime-web/out/" and "seanime-web/out-desktop/"
|
||||
# - name: Install dependencies and build Next.js app
|
||||
# run: |
|
||||
# cd seanime-web/
|
||||
# npm install
|
||||
# npm run build
|
||||
# npm run build:desktop
|
||||
# npm run build:denshi
|
||||
# cd ..
|
||||
# # Upload the output to be used in the next job
|
||||
# - name: Upload web folder
|
||||
# uses: actions/upload-artifact@v4
|
||||
# with:
|
||||
# name: web
|
||||
# path: seanime-web/out # output dir of build
|
||||
# - name: Upload web folder (Electron)
|
||||
# uses: actions/upload-artifact@v4
|
||||
# with:
|
||||
# name: web-desktop
|
||||
# path: seanime-web/out-desktop # output dir of build:desktop
|
||||
# - name: Upload web folder (Electron)
|
||||
# uses: actions/upload-artifact@v4
|
||||
# with:
|
||||
# name: web-denshi
|
||||
# path: seanime-web/out-denshi # output dir of build:denshi
|
||||
build-webapp: # TODO Uncomment if building web
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
# Web
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '20'
|
||||
|
||||
# outputs in "seanime-web/out/" and "seanime-web/out-desktop/"
|
||||
- name: Install dependencies and build Next.js app
|
||||
run: |
|
||||
cd seanime-web/
|
||||
npm install
|
||||
npm run build
|
||||
npm run build:desktop
|
||||
npm run build:denshi
|
||||
cd ..
|
||||
# Upload the output to be used in the next job
|
||||
- name: Upload web folder
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: web
|
||||
path: seanime-web/out # output dir of build
|
||||
- name: Upload web folder (Electron)
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: web-desktop
|
||||
path: seanime-web/out-desktop # output dir of build:desktop
|
||||
- name: Upload web folder (Electron)
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: web-denshi
|
||||
path: seanime-web/out-denshi # output dir of build:denshi
|
||||
|
||||
build-server:
|
||||
# needs: build-webapp # TODO Uncomment if building web
|
||||
needs: build-webapp # TODO Uncomment if building web
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
||||
strategy:
|
||||
@@ -108,13 +108,13 @@ jobs:
|
||||
restore-keys: |
|
||||
${{ runner.os }}-go-
|
||||
|
||||
# # Download the web folders
|
||||
# # TODO Uncomment if building web
|
||||
# - name: Download web folder artifact
|
||||
# uses: actions/download-artifact@v4
|
||||
# with:
|
||||
# name: web
|
||||
# path: web
|
||||
# Download the web folders
|
||||
# TODO Uncomment if building web
|
||||
- name: Download web folder artifact
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: web
|
||||
path: web
|
||||
|
||||
# Create the binary destination folder
|
||||
# ./binaries
|
||||
@@ -220,8 +220,8 @@ jobs:
|
||||
build-electron:
|
||||
needs: build-server
|
||||
uses: ./.github/workflows/electron-build.yml
|
||||
secrets:
|
||||
SUBMODULE_PAT: ${{ secrets.SUBMODULE_PAT }}
|
||||
# secrets:
|
||||
# SUBMODULE_PAT: ${{ secrets.SUBMODULE_PAT }}
|
||||
|
||||
release:
|
||||
runs-on: ubuntu-latest
|
||||
@@ -433,4 +433,4 @@ jobs:
|
||||
${{ env.RELEASE_BODY }}
|
||||
|
||||
---
|
||||
[Open an issue](https://github.com/1sailor/sea/issues/new/choose)
|
||||
[Open an issue](https://github.com/5rahim/seanime/issues/new/choose)
|
||||
|
||||
@@ -82,7 +82,7 @@ func (h *Handler) HandleGetChangelog(c echo.Context) error {
|
||||
return h.RespondWithData(c, cached)
|
||||
}
|
||||
|
||||
changelogBody, err := http.Get("https://raw.githubusercontent.com/1sailor/sea/main/CHANGELOG.md")
|
||||
changelogBody, err := http.Get("https://raw.githubusercontent.com/5rahim/seanime/main/CHANGELOG.md")
|
||||
if err != nil {
|
||||
return h.RespondWithData(c, []*changelogItem{})
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ import (
|
||||
// This allows updates even if Seanime is removed from GitHub
|
||||
var (
|
||||
websiteUrl = "https://seanime.app/api/release"
|
||||
fallbackGithubUrl = "https://api.github.com/repos/1sailor/sea/releases/latest"
|
||||
fallbackGithubUrl = "https://api.github.com/repos/5rahim/seanime/releases/latest"
|
||||
)
|
||||
|
||||
type (
|
||||
@@ -110,25 +110,16 @@ func (u *Updater) GetReleaseName(version string) string {
|
||||
|
||||
func (u *Updater) fetchLatestRelease() (*Release, error) {
|
||||
var release *Release
|
||||
//docsRelease, err := u.fetchLatestReleaseFromDocs()
|
||||
//if err != nil {
|
||||
// ghRelease, err := u.fetchLatestReleaseFromGitHub()
|
||||
// if err != nil {
|
||||
// return nil, err
|
||||
// }
|
||||
// release = ghRelease
|
||||
//} else {
|
||||
// release = docsRelease
|
||||
//}
|
||||
ghRelease, err := u.fetchLatestReleaseFromGitHub()
|
||||
|
||||
docsRelease, err := u.fetchLatestReleaseFromDocs()
|
||||
if err != nil {
|
||||
docsRelease, err := u.fetchLatestReleaseFromDocs()
|
||||
ghRelease, err := u.fetchLatestReleaseFromGitHub()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
release = docsRelease
|
||||
} else {
|
||||
release = ghRelease
|
||||
} else {
|
||||
release = docsRelease
|
||||
}
|
||||
|
||||
return release, nil
|
||||
|
||||
@@ -22,7 +22,7 @@ func TestUpdater_getReleaseName(t *testing.T) {
|
||||
func TestUpdater_FetchLatestRelease(t *testing.T) {
|
||||
|
||||
fallbackGithubUrl = "https://seanimedud.app/api/releases" // simulate dead endpoint
|
||||
//githubUrl = "https://api.github.com/repos/1sailor/sea-desktop/releases/latest"
|
||||
//githubUrl = "https://api.github.com/repos/5rahim/seanime-desktop/releases/latest"
|
||||
|
||||
updater := New(constants.Version, util.NewLogger(), events.NewMockWSEventManager(util.NewLogger()))
|
||||
release, err := updater.fetchLatestRelease()
|
||||
|
||||
@@ -24,7 +24,10 @@
|
||||
"electron-builder": "^24.13.3"
|
||||
},
|
||||
"build": {
|
||||
"electronDist": "../electron",
|
||||
"electronDownload": {
|
||||
"mirror": "https://seanime.app/assets/electron/",
|
||||
"customDir": "v36.2.1"
|
||||
},
|
||||
"appId": "app.seanime.denshi",
|
||||
"productName": "Seanime Denshi",
|
||||
"asar": true,
|
||||
@@ -37,7 +40,7 @@
|
||||
"generateUpdatesFilesForAllChannels": true,
|
||||
"publish": {
|
||||
"provider": "generic",
|
||||
"url": "https://github.com/1sailor/sea/releases/latest/download",
|
||||
"url": "https://github.com/5rahim/seanime/releases/latest/download",
|
||||
"channel": "latest",
|
||||
"publishAutoUpdate": true,
|
||||
"useMultipleRangeRequest": false
|
||||
|
||||
@@ -209,7 +209,7 @@ function logEnvironmentInfo() {
|
||||
|
||||
const updateConfig = {
|
||||
provider: 'generic',
|
||||
url: 'https://github.com/1sailor/sea/releases/latest/download',
|
||||
url: 'https://github.com/5rahim/seanime/releases/latest/download',
|
||||
channel: 'latest',
|
||||
allowPrerelease: false,
|
||||
verifyUpdateCodeSignature: false,
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
"updater": {
|
||||
"pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDg4Q0RFQTc5NTQyRDU4RDYKUldUV1dDMVVlZXJOaU8xMlBhbU1xNG1IY2lLVG1oMXBnWm81VTNKem11N3EzcWk4NHI0SXhtbGkK",
|
||||
"endpoints": [
|
||||
"https://github.com/1sailor/sea/releases/latest/download/latest.json"
|
||||
"https://github.com/5rahim/seanime/releases/latest/download/latest.json"
|
||||
]
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user