This file contains hidden or 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
| <# 1. To patch dll in a protected folder like "c:\program files" run this script as Administrator. | |
| 2. If your Windows isn't configured to run ps1 files, you can run it from command prompt like this: | |
| powershell -ep bypass -noprofile "patch-chrome-mv2.ps1" | |
| #> | |
| param([string]$dll, [string]$dir = $pwd) | |
| function doPatch([string]$path, [string]$pathLabel = '') { | |
| $dll = $script:dll = if ($path.EndsWith('\')) { Join-Path $path chrome.dll } else { $path } | |
| if (!(Test-Path -literal $dll)) { return } | |
| $localAppData = [Environment]::GetFolderPath('LocalApplicationData') |
This file contains hidden or 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
| from contextlib import asynccontextmanager | |
| from datetime import datetime | |
| from fastapi import FastAPI, Request | |
| import fastapi | |
| from fastapi.datastructures import State | |
| from fastapi.responses import JSONResponse | |
| import redis.asyncio as redis | |
| class Redis: | |
| redis_client: redis.Redis = None |
This file contains hidden or 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
| package xyz.nulldev.csg | |
| import okhttp3.OkHttpClient | |
| import okhttp3.Request | |
| import org.jetbrains.ktor.http.HttpStatusCode | |
| import org.jetbrains.ktor.netty.embeddedNettyServer | |
| import org.jetbrains.ktor.response.respondRedirect | |
| import org.jetbrains.ktor.response.respondText | |
| import org.jetbrains.ktor.routing.get | |
| import org.jetbrains.ktor.routing.routing |
This file contains hidden or 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
| #! /bin/sh | |
| # update glibc to 2.17 for CentOS 6 | |
| wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-2.17-55.el6.x86_64.rpm | |
| wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-common-2.17-55.el6.x86_64.rpm | |
| wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-devel-2.17-55.el6.x86_64.rpm | |
| wget http://copr-be.cloud.fedoraproject.org/results/mosquito/myrepo-el6/epel-6-x86_64/glibc-2.17-55.fc20/glibc-headers-2.17-55.el6.x86_64.rpm | |
| sudo rpm -Uvh glibc-2.17-55.el6.x86_64.rpm \ |
This file contains hidden or 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
| #Download dwebp (WebP decoder tool) https://developers.google.com/speed/webp/download | |
| #Run | |
| for %f in (*.webp) do dwebp.exe "%f" -o "%~nf.png" |
