Skip to content

Instantly share code, notes, and snippets.

@jeremybeavon
jeremybeavon / restore-teamcity.cmd
Last active May 5, 2016 03:34 — forked from grenade/restore-teamcity.cmd
Restore TeamCity from a backup file, preserving artifacts and plugins
:: set these variables to match TeamCity environment
SET TEAMCITY_DATA_PATH=D:\Config\TeamCity
SET TEAMCITY_DATA_BACKUP=D:\Temp\TeamCity
SET TEAMCITY_HOME=C:\TeamCity
SET TEAMCITY_BACKUP_FILE=D:\Config\TeamCity\TeamCity_Backup_xxx_xxx.zip
:: maintainDB expects these directories to be empty or absent.
move /Y %TEAMCITY_DATA_PATH%\config %TEAMCITY_DATA_BACKUP%\config
move /Y %TEAMCITY_DATA_PATH%\system %TEAMCITY_DATA_BACKUP%\system
@jeremybeavon
jeremybeavon / XmlToMarkdown.cs
Last active March 16, 2017 22:36 — forked from lontivero/gist:593fc51f1208555112e0
Convert XML to markdown
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text.RegularExpressions;
using System.Xml;
using System.Xml.Linq;
namespace GithubWikiDoc
{