mirror of
https://git.suyu.dev/suyu/suyu
synced 2025-12-05 20:32:07 -06:00
try three of importing hidden files from legacy
On branch master Your branch is up to date with 'origin/master'. Changes to be committed: new file: .ci/.DS_Store new file: .ci/scripts/android/build.sh new file: .ci/scripts/android/eabuild.sh new file: .ci/scripts/android/mainlinebuild.sh new file: .ci/scripts/android/upload.sh new file: .ci/scripts/clang/docker.sh new file: .ci/scripts/clang/exec.sh new file: .ci/scripts/clang/upload.sh new file: .ci/scripts/common/post-upload.sh new file: .ci/scripts/common/pre-upload.sh new file: .ci/scripts/format/docker.sh new file: .ci/scripts/format/exec.sh new file: .ci/scripts/format/script.sh new file: .ci/scripts/linux/docker.sh new file: .ci/scripts/linux/exec.sh new file: .ci/scripts/linux/upload.sh new file: .ci/scripts/merge/apply-patches-by-label-private.py new file: .ci/scripts/merge/apply-patches-by-label.py new file: .ci/scripts/merge/check-label-presence.py new file: .ci/scripts/merge/yuzubot-git-config.sh new file: .ci/scripts/transifex/docker.sh new file: .ci/scripts/windows/docker.sh new file: .ci/scripts/windows/exec.sh new file: .ci/scripts/windows/install-vulkan-sdk.ps1 new file: .ci/scripts/windows/scan_dll.py new file: .ci/scripts/windows/upload.ps1 new file: .ci/scripts/windows/upload.sh new file: .ci/templates/build-mock.yml new file: .ci/templates/build-msvc.yml new file: .ci/templates/build-single.yml new file: .ci/templates/build-standard.yml new file: .ci/templates/build-testing.yml new file: .ci/templates/format-check.yml new file: .ci/templates/merge-private.yml new file: .ci/templates/merge.yml new file: .ci/templates/mergebot-private.yml new file: .ci/templates/mergebot.yml new file: .ci/templates/release-download.yml new file: .ci/templates/release-github.yml new file: .ci/templates/release-private-tag.yml new file: .ci/templates/release-universal.yml new file: .ci/templates/retrieve-artifact-source.yml new file: .ci/templates/retrieve-master-source.yml new file: .ci/templates/sync-source.yml new file: .ci/yuzu-mainline-step1.yml new file: .ci/yuzu-mainline-step2.yml new file: .ci/yuzu-patreon-step1.yml new file: .ci/yuzu-patreon-step2.yml new file: .ci/yuzu-repo-sync.yml new file: .ci/yuzu-verify.yml new file: .codespellrc new file: .git-blame-ignore-revs new file: .gitattributes new file: .gitignore new file: .gitmodules new file: .reuse/dep5
This commit is contained in:
48
.ci/scripts/merge/apply-patches-by-label-private.py
Normal file
48
.ci/scripts/merge/apply-patches-by-label-private.py
Normal file
@@ -0,0 +1,48 @@
|
||||
# SPDX-FileCopyrightText: 2019 yuzu Emulator Project
|
||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
# Download all pull requests as patches that match a specific label
|
||||
# Usage: python download-patches-by-label.py <Label to Match> <Root Path Folder to DL to>
|
||||
|
||||
import requests, sys, json, shutil, subprocess, os, traceback
|
||||
|
||||
org = os.getenv("PRIVATEMERGEORG", "yuzu-emu")
|
||||
repo = os.getenv("PRIVATEMERGEREPO", "yuzu-private")
|
||||
tagline = sys.argv[3]
|
||||
user = sys.argv[1]
|
||||
|
||||
dl_list = {}
|
||||
|
||||
TAG_NAME = sys.argv[2]
|
||||
|
||||
def check_individual(repo_id, pr_id):
|
||||
url = 'https://%sdev.azure.com/%s/%s/_apis/git/repositories/%s/pullRequests/%s/labels?api-version=5.1-preview.1' % (user, org, repo, repo_id, pr_id)
|
||||
response = requests.get(url)
|
||||
if (response.ok):
|
||||
try:
|
||||
js = response.json()
|
||||
return any(tag.get('name') == TAG_NAME for tag in js['value'])
|
||||
except:
|
||||
return False
|
||||
return False
|
||||
|
||||
def merge_pr(pn, ref):
|
||||
print("Matched PR# %s" % pn)
|
||||
print(subprocess.check_output(["git", "fetch", "https://%sdev.azure.com/%s/_git/%s" % (user, org, repo), ref, "-f", "--no-recurse-submodules"]))
|
||||
print(subprocess.check_output(["git", "merge", "--squash", 'origin/' + ref.replace('refs/heads/','')]))
|
||||
print(subprocess.check_output(["git", "commit", "-m\"Merge %s PR %s\"" % (tagline, pn)]))
|
||||
|
||||
def main():
|
||||
url = 'https://%sdev.azure.com/%s/%s/_apis/git/pullrequests?api-version=5.1' % (user, org, repo)
|
||||
response = requests.get(url)
|
||||
if (response.ok):
|
||||
js = response.json()
|
||||
tagged_prs = filter(lambda pr: check_individual(pr['repository']['id'], pr['pullRequestId']), js['value'])
|
||||
map(lambda pr: merge_pr(pr['pullRequestId'], pr['sourceRefName']), tagged_prs)
|
||||
|
||||
if __name__ == '__main__':
|
||||
try:
|
||||
main()
|
||||
except:
|
||||
traceback.print_exc(file=sys.stdout)
|
||||
sys.exit(-1)
|
||||
38
.ci/scripts/merge/apply-patches-by-label.py
Normal file
38
.ci/scripts/merge/apply-patches-by-label.py
Normal file
@@ -0,0 +1,38 @@
|
||||
# SPDX-FileCopyrightText: 2019 yuzu Emulator Project
|
||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
# Download all pull requests as patches that match a specific label
|
||||
# Usage: python apply-patches-by-label.py <Label to Match>
|
||||
|
||||
import json, requests, subprocess, sys, traceback
|
||||
|
||||
tagline = sys.argv[2]
|
||||
|
||||
def check_individual(labels):
|
||||
for label in labels:
|
||||
if (label["name"] == sys.argv[1]):
|
||||
return True
|
||||
return False
|
||||
|
||||
def do_page(page):
|
||||
url = f"https://api.github.com/repos/yuzu-emu/yuzu/pulls?page={page}"
|
||||
response = requests.get(url)
|
||||
response.raise_for_status()
|
||||
if (response.ok):
|
||||
j = json.loads(response.content)
|
||||
if j == []:
|
||||
return
|
||||
for pr in j:
|
||||
if (check_individual(pr["labels"])):
|
||||
pn = pr["number"]
|
||||
print(f"Matched PR# {pn}")
|
||||
print(subprocess.check_output(["git", "fetch", "https://github.com/yuzu-emu/yuzu.git", f"pull/{pn}/head:pr-{pn}", "-f", "--no-recurse-submodules"]))
|
||||
print(subprocess.check_output(["git", "merge", "--squash", f"pr-{pn}"]))
|
||||
print(subprocess.check_output(["git", "commit", f"-m\"Merge {tagline} PR {pn}\""]))
|
||||
|
||||
try:
|
||||
for i in range(1,10):
|
||||
do_page(i)
|
||||
except:
|
||||
traceback.print_exc(file=sys.stdout)
|
||||
sys.exit(-1)
|
||||
21
.ci/scripts/merge/check-label-presence.py
Normal file
21
.ci/scripts/merge/check-label-presence.py
Normal file
@@ -0,0 +1,21 @@
|
||||
# SPDX-FileCopyrightText: 2019 yuzu Emulator Project
|
||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
# Checks to see if the specified pull request # has the specified tag
|
||||
# Usage: python check-label-presence.py <Pull Request ID> <Name of Label>
|
||||
|
||||
import requests, json, sys
|
||||
|
||||
try:
|
||||
url = 'https://api.github.com/repos/yuzu-emu/yuzu/issues/%s' % sys.argv[1]
|
||||
response = requests.get(url)
|
||||
if (response.ok):
|
||||
j = json.loads(response.content)
|
||||
for label in j["labels"]:
|
||||
if label["name"] == sys.argv[2]:
|
||||
print('##vso[task.setvariable variable=enabletesting;]true')
|
||||
sys.exit()
|
||||
except:
|
||||
sys.exit(-1)
|
||||
|
||||
print('##vso[task.setvariable variable=enabletesting;]false')
|
||||
5
.ci/scripts/merge/yuzubot-git-config.sh
Normal file
5
.ci/scripts/merge/yuzubot-git-config.sh
Normal file
@@ -0,0 +1,5 @@
|
||||
# SPDX-FileCopyrightText: 2019 yuzu Emulator Project
|
||||
# SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
git config --global user.email "yuzu@yuzu-emu.org"
|
||||
git config --global user.name "yuzubot"
|
||||
Reference in New Issue
Block a user