cd $(getconf DARWIN_USER_DIR)/com.apple.dock.launchpad/db
sqlite3 --column --head dbdelete from apps where title='<CASE_SENSITIVE_APPNAME>';
delete from apps where title='EpicWebHelper';| import linecache; s=hou.pwd().parm("python").eval(); n=hou.pwd().path(); linecache.cache[n]=(len(s), None, s.splitlines(True), n) |
| def module_private(func): | |
| @functools.wraps(func) | |
| def wrapper(*function_args): | |
| myself_module = func.__code__.co_filename | |
| caller_module = sys._getframe(1).f_code.co_filename | |
| if myself_module != caller_module: | |
| raise Exception("Function %s cannot be called from external module %s" % (func.__name__, caller_module)) | |
| return func(*function_args) | |
| return wrapper |
| code --list-extensions | xargs -L 1 echo code --install-extension > ~/install_vscode_extensions.sh | |
| chmod +x ~/install_vscode_extensions.sh | |
| cd ~/Library/Application\ Support/Code/User | |
| tar -czf vscode_config.tar.gz *.json | |
| mv vscode_config.tar.gz ~/vscode_config.tar.gz |
| import os | |
| import re | |
| def sorted_alphanumeric(data): | |
| convert = lambda text: int(text) if text.isdigit() else text.lower() | |
| alphanum_key = lambda key: [ convert(c) for c in re.split('([0-9]+)', key) ] | |
| return sorted(data, key=alphanum_key) | |
| cwd = os.path.dirname(os.path.realpath(__file__)) | |
| os.chdir(cwd) |
| using System.Collections.Generic; | |
| using UnityEngine; | |
| using UnityEditor; | |
| using System.Linq; | |
| public class CreatePivotFromSelection | |
| { | |
| static void CreatePivot(Vector3 offset) | |
| { | |
| if (Selection.gameObjects == null || Selection.gameObjects.Length <= 0) |
| import json | |
| import os | |
| import plugin_api | |
| # | |
| def IsUsefulInput(viewtype): | |
| return viewtype == "CBV" or viewtype == "IBV" or viewtype == "VBV" or viewtype == "SRV" | |
| def DumpBufferByDrawcall(folder, call, res, id, texture): | |
| if not os.path.exists(folder): |
| using UnityEngine; | |
| [ExecuteInEditMode] | |
| public class DrawBones : MonoBehaviour | |
| { | |
| #if UNITY_EDITOR | |
| public bool ShowHierarchyAlwyas = true; | |
| public bool ShowSelectedBoneName = true; | |
| public Color BoneColor = Color.white; | |
| public Color SelectedBoneColor = Color.red; |
| using System; | |
| using System.Diagnostics; | |
| using System.IO; | |
| using System.Text.RegularExpressions; | |
| namespace P4 | |
| { | |
| class P4OutputStream : IDisposable | |
| { | |
| public StreamReader Reader { get; set; } |
| // https://en.wikipedia.org/wiki/Ordered_dithering | |
| half threshold4x4[16] = { | |
| 1.0 / 17.0, 9.0 / 17.0, 3.0 / 17.0, 11.0 / 17.0, | |
| 13.0 / 17.0, 5.0 / 17.0, 15.0 / 17.0, 7.0 / 17.0, | |
| 4.0 / 17.0, 12.0 / 17.0, 2.0 / 17.0, 10.0 / 17.0, | |
| 16.0 / 17.0, 8.0 / 17.0, 14.0 / 17.0, 6.0 / 17.0 | |
| }; | |
| half threshold8x8[64] = { | |
| 1.0 / 65.0, 49.0 / 65.0, 13.0 / 65.0, 61.0 / 65.0, 4.0 / 65.0, 52.0 / 65.0, 16.0 / 65.0, 64.0 / 65.0, |