Skip to content

Instantly share code, notes, and snippets.

@lingyfh
lingyfh / UnpackUnityAssets.py
Created February 21, 2024 06:27 — forked from jesliwang/UnpackUnityAssets.py
Unpack Assets For Unity Games From Apks or assetbundles
#!/Users/Jesli/opt/anaconda3/bin/python
# -*- coding: UTF-8 -*-
import io, os
import UnityPy
import sys, getopt
import traceback
import json
class UnPackUnityAsset:
import java.io.IOException;
import okhttp3.Interceptor;
import okhttp3.MediaType;
import okhttp3.Request;
import okhttp3.RequestBody;
import okhttp3.Response;
import okio.Buffer;
@lingyfh
lingyfh / manifest.mf.py
Last active January 20, 2020 04:01
对比apk中manifest.mf中Hash值存在,与文件是否存的脚本。(Hash value exists, but file does not exist. - META-INF)
# -*- coding:utf-8 -*-
import zipfile
import hashlib
import base64
from optparse import OptionParser
def log(msg):
print "****************************************"
@lingyfh
lingyfh / loading.xml
Created September 11, 2018 09:55
loading drawbale
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item android:drawable="@drawable/progress_img_small"/>
<item>
<rotate
android:fromDegrees="0"
android:interpolator="@android:anim/linear_interpolator"
android:pivotX="50%"
android:pivotY="50%"
android:toDegrees="359" >
@lingyfh
lingyfh / notify.py
Created June 23, 2018 11:43
python show mac notification
# -*- coding:utf-8 -*-
from Foundation import NSUserNotification
from Foundation import NSUserNotificationCenter
from Cocoa import NSImage
if __name__ == '__main__':
notification = NSUserNotification.alloc().init()
notification.setTitle_("title")
@lingyfh
lingyfh / notify.py
Created June 23, 2018 11:18 — forked from lukaszb/notify.py
Simple Python script to send notification to the OSX Notifications Center (requires OS X 10.8+). Tested with pyobjc 2.5.1
#!/usr/bin/env python
from Foundation import NSUserNotification
from Foundation import NSUserNotificationCenter
from Foundation import NSUserNotificationDefaultSoundName
from optparse import OptionParser
def main():
parser = OptionParser(usage='%prog -t TITLE -m MESSAGE')
@lingyfh
lingyfh / multi_file_to_one.sh
Created December 4, 2017 12:18
当前文件夹下的,指定文件类型内容写入一个文件中
find . -name "*.h" -o -name "*.m" | xargs -n 1 cat > test.log
@lingyfh
lingyfh / cat_all_file_to_one_file.sh
Created December 4, 2017 11:44
将多个文件写入到一个文件中
ls *.sh | xargs -n 1 cat > tempppp.txt
@lingyfh
lingyfh / find_id_all_db.py
Created November 2, 2017 07:19
在所有的dbs中查询id
import pymongo
import sys
from bson.objectid import ObjectId
import datetime
if __name__ == '__main__':
if len(sys.argv) < 2:
print "please input object id"
exit()
@lingyfh
lingyfh / update_root_password.txt
Created August 18, 2017 02:47
修改linux root密码
sudo passwd root