Skip to content

Instantly share code, notes, and snippets.

View dviererbe's full-sized avatar

Dominik Viererbe dviererbe

View GitHub Profile
@dviererbe
dviererbe / .quiltrc
Created June 20, 2024 11:30
My quiltrc file for working with debian source packages
#!/usr/bin/env bash
#set -euo pipefail
# find the root of a debian source tree:
SourcePackageRoot="${PWD}"
while [ ! -s "$SourcePackageRoot/debian/source/format" ]
do
if [ "${SourcePackageRoot}" = '/' ]
then
echo -e '\033[1;33mWARNING\033[0m: You are not in a debian source tree!'
{
"$schema": "../../Documentation/json-schema/distro-support-schema.json",
"Ubuntu": {
"installCommand": "sudo apt-get update && sudo apt-get install -y {0}",
"uninstallCommand": "sudo apt-get remove {0}",
"updateCommand": "sudo apt-get update && apt-get upgrade -y {0}",
"isInstalledCommand": "sudo apt list --installed {0}",
"packageLookupCommand": "dpkg -l {0}",
"expectedDistroFeedInstallDirectory" : "/usr/lib/dotnet/sdk",
"expectedMicrosoftFeedInstallDirectory" : "/usr/bin/dotnet",
@dviererbe
dviererbe / dotnet-eol-SRU-exception-request.md
Last active September 1, 2023 12:43
Ubuntu SRU Exception for .NET End of Life Process

.NET End of Life Process

This document describes the policy for end of (support) life for .NET packages in a stable supported distro, including LTS.

.NET is an open-source platform for building desktop, web, and mobile applications that can run natively on any operating system. The .NET ecosystem includes tools, libraries, and languages that support modern, scalable, and high-performance software development.

Cananoical collaborates with Microsoft to package .NET releases for the Ubuntu Platform:

@dviererbe
dviererbe / watch
Last active August 4, 2023 11:22
.NET 8 debian watch file+script
version=4
# watch for 8.0.X[X[-TEXT.X.XXXXX.X]] pattern:
# watch for 8.0.100-preview.1; 8.0.100-preview.2; 8.0.100-preview.3:
opts="mode=git,repack,compression=xz,dversionmangle=s/^8\.0\.(1\d\d)-//,uversionmangle=s/^8\.0\.100/8.0.0/;s/-([a-z]+)\./~$1/" \
git@github.com:dotnet/dotnet.git \
^refs/tags/v(8\.0\.\d{1,3}(?:-[a-z]+\.\d+)?).*$ \
debian \
debian/watch-script.sh
@dviererbe
dviererbe / test-ubuntu-image-redirections.sh
Last active July 26, 2023 19:21
Check if the ubuntu image '-latest' redirects work.
#!/usr/bin/env bash
# Check if the ubuntu image '-latest' redirects work.
#source /etc/os-release
UBUNTU_CODENAME=jammy
VERSION_ID=22.04
all_checks_successful=true
function check_url()
@dviererbe
dviererbe / PrintSupportedRuntimeIdentifiers.fsx
Last active May 19, 2023 14:17
A test script that checks if all supported RIDs are buildable via the dotnet CLI
open System
open System.IO
open System.Text.Json
let printUsage() =
printfn "Usage:"
printfn $" dotnet fsi {fsi.CommandLineArgs[0]} help"
printfn $" dotnet fsi {fsi.CommandLineArgs[0]} <path>"
printfn ""
printfn "Commands:"
@dviererbe
dviererbe / codium-adapter-for-sensible-editor.sh
Created May 18, 2023 16:33
Adapter script to call Codium from sensible-editor with the +n syntax.
#!/usr/bin/env bash
set -eo pipefail
case "$#" in
"0")
codium --wait
;;
"1")
codium --wait "$1"
#!/usr/bin/env bash
function PrintUsage
{
echo "Description:"
echo " Creates a temporary directory name that is not taken before running"
echo " this command. Works simillarly to mktemp but with incremental number"
echo " suffix (e.g. tmp_1, tmp_2, ...)"
echo ""
echo "Usage:"
@dviererbe
dviererbe / LaunchpadCommentSyntax.md
Created April 12, 2023 15:57
A document that describes how Launchpad parses bug comments.

Launchpad Comment Parsing

Whitespace

Launchpad will

  • cut off any whitespace to the right and
  • keep any whitespace to the left and
  • reduce any whitespace between non-whitespace characters to just one.

Note: Technically Launchpad passes whitespace through and the browser just ignores the whitespace.

@dviererbe
dviererbe / DeleteAllObjectsOfS3Bucket.cs
Created May 8, 2022 14:08
A simple script that deletes all objects located in an S3 Bucket.
// uses AWSSDK.S3 NuGet Package
using Amazon.S3;
using Amazon.S3.Model;
// TODO: paste access key here
const string AccessKey = "";
// TODO: paste secret key here
const string SecretKey = "";