Skip to content

Instantly share code, notes, and snippets.

View lwlsw's full-sized avatar
🤚

我是谁 lwlsw

🤚
View GitHub Profile
#!/bin/bash
# Script to build futurerestore for GNU/Linux
# tested on Debian 9 and Ubuntu 18.04.
# Install libimobiledevice before running this script
# (https://gist.github.com/matteyeux/d7d8041a41ee8d664aaf5c3b99556ada)
# install liblzfse
git clone https://github.com/lzfse/lzfse.git
make -C lzfse && sudo make -C lzfse install
#!/bin/bash
trap 'echo "Exiting..."' EXIT
echo "futurerestore compile script for Linux"
echo "Supported distros: Ubuntu 20.04, 20.10, 21.04, Fedora 33 to 34, Arch Linux"
echo
. /etc/os-release
export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:/usr/lib/x86_64-linux-gnu/pkgconfig:/usr/lib64/pkgconfig:/usr/lib/pkgconfig
if [[ $UBUNTU_CODENAME == "focal" ]] || [[ $UBUNTU_CODENAME == "groovy" ]] || [[ $UBUNTU_CODENAME == "hirsute" ]]; then
@lwlsw
lwlsw / extract-ipa.sh
Created April 10, 2021 14:36 — forked from oszo/extract-ipa.sh
IPA extract script
if [ ! -z "$1" -a "$1" != " " ]
then
EXTRACT_APP_PATH=$1
# echo $EXTRACT_APP_PATH
if [ -d "$EXTRACT_APP_PATH" ]
then
EXTRACT_APP_NAME="$(ls $1/ | grep .app)"
# echo $EXTRACT_APP_NAME
if [ ! -z "$EXTRACT_APP_NAME" -a "$EXTRACT_APP_NAME" != " " ]
then
@lwlsw
lwlsw / XXXRootListController.m
Created June 7, 2020 06:00 — forked from Galactic-Dev/XXXRootListController.m
Show a custom version of Apple's native OBWelcomeController when opening a preference bundle.
/*The file that you modify is the XXXRootListController.m file in your
preference bundle directory (XXX being the three characters that you chose for your preference bundle */
//I'm interfacing all the classes you'll need here. But don't forget to change $(BUNDLE_NAME)_PRIVATE_FRAMEWORKS = Preferences to $(BUNDLE_NAME)_PRIVATE_FRAMEWORKS = Preferences OnBoardingKit
#include "XXXRootListController.h"
@interface OBButtonTray : UIView
- (void)addButton:(id)arg1;
- (void)setStackViewTopConstraint:(NSLayoutConstraint *)arg1;
- (NSLayoutConstraint *)stackViewTopConstraint;
@lwlsw
lwlsw / generateIconImageWithInfo.m
Created February 23, 2020 10:25 — forked from CPDigitalDarkroom/generateIconImageWithInfo.m
Generate icon image on iOS 13
struct SBIconImageInfo {
struct CGSize size;
double scale;
double continuousCornerRadius;
};
- (UIImage *)iconImageForIdentifier:(NSString *)identifier {
SBIconController *iconController = [NSClassFromString(@"SBIconController") sharedInstance];
SBIcon *icon = [iconController.model expectedIconForDisplayIdentifier:identifier];
/*
* Tweak.xm
* VolumeLock
*
* Created by Zachary Thomas Paul <LacertosusThemes@gmail.com> on 9/16/2019.
* Copyright © 2019 LacertosusDeus <LacertosusThemes@gmail.com>. All rights reserved.
*/
#define LD_DEBUG NO
static BOOL toggleVolumeLock = NO;
@lwlsw
lwlsw / csdn_article.user.js
Last active February 4, 2020 09:01 — forked from Hunlongyu/csdn_article.user.js
『净网卫士』 CSDN文章
// ==UserScript==
// @author Hunlongyu, whoami
// @name 『净网卫士』 CSDN文章
// @namespace https://github.com/Hunlongyu
// @icon https://i.loli.net/2019/04/22/5cbd720718fdb.png
// @description 只针对 CSDN 的文章,进行极致简化。移除了所有无关文章内容的元素。同时增加了:展开文章、剪贴板净化、代码一键复制功能。
// @version 0.1.4
// @include *://*.csdn.net/*/article/details/*
// @grant GM_addStyle
// @grant GM_setClipboard