Skip to content

Instantly share code, notes, and snippets.

View andreinitescu's full-sized avatar

Andrei Nitescu andreinitescu

View GitHub Profile
@andreinitescu
andreinitescu / AssemblyAnalyzer.cs
Created July 16, 2023 16:28 — forked from jbe2277/AssemblyAnalyzer.cs
AssemblyAnalyzer via System.Reflection.Metadata
using System;
using System.Collections.Immutable;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Reflection.Metadata;
using System.Reflection.PortableExecutable;
using System.Security.Cryptography;
@andreinitescu
andreinitescu / dotnetlayout.md
Created July 12, 2022 02:53 — forked from davidfowl/dotnetlayout.md
.NET project structure
$/
  artifacts/
  build/
  docs/
  lib/
  packages/
  samples/
  src/
 tests/
using System;
using System.Linq;
using System.Runtime.InteropServices;
using EnvDTE;
using EnvDTE80;
using Microsoft.VisualStudio;
using Microsoft.VisualStudio.Shell;
using Microsoft.VisualStudio.Shell.Interop;
using Microsoft.VisualStudio.Text.Editor;
using Microsoft.VisualStudio.TextManager.Interop;
/// <summary>
/// A hash combiner that is implemented with the Fowler/Noll/Vo algorithm (FNV-1a). This is a mutable struct for performance reasons.
/// Taken from https://gist.github.com/StephenCleary/4f6568e5ab5bee7845943fdaef8426d2
/// </summary>
public struct FnvHash
{
/// <summary>
/// The starting point of the FNV hash.
/// </summary>
public const long Offset = 2166136261;
@andreinitescu
andreinitescu / Cisco.vbs
Created December 2, 2020 09:54 — forked from paveleremin/Cisco.vbs
Cisco AnyConnect: save password
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.Run """%PROGRAMFILES(x86)%\Cisco\Cisco AnyConnect Secure Mobility Client\vpnui.exe"""
WScript.Sleep 1500
WshShell.AppActivate "Cisco AnyConnect Secure Mobility Client"
WshShell.SendKeys "{TAB}"
WshShell.SendKeys "{TAB}"
@andreinitescu
andreinitescu / esnextbin.md
Last active April 7, 2016 10:13
esnextbin sketch
@andreinitescu
andreinitescu / gist:69e8afcad1ed9de69b76
Last active October 30, 2018 19:33
Xamarin Forms style resets
<!-- Put this inside App.xaml -->
<!-- if you don't know how to add App.xaml to your project use this guide: http://goo.gl/GuXMDD/>
<!-- Some default style resets -->
<Style TargetType="Grid">
<Setter Property="Padding"
Value="0" />
<Setter Property="RowSpacing"
Value="0" />
<Setter Property="ColumnSpacing"
// MvxActivity.cs
// (c) Copyright Cirrious Ltd. http://www.cirrious.com
// MvvmCross is licensed using Microsoft Public License (Ms-PL)
// Contributions and inspirations noted in readme.md and license.txt
//
// Project Lead - Stuart Lodge, @slodge, me@slodge.com
using System;
using System.Collections.Generic;
using Android.App;
@andreinitescu
andreinitescu / MvxCachingFragmentActivityBehavior.cs
Last active August 29, 2015 14:13
MvxCachingFragmentActivityBehavior
using System;
using System.Collections.Generic;
using System.Linq;
using Android.App;
using Android.OS;
using Cirrious.CrossCore;
using Cirrious.CrossCore.Exceptions;
using Cirrious.CrossCore.Platform;
using Cirrious.MvvmCross.Droid.FullFragging.Fragments;
using Cirrious.MvvmCross.Droid.Platform;