Skip to content

Instantly share code, notes, and snippets.

View xymopen's full-sized avatar

xymopen_Official xymopen

  • Shanghai, China
View GitHub Profile
@echo off
setlocal EnableExtensions
setlocal EnableDelayedExpansion
set STUDENT_MAIN_PATH="C:\Program Files\Mythware\e-Learning Class\StudentMain.exe"
set LOCAL_INTERFACE="本地连接"
set FIREWALL_RULE_NAME_1="Block Mythware e-Learning class(UDP 4605)"
set FIREWALL_RULE_NAME_2="Block Mythware e-Learning class(StudentMain.exe)"
@xymopen
xymopen / fernflower.ps1
Last active February 16, 2025 15:10
IntelliJ IDEA Java decompiler wrapper script for PowerShell
############################################################################
#
# IntelliJ IDEA Java Decompiler wrapper script for Windows
#
# @see https://stackoverflow.com/questions/28389006/how-to-decompile-to-java-files-intellij-idea/30106981
# @see https://github.com/JetBrains/intellij-community/tree/master/plugins/java-decompiler/engine
#
############################################################################
$IDEA_PATH = "$Env:ProgramFiles\JetBrains\IntelliJ IDEA 2020.1.1"
@xymopen
xymopen / open-terminals.md
Last active May 15, 2024 10:43 — forked from auroursa/open-windows-terminal-in-current-folder.md
Open Windows Terminal and Fluent Terminal in current folder

Open Windows Terminal and Fluent Terminal in current folder

Using Registry to add "Terminal Here" in the context menu.

Icon value is optional, path may change with different version.

notice change [your username] to the correct username.

Use cmd.exe to resolve executable from %PATH%. Require that %UserProfile%\AppData\Local\Microsoft\WindowsApps is presented at %PATH% of system environment variable (which is default).

@xymopen
xymopen / git-mingw.cmd
Last active December 16, 2020 14:19
Start a cmd with MinGW come with Git for Windows
@echo off
setlocal
for /f "delims=" %%i in ('where git') do (
set "GIT_PATH=%%~dpi"
goto _end_of_where
)
:_end_of_where
@xymopen
xymopen / openid-configuration.json
Created October 13, 2023 16:29
GitHub OAuth App OIDC Configuration
{
"issuer": "https://github.com",
"authorization_endpoint": "https://github.com/login/oauth/authorize",
"token_endpoint": "https://github.com/login/oauth/access_token",
"userinfo_endpoint": "https://api.github.com/user",
"scopes_supported": [
"repo",
"repo:status",
"repo_deployment",
"public_repo",
@xymopen
xymopen / node-pwsh-completion.mjs
Last active July 27, 2024 08:22
print source-able pwsh completion script for Node.js
import { execFile as childProcessExecFile } from "node:child_process"
import { execPath, stdout } from "node:process"
import { promisify } from "node:util"
const execFile = promisify(childProcessExecFile)
const pwshCompletionTemplatePrefix =
`using namespace System.Management.Automation
using namespace System.Management.Automation.Language
@xymopen
xymopen / dismount.sh
Last active October 14, 2024 06:27
Shell implemented mounting app of ReVanced Manager
#!/data/adb/magisk/busybox ash
# shellcheck shell=ash
# @see https://github.com/ReVanced/revanced-manager/blob/main/lib/services/root_api.dart
REVANCED_PATH="/data/adb/revanced"
SERVICE_D_PATH="/data/adb/service.d"
main () {
local packageName="$1"