Skip to content

Instantly share code, notes, and snippets.

@patrickhuber
patrickhuber / Clear-Tfscache.ps1
Created November 18, 2015 14:48 — forked from anonymous/Clear-Tfscache.ps1
clears the tfs cache for visual studio
$ErrorActionPreference = "Stop"
$directory = [io.path]::combine($env:LOCALAPPDATA, "microsoft", "team foundation")
foreach($versionDirectory in get-childitem $directory)
{
$cacheDirectory = Join-Path $versionDirectory.FullName "Cache"
$items = Get-ChildItem $cacheDirectory
foreach($item in $items)
{
Remove-Item -Recurse -Force $item.FullName
}
# setup
Set-ExecutionPolicy AllSigned
# install chocolatey
iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
# install packages
choco install firefox -y
choco install filezilla -y
choco install javaruntime -y
@patrickhuber
patrickhuber / Person.java
Last active August 29, 2015 14:05
Java Property Class
package com.props.tests;
import java.util.Date;
import com.props.*;
public class Person {
public final Property<Integer> id = new Property<Integer>();
public final Property<String> firstName = new Property<String>();
public final Property<String> lastName = new Property<String>();
public final Property<Date> dateOfBirth = new Property<Date>();
}