// Wire up Unhandled Expcetion handler from Android
AndroidEnvironment.UnhandledExceptionRaiser += (sender, args) =>
{
/*
* When the UI Thread crashes this is the code that will be executed. There is no context at this point
* and no way to recover from the exception. This is where you would capture the error and log it to a
* file for example. You might be able to post to a web handler, I have not tried that.
*
This file contains hidden or 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
// (c) 2017 Yauheni Pakala | |
(function(p,l){l.protocol===p||(l.protocol=p)}("https:",window.location)) |
for j in *.bak; do mv -- "$j" "temp_${j%.bak}.txt"; done
Example:
from:
123.bak
This file contains hidden or 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 class ViewPagerIndicator : LinearLayout, ViewPager.IOnPageChangeListener | |
{ | |
private TextView _textView; | |
private ViewPager _viewPager; | |
#region Android view dafault constructors | |
public ViewPagerIndicator(Context context) | |
: base(context) | |
{ |
This file contains hidden or 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
// (c) 2016 Yauheni Pakala | |
var _parseInt = str => str.replace(/(.*?)(\d+)(.*)/,'$2') - 0; | |
// test | |
console.log(_parseInt("123hui")); | |
console.log(_parseInt("123hui321")); | |
console.log(_parseInt("hui123")); |
This file contains hidden or 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 class CarouselIndicators : Grid | |
{ | |
private ImageSource UnselectedImageSource = null; | |
private ImageSource SelectedImageSource = null; | |
private readonly StackLayout _indicators = new StackLayout() { Orientation = StackOrientation.Horizontal, HorizontalOptions = LayoutOptions.CenterAndExpand }; | |
public CarouselIndicators() | |
{ | |
this.HorizontalOptions = LayoutOptions.CenterAndExpand; | |
this.RowDefinitions.Add(new RowDefinition() { Height = GridLength.Auto }); |
This file contains hidden or 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 class BaseViewModel : BaseNotify | |
{ | |
bool _isBusy = false; | |
CancellationTokenSource _cancellationTokenSource = new CancellationTokenSource(); | |
public bool IsBusy | |
{ | |
get | |
{ | |
return _isBusy; |
This file contains hidden or 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 interface IRemove | |
{ | |
ICommand RemoveCommand { get; } | |
} |
This file contains hidden or 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
description "node.js server" | |
author "Yuaheni Pakala" | |
# used to be: start on startup | |
# until we found some mounts weren't ready yet while booting: | |
start on started mountall | |
stop on shutdown | |
# Automatically Respawn: | |
respawn |
This file contains hidden or 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
itms-services://?action=download-manifest&url=http://loqi.me/app/Geoloqi.plist | |
From: http://aaronparecki.com/articles/2011/01/21/1/how-to-distribute-your-ios-apps-over-the-air |