Skip to content

Instantly share code, notes, and snippets.

View maxwellmlin's full-sized avatar

Maxwell Lin maxwellmlin

View GitHub Profile
@maxwellmlin
maxwellmlin / onetrust_id_mapping.js
Created July 27, 2023 20:22
OneTrust ID mapping
// Select all elements with an ID that starts with 'ot-header-id-'
onetrust_id_elements = document.querySelectorAll('*[id^="ot-header-id-"]');
success = true;
categories = {} // Map OneTrust ID to category name (e.g. 1: "Strictly Necessary Cookies")
onetrust_id_elements.forEach(function (element) {
let onetrust_id = element.id.split('ot-header-id-')[1]; // get the ID after the prefix
let category = element.innerText;
// Check for conflicts
~/Library/Group Containers/K36BKF7T3D.group.com.apple.configurator/Library/Caches/Assets/TemporaryItems/MobileApps
@maxwellmlin
maxwellmlin / LPX-Trial-Reset.sh
Created April 14, 2021 03:46
Logic Pro X Trial Reset
mv -v ~/Library/Application\ Support/.lpxuserdata ~/.Trash