Skip to content

Instantly share code, notes, and snippets.

View mishrsud's full-sized avatar
🎯
Focusing

Sudhanshu Mishra mishrsud

🎯
Focusing
View GitHub Profile
@shortjared
shortjared / list.txt
Last active May 29, 2024 23:16
List of AWS Service Principals
a4b.amazonaws.com
access-analyzer.amazonaws.com
account.amazonaws.com
acm-pca.amazonaws.com
acm.amazonaws.com
airflow-env.amazonaws.com
airflow.amazonaws.com
alexa-appkit.amazon.com
alexa-connectedhome.amazon.com
amazonmq.amazonaws.com

Summary

This document addresses scenarios such as below:

  1. You branched as branch-123 from develop on a repository
  2. To get your changes tested along with some other branch-345, you merged branch-345 into yours
  3. When the time came to review your branch-123 against develop, there are changes from branch-345 as well (which isn't yet merged to develop)
  4. Hence, you need to remove commits from branch-345 to have the PR show only the diff between branch-123 and develop

Solution

Assume the git log looks like the following

.NET Core 2.0 SDK Preview 1 Support in Visual Studio for Mac 7.0

This document covers the steps required in order to use build and run .NET Core 2.0 and .NET Standard 2.0 projects with Visual Studio for Mac.

Existing project templates target .NET Core 1.1

If only the .NET Core 2.0 SDK is installed then the projects will fail to run due to the 1.1 runtime being unavailable. To target .NET Core 2.0 the TargetFramework in the project will need to be edited to target netcoreapp2.0 or netstandard2.0. Alternatively the dotnet cli installed with the .NET Core 2.0 SDK can be used to create the project with the correct dependencies and target framework.

.NET Core App 2.0 Project

@andrewabest
andrewabest / 1 - Getting Started.md
Last active December 11, 2017 06:30
React Native development on Windows

React Native on Windows

So I've started looking into React Native, as mobile development is still a very hot topic, and I would like to do x-plat mobile development that provides a native experience, but doesn't suck for the developer (I'm looking at you Xamarin). I'm a big fan of React, and doing mobile dev that allows hot-reloading during the dev cycle sounds too good to be true.

I'm also going to be building this app with my son, who is 6. It is going to be for him to track his jobs (chores) and income (pocket money), and track savings and goals - encouraging some financial literacy and hopefully letting him reason about the money he makes and what he can do with it! I'm hoping JSX and Javascript will make for a clean and clear way to teach some of the concepts we will use for building the app. Even running through the boilerplate, it was quite simple to explain to him that a <Text> element in the JSX made the app display some text for us. A good start!

If you follow alon

@gkinsman
gkinsman / new_gist_file
Created February 21, 2017 06:24
UnhandledExceptionLogger
public static class UnhandledExceptionLogger
{
public static void Install()
{
var log = Log.ForContext(typeof(UnhandledExceptionLogger));
AppDomain.CurrentDomain.UnhandledException += (s, e) =>
{
log.Fatal(e.ExceptionObject as Exception, "Unhandled exception caught at AppDomain boundary (terminating: {IsTerminating})", e.IsTerminating);
};
@davidfowl
davidfowl / Example1.cs
Last active March 28, 2024 20:36
How .NET Standard relates to .NET Platforms
namespace Analogy
{
/// <summary>
/// This example shows that a library that needs access to target .NET Standard 1.3
/// can only access APIs available in that .NET Standard. Even though similar the APIs exist on .NET
/// Framework 4.5, it implements a version of .NET Standard that isn't compatible with the library.
/// </summary>INetCoreApp10
class Example1
{
public void Net45Application(INetFramework45 platform)
@emoacht
emoacht / EnumService.cs
Created July 20, 2015 01:17
Get Enum values from Type variable.
public class EnumService
{
public enum Hero
{
Super,
Bat,
Iron,
}
public void ShowEnumValues()
@mythz
mythz / 01-WebApiProducts.cs
Created October 13, 2012 23:40
Your First ASP.NET Web API Products Example vs ServiceStack
/* Tutorial example from:
* Your First ASP.NET Web API (C#):
* http://www.asp.net/web-api/overview/getting-started-with-aspnet-web-api/tutorial-your-first-web-api
*/
namespace HelloWebAPI.Controllers
{
public class ProductsController : ApiController
{
Product[] products = new Product[]
{
@gre
gre / easing.js
Last active May 17, 2024 03:33
Simple Easing Functions in Javascript - see https://github.com/gre/bezier-easing
/*
* This work is free. You can redistribute it and/or modify it under the
* terms of the Do What The Fuck You Want To Public License, Version 2,
* as published by Sam Hocevar. See the COPYING file for more details.
*/
/*
* Easing Functions - inspired from http://gizma.com/easing/
* only considering the t value for the range [0, 1] => [0, 1]
*/
EasingFunctions = {