Skip to content

Instantly share code, notes, and snippets.

View dtaalbers's full-sized avatar
💻
Doing the computer stuff things..

Tom Aalbers dtaalbers

💻
Doing the computer stuff things..
View GitHub Profile
@dtaalbers
dtaalbers / address.js
Last active September 18, 2016 16:55
Aurelia Validation Demo using a model in the viewmodel
import { ValidationRules } from 'aurelia-validation';
export class Address {
street;
city;
}
ValidationRules
.ensure(a => a.street).required()
.ensure(a => a.city).required()
@dtaalbers
dtaalbers / gist:0f0f1247b1b27f8dad1cc2e1d3ec07bd
Created July 31, 2016 15:21
Connecting to Visual Studio on Parallels 11 VM windows via your mac
Follow these steps:
https://www.getdonedone.com/accessing-your-windows-development-environment-from-osx/
Configure your parralels VM to share all file disk
When setting up your IIS website make sure the Physical path points to the MAC network and root folder of your application.
This way you can still keep your project files on your mac disk en run them though IIS on your VM
@dtaalbers
dtaalbers / gist:0d4e625a287f81279689
Created September 25, 2015 10:01
SearchById Index RavenDb
// Create index, NOTE the plural form of DocTypes
from doc in docs.DocTypes
select new {
doc.Id
}
// Now you can query documents like this, NOTE the plural form of DocTypes
Id: DocTypes/108449
@dtaalbers
dtaalbers / gist:32bf072e368262c2fdea
Last active October 2, 2015 10:22
Get all RavenDB documents from one document type (overcome 1024 limit)
public List<DocType> DoStuffForALotOfData()
{
var list = new List<DocType>();
using (var session = _DataContext.OpenSession())
{
var skip = 0;
var take = 50;
// Execute query
@dtaalbers
dtaalbers / gist:0a65f6f598704b722609
Created June 2, 2015 06:52
Unblock all files in directory through powershell
gci c:someFolder -Recurse | Unblock-File