This is a quick guide to debug potential line ending weirdness.
Note: I've thrown a lot of concepts in here around Git data structures without going into depth. If there's things that are unclear or you'd like some more details, just leave a comment and I'll either reply or expand on this post accordingly...
What sort of weirdness am I referring to? Consider this commit: https://github.com/dalefrancis88/Windsor/commit/e2543e5573781c7ded83166932c9c415feef11c0
While it looks like a very large commit, the contents of the file are unchanged. But the diffs are very intimidating.
- Recipes
- Anonymous GET access
- Anonymous GET access - match HTTP referrer
- Full access for specific IAM user/role
- GET/PUT/DELETE access to specific path within a bucket
- Restricted LIST & PUT/DELETE access to specific path within a bucket
- Full access (and S3 console) for specific IAM users
- Bucket and object delete deny
// | |
// Countdown.cs | |
// Created by Alexey Kinev on 11 Jan 2015. | |
// | |
// Licensed under The MIT License (MIT) | |
// http://opensource.org/licenses/MIT | |
// | |
// Copyright (c) 2015 Alexey Kinev <alexey.rudy@gmail.com> | |
// | |
using System; |
* Reducing executable size: | |
http://developer.xamarin.com/guides/cross-platform/deployment,_testing,_and_metrics/memory_perf_best_practices/#Reducing_Executable_Size | |
* Use the linker (iOS [1], Android [2]) to remove unnecessary code from your assemblies | |
[1] https://developer.xamarin.com/guides/ios/advanced_topics/linker | |
[2] https://developer.xamarin.com/guides/android/advanced_topics/linking | |
* Reference third-party libraries judiciously | |
* Applying constraints to generics may reduce app size, since less code would need to be included (haven’t verified this) |
*update: TBC, but this new might affect how easy it is to use this technique past August 2024: Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August
This gist, based in part on a gist by Brian Hartvigsen, allows you to export from Authy your TOTP tokens you have stored there.
Those can be "standard" 6-digits / 30 secs tokens, or Authy's own version, the 7-digits / 10 secs tokens.
using Microsoft.AspNetCore.Builder; | |
using Microsoft.AspNetCore.Http; | |
using Microsoft.AspNetCore.WebUtilities; | |
using Microsoft.Net.Http.Headers; | |
using System.IO; | |
using System.Security.Cryptography; | |
using System.Threading.Tasks; | |
public class ETagMiddleware | |
{ |
// https://support.hockeyapp.net/kb/api/api-crashes | |
public static async Task<bool> SendHandledException(CaughtExceptionModel model) | |
{ | |
string version = DeviceInfo.AppVersion; | |
var arr = version.Split('.'); | |
string short_ver = arr[arr.Length - 1]; | |
var deviceInfo = Plugin.DeviceInfo.CrossDeviceInfo.Current; | |
StringBuilder sb = new StringBuilder(12000); |
using Microsoft.AspNetCore.Mvc.Testing; | |
using System.Net; | |
using System.Threading.Tasks; | |
using Xunit; | |
using System.Net.Http; | |
using System.Collections.Generic; | |
using Newtonsoft.Json; | |
namespace Api.FunctionalTests | |
{ |
using System; | |
using System.Threading.Tasks; | |
namespace System.Collections.Concurrent | |
{ | |
public static class ConcurrentDictionaryExtensions | |
{ | |
/// <summary> | |
/// Provides an alternative to <see cref="ConcurrentDictionary{TKey, TValue}.GetOrAdd(TKey, Func{TKey, TValue})"/> that disposes values that implement <see cref="IDisposable"/>. | |
/// </summary> |