Skip to content

Instantly share code, notes, and snippets.

Bob Archer PilotBob

Block or report user

Report or block PilotBob

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:dcdf5bfcc0e7c11200dce83b2d29bef2
2018-12-17T18:04:20.0637782Z Prepending Path environment variable with directory containing 'git.exe'.
2018-12-17T18:04:20.0803087Z ##[command]git version
2018-12-17T18:04:20.5487112Z git version 2.14.3.windows.1
2018-12-17T18:04:20.5585776Z ##[command]git lfs version
2018-12-17T18:04:20.9954212Z git-lfs/2.6.1 (GitHub; windows amd64; go 1.11.1; git dc072c3e)
2018-12-17T18:04:21.0085413Z ##[command]git config --get remote.origin.url
2018-12-17T18:04:21.1570796Z ##[command]git config gc.auto 0
2018-12-17T18:04:21.2322820Z ##[command]git config --get-all http.https://amsidev.visualstudio.com/Infor%20Property%20Management/_git/InforPropertyManagement.extraheader
2018-12-17T18:04:21.2935813Z ##[command]git config --get-all http.proxy
2018-12-17T18:04:21.3637727Z ##[command]git lfs install --local
View editroles.html
{#each perms as node}
<li class="folder {node.Granted}">
<a on:click="event.preventDefault()"
href="/#"
title={node.Description}
id={node.RuntimeName}
role="treeitem"
tabindex="0"
aria-selected="true"
aria-level="0" aria-posinset="1" aria-setsize="13" class="hide-focus">
View explict load
This works:
db.Entry(target).Collection(r => r.Permissions).Load();
target.Permissions.Remove(permission);
This doesn't:
db.Entry(target).Collection(r => r.Permissions).Query().Where(p => p.ID == permission.ID).Load();
target.Permissions.Remove(permission);
View Agentlog.txt
2018-05-31T14:34:15.9502941Z ##[section]Starting: Download artifact - InforPropertyManagement-CI
2018-05-31T14:34:15.9699892Z ==============================================================================
2018-05-31T14:34:15.9700337Z Task : Download Build Artifacts
2018-05-31T14:34:15.9700611Z Description : Download Build Artifacts
2018-05-31T14:34:15.9700895Z Version : 0.136.1
2018-05-31T14:34:15.9701146Z Author : Microsoft Corporation
2018-05-31T14:34:15.9701423Z Help :
2018-05-31T14:34:15.9701701Z ==============================================================================
2018-05-31T14:34:24.0509330Z Downloading artifacts for build: 626
2018-05-31T14:34:32.1900845Z Linked artifacts count: 1
View createcert.bat
@echo off
REM IN YOUR SSL FOLDER, SAVE THIS FILE AS: makeCert.bat
REM AT COMMAND LINE IN YOUR SSL FOLDER, RUN: makecert
REM IT WILL CREATE THESE FILES: example.cnf, example.crt, example.key
REM IMPORT THE .crt FILE INTO CHROME Trusted Root Certification Authorities
REM REMEMBER TO RESTART APACHE OR NGINX AFTER YOU CONFIGURE FOR THESE FILES
REM PLEASE UPDATE THE FOLLOWING VARIABLES FOR YOUR NEEDS.
SET HOSTNAME=yourhouse.name.here
@PilotBob
PilotBob / kendouibundle.cs
Created Dec 14, 2017
KendoUI for MVC bundle pointing to NuGet package installed Content and Script folders
View kendouibundle.cs
// KendoUI Bundles
var path = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "bin");
var kendoVersion = Assembly.LoadFrom(Path.Combine(path, "Kendo.Mvc.dll")).GetName().Version;
var kendoFormatedVersion = $"{kendoVersion.Major}.{kendoVersion.Minor}.{kendoVersion.Build}";
bundles.Add(new ScriptBundle("~/bundles/kendoui").Include(
$"~/Scripts/kendo/{kendoFormatedVersion}/kendo.all.min.js"));
bundles.Add(new StyleBundle("~/Content/kendoui").Include(
$"~/Content/kendo/{kendoFormatedVersion}/kendo.common.min.css",
$"~/Content/kendo/{kendoFormatedVersion}/kendo.blueopal.min.css"));
View gist:df7119ea471fac1ed85e
if I do this:
var result = db.People.Where(p => p.first = "pilot" && p.last = "bob").Select(p => p.Id).SingleOrDefault();
Can I later do this and expect to find a result?
var result = db.People.Local.Where(p => p.first = "pilot" && p.last = "bob").Select(p => p.Id).SingleOrDefault();
Or since I did a projection is the entity not actually loaded into the context?
View gist:cc496ad4354ced9deadc
while($data =~ /\<b\>.*?\[\W*?$type\W*?(.*?)\].*?\<\/b\>/i)
{
$votee = lc($1);
$type = lc($type);
$votee =~ s/\<img src=.*\/(.*?)\.gif.*?\>/$1/i;
$name = lc($votee);
View Vote_bi.sql
vote_check:begin
declare tally_id int(11);
declare new_count int(11);
declare new_tally int(1);
declare nightfall int(1);
if new.valid != 1 then
leave vote_check;
end if;
set new_tally := 0;
@PilotBob
PilotBob / boxstarter.txt
Last active Jan 27, 2018
My Boxstarter Script
View boxstarter.txt
# Boxstarter options
$Boxstarter.RebootOk=$true # Allow reboots?
$Boxstarter.NoPassword=$false # Is this a machine with no login password?
$Boxstarter.AutoLogin=$true # Save my password securely and auto-login after a reboot
# Basic setup
Update-ExecutionPolicy Unrestricted
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowFileExtensions -EnableShowFullPathInTitleBar
Enable-RemoteDesktop
You can’t perform that action at this time.