Skip to content

Instantly share code, notes, and snippets.

View mwallner's full-sized avatar
🧙

Manfred Wallner mwallner

🧙
View GitHub Profile
Running miktex-pdftex.exe...
Running miktex-tex.exe...
Chocolatey v0.10.0
[Pending] Removing incomplete install for 'kse-miktex'
Uninstalling the following packages:
kse-miktex-framework
kse-miktex-framework v0.1 (forced)
Cannot remove item C:\kse\kse-miktex-framework\BuildScripts\Tools\Paralizer\Paralizer.suo: You do not have sufficient ac
cess rights to perform this operation.
@mwallner
mwallner / error.txt
Created January 26, 2017 19:07
chocolatey bug ? - Install-BinFile on PowerShell script
E:\ps1crash>ps1crash
Unbehandelte Ausnahme: System.ComponentModel.Win32Exception: Die angegebene ausf
ührbare Datei ist keine gültige Anwendung für diese Betriebssystemplattform.
bei System.Diagnostics.Process.StartWithCreateProcess(ProcessStartInfo startI
nfo)
bei shim.CommandExecutor.execute(String process, String arguments, String wor
king_directory, Boolean is_gui, Boolean wait_for_exit, Boolean requires_elevatio
n)
bei shim.ShimProgram.Main(String[] args)
@mwallner
mwallner / psl-native-test.log
Created January 27, 2017 19:20
PowerShell d7cf81b64dc244ef4451c3be725205058c068a90 native test failure
mw@mwmaster:/trunk/git/PowerShell [master]> ./src/libpsl-native/test/psl-native-test
[==========] Running 32 tests from 14 test cases.
[----------] Global test environment set-up.
[----------] 2 tests from GetFileOwnerTest
[ RUN ] GetFileOwnerTest.CanGetOwnerOfRoot
[ OK ] GetFileOwnerTest.CanGetOwnerOfRoot (0 ms)
[ RUN ] GetFileOwnerTest.CannotGetOwnerOfFakeFile
[ OK ] GetFileOwnerTest.CannotGetOwnerOfFakeFile (0 ms)
[----------] 2 tests from GetFileOwnerTest (0 ms total)
@mwallner
mwallner / ib_build.log
Created April 26, 2017 19:22
Invoke-Build build with cake
PS D:\git\Invoke-Remote> .\build.ps1
Preparing to run build script...
Running build script...
Analyzing build script...
Processing build script...
Installing tools...
Downloading and installing Roslyn...
Installing packages (using https://packages.nuget.org/api/v2)...
Copying files...
Copying Roslyn.Compilers.CSharp.dll...
@mwallner
mwallner / bar\bar.nuspec
Created October 25, 2017 20:10
choco foo/bar force-uninstall dependency
<?xml version="1.0" encoding="utf-8"?>
<!-- Do not remove this test for UTF-8: if “Ω” doesn’t appear as greek uppercase omega letter enclosed in quotation marks, you should use an editor that supports UTF-8, not this one. -->
<package xmlns="http://schemas.microsoft.com/packaging/2015/06/nuspec.xsd">
<metadata>
<id>bar</id>
<version>1.0.0</version>
<title>bar (Install)</title>
<authors>me</authors>
<tags>bar</tags>
<summary>this is bar</summary>
@mwallner
mwallner / BoxstarterPackage.ps1
Created May 15, 2018 07:58
install a chocolatey package with boxstarter using chocolatey sources
param(
$pkg
)
$chococfg = "C:\ProgramData\chocolatey\config\chocolatey.config"
if (-Not $(Test-Path $chococfg)) {
throw "choco config not found!"
}
[xml]$cfg = Get-Content $chococfg
$nugetSources = ""
@mwallner
mwallner / reorigin_accurev_wspaces.ps1
Last active May 23, 2018 16:34
"reorigin" accurev workspaces after hostname change
param(
$oldHostname
)
$erroractionpreference = "Stop"
[xml]$wspaces = accurev show wspaces -fx
$myFQDN=(Get-WmiObject win32_computersystem).DNSHostName+"."+(Get-WmiObject win32_computersystem).Domain
function ReOriginWS($wsname, $wsstorage) {
Write-Output " pulling workspace '$wsname' to '$myFQDN'"
# https://mwallner.net/2017/10/06/powershell-logging-made-easy-thinking-raii/
function Monitor {
param(
[Parameter(Mandatory = $True, ValueFromPipeline = $True)]
[scriptblock]$scriptblk,
[Parameter(Mandatory = $True)]
[string]$Description,
[Parameter(Mandatory = $False)]
[scriptblock]$ResultReceiver,
$API_User = "user"
$API_Pass = "password"
$API_URL = "http://jenkins-host"
$API_Port = "8082"
$API_NODE= "node-name"
$API_MESSAGE= "bye!"
$CRUMB_URI = "${API_URL}:${API_Port}/jenkins/crumbIssuer/api/json"
Write-Host "getting crumb from '$CRUMB_URI'"
#include "stdafx.h"
#include <afxstr.h>
#include <afx.h>
#define PATH_MAX 255
BOOL determine_status(CString szPath) {
wprintf(L" > determine_status: %s\n", szPath);
WIN32_FIND_DATA findFileData;