uti | platforms | packages | ||||||
---|---|---|---|---|---|---|---|---|
com.xamarin.workbook |
|
|
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
# Run the last command as root | |
sudo !! | |
# Serve current directory tree at http://$HOSTNAME:8000/ | |
python -m SimpleHTTPServer | |
# Save a file you edited in vim without the needed permissions | |
:w !sudo tee % | |
# change to the previous working directory | |
cd - | |
# Runs previous command but replacing | |
^foo^bar |
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
#install chocolatey | |
Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1')) | |
#generate list of installed applications with exact version | |
choco list -lo -r -y | % { "choco install " + $_.Replace("|", " ") + " -y" } | |
#generate list of installed application without version. | |
choco list -lo --id-only -y | % { "choco install " + $_.Replace("|", " ") + " -y" } | |
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
Use ReportServer | |
go | |
/* Performance Tips | |
1. High TimeDataRetriveal | |
* Removed unused datasets | |
* Analyze the dataset query in SQL Profiler | |
* Combine Datasets where possible | |
2. High TimeProcessing | |
* Use less report parts (tables, charts...) | |
* Do Grouping and Sorting on the SQL Side |
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
/* | |
Student Planning goes down randomly and we have to recycle the app pool to fix it. | |
This script will try to login to Student Planning and make an AJAX request. It will | |
return text output (console.log() output) about whether it is working or not. | |
NOTE: this script relies on PhatomJS, which you can download here: | |
http://phantomjs.org/download.html | |
NOTE: change the values of the host, user, and pass variables. Optionally change the timeout variable. | |
*/ |
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
#Requires -RunAsAdministrator | |
#Requires -Version 3.0 | |
#References: | |
#Getting Started with Nano Server <https://technet.microsoft.com/en-us/library/mt126167.aspx> | |
#Quick Guide - Deploying Nano Server using PowerShell <http://deploymentresearch.com/Research/Post/479/Quick-Guide-Deploying-Nano-Server-using-PowerShell> | |
param ( | |
#[ValidateScript({ Test-Path $_ })] | |
$ConvertWindowsImageScriptPath = 'D:\work\NanoServerSetup\Convert-WindowsImage.ps1' |
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
using System; | |
namespace Hongy | |
{ | |
/// <summary> | |
/// Represents vectorless interval of the form [a, b] or (a, b) or any | |
/// combination of exclusive and inclusive end points. | |
/// </summary> | |
/// <typeparam name="T">Any comparent type</typeparam> | |
/// <remarks> |
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
#region Encryption | |
/// <summary> | |
/// Generate a private key | |
/// From : www.chapleau.info/blog/2011/01/06/usingsimplestringkeywithaes256encryptioninc.html | |
/// </summary> | |
private static string GenerateKey(int iKeySize) | |
{ | |
RijndaelManaged aesEncryption = new RijndaelManaged(); | |
aesEncryption.KeySize = iKeySize; | |
aesEncryption.BlockSize = 128; |
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
namespace PKI | |
{ | |
class Results : IEquatable<Results> | |
{ | |
internal static readonly Results NotFound = new Results | |
{ | |
Directory = "", | |
KeyName = "" | |
}; |
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
/* | |
Call the api client like this: | |
var client = new ApiClient<SEnvelope>("https://baseurl.com/api/v1"); | |
//you would overload and add an auth_token param here | |
client.GetDtoAsync("envelopes", "object_id", (response) => //callback | |
{ | |
this.SEnvelope = response.Data;//should be an envelope from the server | |
}); | |
NewerOlder