View script.sh
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
# Rosseta | |
/usr/sbin/softwareupdate --install-rosetta --agree-to-license | |
# Xcode Command Line Tools (Need Xcode) | |
xcode-select --install | |
sudo xcode-select -s /Applications/Xcode.app | |
# Microsoft OpenJDK 11 |
View file.cs
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
public static class TestClass | |
{ | |
static string GetMsBuildPath(int versionMajor, string pathContains) | |
{ | |
var defaultDirectories = new[] | |
{ | |
Path.Combine(System.Environment.GetEnvironmentVariable("HOME"), "Library/Caches/VisualStudio"), | |
"/Library/Frameworks/Mono.framework/Versions", | |
"/usr/local/share/dotnet/sdk", |
View gist:f4c7527d1fb11fa27c405e7576b1639c
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
<html> | |
<body> | |
<script src="http://code.jquery.com/jquery-2.1.4.min.js"></script> | |
<h1>HybridWebView Test</h1> | |
<br /> | |
Enter name: <input type="text" id="name"> | |
<br /> | |
<br /> | |
<button type="button" onclick="javascript: invokeCSCode($('#name').val());">Invoke C# Code</button> | |
<br /> |
View gist:f2a565913a05c36f80f4f9de02410934
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
@" | |
document.body.addEventListener('click', function(e) { | |
e = e || window.event; | |
var target = e.target || e.srcElement; | |
Native('invokeClick', 'tag='+target.tagName+' id='+target.id+' name='+target.name); | |
}, true /* to ensure we capture it first*/); | |
" |
View PageSpecific.cs
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
public static class PageSpecific | |
{ | |
public static readonly BindableProperty BackSwipeEnableProperty = | |
BindableProperty.Create("BackSwipeEnable", typeof(bool), typeof(Page), true, BindingMode.OneTime); | |
public static bool GetBackSwipeEnable(BindableObject element) | |
=> (bool) element.GetValue(BackSwipeEnableProperty); | |
public static void SetBackSwipeEnable(BindableObject element, bool value) | |
=> element.SetValue(BackSwipeEnableProperty, value); |
View DisplayHelper.cs
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
using System.Linq; | |
using Foundation; | |
using Xamarin.Essentials; | |
using Xamarin.Forms; | |
namespace MyNamespace | |
{ | |
public class DisplayHelper | |
{ | |
const string IphoneModelPrefix = "iphone"; |
View ResXFileCodeGenerator Sample
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
<?xml version="1.0" encoding="utf-8"?> | |
<Project Sdk="Microsoft.NET.Sdk"> | |
<PropertyGroup> | |
<OutputType>Exe</OutputType> | |
<TargetFramework>net5.0</TargetFramework> | |
</PropertyGroup> | |
<!--<Target Name="GenerateResx" AfterTargets="BeforeBuild"> | |
<Message Text="Check Resources.Designer.cs" Importance="high" /> | |
<Message Text="Generating Designer Files..." /> | |
<GenerateResource Sources="@(EmbeddedResource)" StronglyTypedLanguage="cs" StronglyTypedClassName="%(Filename)" StronglyTypedNamespace="@(EmbeddedResource->'%(CustomToolNamespace)')" StronglyTypedFileName="@(EmbeddedResource->'%(RootDir)%(Directory)%(Filename).designer.cs')" PublicClass="true" /> |
View RunSyncUtil.cs
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
using System; | |
using System.Threading.Tasks; | |
namespace Sync | |
{ | |
public static class RunSyncUtil | |
{ | |
private static readonly TaskFactory factory = new | |
TaskFactory(default, | |
TaskCreationOptions.None, |
View gist:256877569a8de8581e9de67779fac087
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
=== Visual Studio Community 2019 for Mac === | |
Version 8.8.10 (build 2) | |
Installation UUID: f8caf6ef-1bee-4228-a7ca-ccc3745efdd9 | |
GTK+ 2.24.23 (Raleigh theme) | |
Xamarin.Mac 6.18.0.23 (d16-6 / 088c73638) | |
Package version: 612000122 | |
=== Mono Framework MDK === |
View Pharmacist.NuGet.g.cs
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
// Licensed to the .NET Foundation under one or more agreements. | |
// The .NET Foundation licenses this file to you under the MIT license. | |
// See the LICENSE file in the project root for more information. | |
//------------------------------------------------------------------------------ | |
// <auto-generated> | |
// This code was generated from a template. | |
// | |
// Manual changes to this file may cause unexpected behavior in your application. | |
// Manual changes to this file will be overwritten if the code is regenerated. |
NewerOlder