Skip to content

Instantly share code, notes, and snippets.

Avatar
🐝
Busy bee, improving my code every day.

Kryštof Woldřich krystofwoldrich

🐝
Busy bee, improving my code every day.
View GitHub Profile
View background.js
chrome.webRequest.onHeadersReceived.addListener(
function (details) {
for (var i = 0; i < details.responseHeaders.length; ++i) {
if (details.responseHeaders[i].name.toLowerCase() == 'x-frame-options') {
details.responseHeaders.splice(i, 1);
return {
responseHeaders: details.responseHeaders
};
}
}
View get-xcode-version.sh
#!/usr/bin/env bash
set -euo pipefail
# Matches the version number from the output of xcodebuild -version
# Example: 13.4.1
xcodeBin=/usr/bin/xcodebuild
xcodeVersionOutput=$($xcodeBin -version)
xcodeVersion=$(echo "$xcodeVersionOutput" | perl -pe '($_)=/([0-9]+([.][0-9]+)+)/')