-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit d1cf4a7
Showing
24 changed files
with
767 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Auto detect text files and perform LF normalization | ||
* text=auto | ||
*.lockb binary diff=lockb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: Deploy to Pages | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- master | ||
paths: | ||
- 'src/**' | ||
- 'public/**' | ||
- 'index.html' | ||
- 'package.json' | ||
- 'vite.config.ts' | ||
- '.github/workflows/pages-deploy.yml' | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Setup Bun | ||
uses: oven-sh/setup-bun@v2 | ||
- name: Install Dependencies | ||
run: bun i | ||
- name: Build | ||
run: bun build-only | ||
- name: Upload artifact | ||
uses: actions/upload-pages-artifact@v1 | ||
with: | ||
path: './dist' | ||
deploy: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
concurrency: | ||
group: 'pages' | ||
cancel-in-progress: true | ||
permissions: | ||
pages: write | ||
id-token: write | ||
environment: | ||
name: github-pages | ||
url: ${{ steps.deployment.outputs.page_url }} | ||
steps: | ||
- name: Deploy to GitHub Pages | ||
id: deployment | ||
uses: actions/deploy-pages@v1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
lerna-debug.log* | ||
|
||
node_modules | ||
.DS_Store | ||
dist | ||
dist-ssr | ||
coverage | ||
*.local | ||
|
||
/cypress/videos/ | ||
/cypress/screenshots/ | ||
|
||
# Editor directories and files | ||
.vscode/* | ||
!.vscode/extensions.json | ||
.idea | ||
*.suo | ||
*.ntvs* | ||
*.njsproj | ||
*.sln | ||
*.sw? | ||
|
||
*.tsbuildinfo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"printWidth": 140, | ||
"singleQuote": true, | ||
"trailingComma": "all", | ||
"arrowParens": "avoid", | ||
"useTabs": false, | ||
"tabWidth": 2, | ||
"semi": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"recommendations": ["Vue.volar"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
MIT License | ||
|
||
Copyright (c) 2024 神代綺凛 | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# MAA Resource Updater | ||
|
||
无需依赖任何第三方软件,纯靠浏览器工作的 [MAA 资源文件](https://github.com/arkntools/maa-resource-updater) 更新器 | ||
|
||
仅支持:Chrome ≥ 86, Edge ≥ 86, Opera ≥ 72 | ||
|
||
## 原理 | ||
|
||
[isomorphic-git](https://github.com/isomorphic-git/isomorphic-git) + [File System API](https://developer.mozilla.org/zh-CN/docs/Web/API/File_System_API) | ||
|
||
## 首次使用 Tips | ||
|
||
如果你本地的资源已经最新,那么可以直接点击“仅 clone / pull”,后续有更新时再用增量更新即可 |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/// <reference lib="webworker" /> | ||
/// <reference types="@types/wicg-file-system-access" /> | ||
/// <reference types="vite/client" /> | ||
/// <reference types="vite-plugin-comlink/client" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link rel="icon" href="/favicon.ico" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<title>MAA Resource Updater</title> | ||
</head> | ||
<body> | ||
<div id="app"></div> | ||
<script type="module" src="/src/main.ts"></script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
declare module '@isomorphic-git/cors-proxy/middleware' { | ||
export default function corsProxy(): any; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { createServer } from 'http'; | ||
import Express from 'express'; | ||
import gitCorsProxy from '@isomorphic-git/cors-proxy/middleware'; | ||
|
||
export const startProxy = () => { | ||
try { | ||
const app = Express(); | ||
app.use(gitCorsProxy()); | ||
app.on('error', console.error); | ||
const server = createServer(app); | ||
server.on('error', () => {}); | ||
server.listen(9999, () => { | ||
console.log('Git CORS proxy started'); | ||
}); | ||
} catch {} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
{ | ||
"name": "maa-resource-updater", | ||
"version": "0.0.0", | ||
"private": true, | ||
"type": "module", | ||
"scripts": { | ||
"dev": "vite", | ||
"build": "run-p type-check \"build-only {@}\" --", | ||
"preview": "vite preview", | ||
"build-only": "vite build", | ||
"type-check": "vue-tsc --build --force" | ||
}, | ||
"dependencies": { | ||
"@isomorphic-git/lightning-fs": "^4.6.0", | ||
"@vueuse/core": "^11.0.0", | ||
"buffer": "^6.0.3", | ||
"isomorphic-git": "^1.27.1", | ||
"sass": "^1.77.8", | ||
"vue": "^3.4.38" | ||
}, | ||
"devDependencies": { | ||
"@isomorphic-git/cors-proxy": "^2.7.1", | ||
"@tsconfig/node18": "^18.2.4", | ||
"@types/express": "^4.17.21", | ||
"@types/node": "^18.19.44", | ||
"@types/wicg-file-system-access": "^2023.10.5", | ||
"@vitejs/plugin-vue": "^5.1.2", | ||
"@vue/tsconfig": "^0.5.1", | ||
"express": "^4.19.2", | ||
"npm-run-all2": "^6.2.2", | ||
"typescript": "^5.5.4", | ||
"vite": "^5.4.1", | ||
"vite-plugin-comlink": "^5.0.1", | ||
"vue-tsc": "^2.0.29" | ||
} | ||
} |
Binary file not shown.
Oops, something went wrong.