Skip to content

Instantly share code, notes, and snippets.

View Pxtl's full-sized avatar
😶

Martin Zarate Pxtl

😶
View GitHub Profile
@Pxtl
Pxtl / gist:3e2ef6fe5e535d6818c624011f80ba0c
Created April 30, 2016 20:34 — forked from lontivero/gist:593fc51f1208555112e0
Generates Markdown from VS XML documentation file
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
{
@Pxtl
Pxtl / Rename-BinCue.ps1
Created December 26, 2019 05:22
Rename Bin/Cue file using Powershell - designed for PS1 files
# for a given cue/bin pair, rename the bin file, rename the cue file with the corresponding name,
# and update the bin reference within the cue file to match
[cmdletbinding()]
param(
[Parameter(Mandatory)][io.FileInfo]$sourceBinPath,
[Parameter(Mandatory)][string]$newName
)
$sourceCuePath = [io.path]::ChangeExtension($sourceBinPath, 'cue')
write-verbose("sourceCuePath: $sourceCuePath")
$sourceBinName = [io.path]::GetFileName($sourceBinPath)
@Pxtl
Pxtl / Create-m3u.ps1
Created December 26, 2019 05:24
Use Powershell to create a ps1 m3u compatible with Lakka
# create an m3u from the given list of files
[cmdletbinding()]
param(
[Parameter(Mandatory)][string] $targetFilePath,
[Parameter(Mandatory)][IO.FileInfo[]]$sourceCuePaths
)
$targetFilePath = [IO.Path]::ChangeExtension($targetFilePath, 'm3u')
$m3uBodyArray = $sourceCuePaths | foreach-object {
[IO.Path]::GetFileName($_)
}