Skip to content

Instantly share code, notes, and snippets.

View robie2011's full-sized avatar

Robert Rajakone robie2011

View GitHub Profile
$Stats = @()
1..10 |% {
$i = $_
Write-Progress -Activity "Iteration $i" -Status "Cleanup" -PercentComplete ($i/10)
dotnet clean NakaOne.sln
Write-Progress -Activity "Iteration $i" -Status "Build" -PercentComplete ($i/10)
$Stats += Measure-Command { dotnet build NakaOne.sln }
@robie2011
robie2011 / Models.cs
Created July 6, 2023 10:19
RxDb Sync Poco
using System.Collections.Immutable;
namespace RxDbSyncTests;
public static class Models
{
public record Entry(
int Id,
int Value,
DateTime CreatedAt,
@robie2011
robie2011 / current.js
Last active August 11, 2022 08:40
window resize service
import Debouncer from "./debouncer.js"
// 1. Sollte in der regel const sein statt var; Dies verhindert viele Probleme.
var resizeHandler;
var debouncer;
var dotNetReferences = [];
// 2. Ist diese Funktion angedacht mehrmals zu rufen oder einmal?
// Aktuell ist gemäss Code ein gemisch, dass nicht aufgeht.
{
"type": "hostService",
"configuration": {
"reverseProxyPrefix": "/zerf"
},
"openIdApplications": [
{
"clientType": "public",
"clientId": "NakaOneBlazorWasmClient",
"redirectUris": ["http://localhost:8080/zerf/authentication/login-callback"],
@robie2011
robie2011 / example1.html
Created July 21, 2021 07:46
bootstrap tooltip
<!doctype html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">
@robie2011
robie2011 / gist:02deff5d7200746d2ee720ecae246e25
Created December 22, 2020 10:24
Push nuget package to local store
$targetDir = "$env:USERPROFILE\.nuget\packages"
gci -Filter *.nupkg | % { nuget push $_.Name -Source $targetDir }
@robie2011
robie2011 / azure-devops-commit-copy.js
Last active October 13, 2020 09:51
Azure DevOps
// ==UserScript==
// @name pull request copy
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match http://rmitfs:8080/tfs/Messerli%20Main/*/pullrequest/*
// @grant none
// @require https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/2.0.4/clipboard.min.js
// ==/UserScript==
@robie2011
robie2011 / ConfigMongoDb.cs
Last active August 20, 2020 06:09
C# MongoDb get document by id not working
using MongoDB.Bson.Serialization.Conventions;
namespace Judasheet
{
public static class ConfigMongoDb
{
public static void SetupConvention()
{
var pack = new ConventionPack();
pack.Add(new CamelCaseElementNameConvention());
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using Microsoft.Extensions.Logging;
using Xunit;
using Xunit.Abstractions;
namespace EfSqlite.Tests
@robie2011
robie2011 / example.md
Created September 13, 2019 13:43
pandoc pdf customize toc pagebreak problem

A

hello

hello

hello

hello

hello

hello

hello

hello

hello