Creates an exclusion list to only download the NGS version for PSO2 Global.
You can't use this on a mainline version of Legendary just yet, pull request is still pending
| #!/usr/bin/env -S bash | |
| ## credits to https://paste.sh/1QS8Tgf6#aHTfRy1dOG4rcA5x_6kauwq3 | |
| #pkg=current/xbps-0.59.1_6.x86_64.xbps | |
| pkg=current/dolphin-22.08.2_1.x86_64.xbps | |
| otime=current/otime | |
| file="${XDG_CACHE_HOME:-$HOME/.cache}/${0##*/}-results" | |
| mirrormsg() { printf '%s\n' "getting mirrors from void-docs..." ; } |
| // This attendance counting function assumes the following: | |
| // - You can attend multiple times in one day (and still be counted as one) | |
| // - Attendance time is not counted, you can attend for several minutes and it still counts as one day | |
| /** @typedef {string | number | Date} DateLike */ | |
| /** | |
| * @param {Array<{ start: DateLike, end: DateLike }>} attendances | |
| * @param {Date} startDate | |
| * @param {Date} endDate |
| /** | |
| * @typedef {object} Reader | |
| * @property {(p: Uint8Array) => Promise<number | null>} read | |
| */ | |
| /** | |
| * @typedef {object} Seeker | |
| * @property {(offset: number) => Promise<number>} seek | |
| */ |
| /** | |
| * Create an async iterable for a readable stream | |
| * @template T | |
| * @param {ReadableStream<T>} stream | |
| * @returns {AsyncIterableIterator<T>} | |
| */ | |
| function createStreamIterator (stream) { | |
| // return if browser already supports async iterator in stream | |
| if (stream[Symbol.asyncIterator]) { | |
| return stream; |
| function assert (condition, message = 'Assertion failed') { | |
| if (!condition) { | |
| throw new Error(message); | |
| } | |
| } | |
| export class ByteReader { | |
| /** | |
| * @param {ArrayBuffer} buffer | |
| * @param {number} [offset] |
| import { style } from '@vanilla-extract/css'; | |
| const NEW_RULE = /(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g; | |
| const RULE_CLEAN = /\/\*[^]*?\*\/| +/g; | |
| const RULE_NEWLINE = /\n+/g; | |
| const EMPTY = ' '; | |
| /** | |
| * @param {string} val | |
| * @returns {object} |
| import { stableStringify } from '@intrnl/stable-stringify'; | |
| const defaultKey = () => {}; | |
| const defaultId = (x) => x.id; | |
| export const createBatchedFetch = (options) => { | |
| const { | |
| fetch, | |
| limit = 100, |
| let map; | |
| function generateUUID () { | |
| const buf = crypto.getRandomValues(new Uint8Array(16)); | |
| buf[6] = (buf[6] & 0x0f) | 0x40; | |
| buf[8] = (buf[8] & 0x3f) | 0x80; | |
| if (!map) { | |
| map = []; |
| import http from 'node:http'; | |
| export function createRunner (middlewares) { | |
| /** | |
| * @param {http.IncomingMessage} request | |
| * @param {http.ServerResponse} response | |
| * @param {(error?: any) => void} done | |
| */ | |
| return function runner (request, response, done = createFinalHandler(request, response)) { | |
| let idx = 0; |
Creates an exclusion list to only download the NGS version for PSO2 Global.
You can't use this on a mainline version of Legendary just yet, pull request is still pending