This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Xcode 2019 | |
# remove old simulators in Xcode 9 or Xcode 10 | |
xcrun simctl delete unavailable | |
# solve issue with `xcrun: error: unable to find utility "name", not a developer tool or in PATH` | |
sudo xcode-select --reset | |
## Xcode 2011 | |
defaults write com.apple.Xcode PBXBeepOnNoMatchingBrace YES | |
defaults write com.apple.Xcode NSRecentDocumentsLimit 12 | |
defaults write com.apple.Xcode PBXCustomTemplateMacroDefinitions '{FULLUSERNAME="Firstname Last";ORGANIZATIONNAME="Orgname";}' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// javascript:if(!location.href.match(%2Fetswsso.web.(.*%3F).com.etsp.ets%2F))void(location.href%3D'https%3A%2F%2Fetswsso.web.PLACEHOLDER.com%2Fetsp%2Fetslg9pm')%3Bvar%20d%3Ddocument.getElementsByName('contents')%5B0%5D.contentDocument,h%3Dd.getElementsByName('hours001')%5B0%5D,t%3Dd.getElementsByName('ccnsel001')%5B0%5D,e%3Dd.createEvent('HTMLEvents')%3Bh.value%3D8%3Bt.selectedIndex%3D2%3Be.initEvent('change',false,true)%3Bt.dispatchEvent(e)%3Bvoid(d.getElementsByName('lmform')%5B0%5D.submit()) | |
//verify on correct page | |
if (!location.href.match(/etswsso.web.(.*?).com.etsp.ets/)) void (location.href = 'DESIRED_URL'); | |
// enter 8 hours for activity #2 on ETS | |
// setup vars for DOM elements and event | |
var d = document.getElementsByName('contents')[0].contentDocument, | |
h = d.getElementsByName('hours001')[0], | |
t = d.getElementsByName('ccnsel001')[0], | |
e = d.createEvent('HTMLEvents'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
javascript:{document.documentElement.innerHTML%20='<head><title>View%20Source<\/title><\/head>\n'+'<body><p>Source%20of%20<a%20href=\''+location.href+'\'>'+location.href+'<\/a><\/p>\n'+'<pre>\n<'+document.documentElement.nodeName+'>\n'+(document.documentElement.innerHTML).replace(/\&/g,%20'&').replace(/</g,%20'<').replace(/>/g,%20'>')+'\n</'+document.documentElement.nodeName+'>\n<\/pre><\/body>\n';} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
defaults write com.parallels.Parallels\ Desktop ProductPromo.ForcePromoOff -bool YES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
npm config set proxy http://proxy_host:port |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Java VM sym link | |
sudo ln -s /Library/Java/JavaVirtualMachines /System/Library/Java/JavaVirtualMachines | |
# Java browser plugin | |
sudo rm -f /Library/Internet Plug-Ins/JavaAppletPlugin.plugin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# delete local tag '12345' | |
git tag -d 12345 | |
# delete remote tag '12345' (eg, GitHub version too) | |
git push origin :refs/tags/12345 | |
# alternative approach | |
git push --delete origin tagName | |
git tag -d tagName |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# depends on exiftool | |
for TKJF in photo\(?\).jpg | |
do touch -t "$(exiftool -DateTimeOriginal -S "$TKJF" | awk '{gsub(":","",$0); print $2 substr($3, 1, 4) "." substr($3, 5, 6) }')" "$TKJF" | |
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for PHOFILE in Photo*.jpg ; do exiftool -Orientation='' "$PHOFILE" ; done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# strip audio from a video and save as m4a | |
ffmpeg -i input.mp4 -vn -c:a copy output.m4a | |
# replace audio track with audio track in identical (m4a) format | |
ffmpeg.exe -i input_video.mp4 -i replacement_audio.m4a -vcodec copy -acodec copy -map 0:0 -map 1:0 output.mp4 | |
# replace audio, matching file's audio codec (encodes only audio) | |
ffmpeg.exe -i input_video.mp4 -i replacement_audio.m4a -vcodec copy -map 0:0 -map 1:0 output.mp4 | |
OlderNewer