#!/bin/bash | |
osascript <<EOS | |
on toggle() | |
tell application "System Preferences" to reveal pane id "com.apple.preferences.sharing" | |
tell application "System Events" to tell window 1 of application process "System Preferences" | |
repeat until exists checkbox 1 of (first row of table 1 of scroll area 1 of group 1 whose value of static text 1 is "AirPlay Receiver") |
#!/usr/bin/env bash | |
# <bitbar.title>WiFi level</bitbar.title> | |
# <bitbar.version>v1.0</bitbar.version> | |
# <bitbar.author>Alex Sorokoletov</bitbar.author> | |
# <bitbar.author.github>alexsorokoletov</bitbar.author.github> | |
# <bitbar.desc>TX rate/Link speed of the connected WiFi</bitbar.desc> | |
# <bitbar.dependencies></bitbar.dependencies> | |
# <bitbar.abouturl>https://sorokoletov.com/</bitbar.abouturl> |
<?xml version="1.0" encoding="UTF-8"?> | |
<configuration> | |
<system.webServer> | |
<staticContent> | |
<mimeMap fileExtension="." mimeType="text/plain" /> | |
<mimeMap fileExtension=".nupkg" mimeType="application/octet-stream" /> | |
<mimeMap fileExtension=".exe" mimeType="application/octet-stream" /> | |
<mimeMap fileExtension=".zip" mimeType="application/x-zip-compressed" /> | |
</staticContent> | |
</system.webServer> |
upstream redash { | |
server redash:5000; | |
} | |
server { | |
listen 80; | |
location / { | |
return 301 https://$host$request_uri; | |
} |
#!/bin/bash | |
# based on http://stackoverflow.com/questions/755382/i-want-to-delete-all-bin-and-obj-folders-to-force-all-projects-to-rebuild-everyt | |
find . -iname "bin" -type d | xargs rm -rf | |
find . -iname "obj" -type d | xargs rm -rf | |
# clear VS4Mac temporary downloads | |
echo ~/Library/Caches/VisualStudio/7.0/TempDownload/ | |
for f in ~/Library/Caches/VisualStudio/7.0/TempDownload/* ; do | |
sudo rm -rf $f | |
done |
One of the best ways to investigate a problematic Xamarin.Android Binding is to first ensure you have the proper tooling available:
- Diagnostic MSBuild Output Enabled(Instructions)
- Java Decompiler(http://jd.benow.ca/)
- .NET Decompiler(https://www.jetbrains.com/decompiler/)
- Binding SDK Documentation
function logClass(target: any) { | |
// save a reference to the original constructor | |
var original = target; | |
// a utility function to generate instances of a class | |
function construct(constructor, args) { | |
var c : any = function () { | |
return constructor.apply(this, args); | |
} |
04/26/2103. From a lecture by Professor John Ousterhout at Stanford, class CS142.
This is my most touchy-feely thought for the weekend. Here’s the basic idea: It’s really hard to build relationships that last for a long time. If you haven’t discovered this, you will discover this sooner or later. And it's hard both for personal relationships and for business relationships. And to me, it's pretty amazing that two people can stay married for 25 years without killing each other.
[Laughter]
> But honestly, most professional relationships don't last anywhere near that long. The best bands always seem to break up after 2 or 3 years. And business partnerships fall apart, and there's all these problems in these relationships that just don't last. So, why is that? Well, in my view, it’s relationships don't fail because there some single catastrophic event to destroy them, although often there is a single catastrophic event around the the end of the relation