Skip to content

Instantly share code, notes, and snippets.

@fokklz
fokklz / Dockerfile
Created November 1, 2023 13:59
Dockerfile for EF-Core Web API (net 0.7)
FROM mcr.microsoft.com/dotnet/aspnet:7.0 AS base
WORKDIR /app
EXPOSE 80
FROM mcr.microsoft.com/dotnet/sdk:7.0 AS build
WORKDIR /src
COPY ["MyWebApi.csproj", ""]
RUN dotnet restore "./MyWebApi.csproj"
COPY . .
WORKDIR "/src/."
#!/usr/bin/env bash
# shellcheck disable=SC1090
# all modifications are marked with "MODIFICATION: FLZ_PI_HOLE" comment
# for ease of identification
window.s1PxyAdsTag='4jr1ZbZYIEqcP0jtz8H2';if(!window['googleNDT_']){window['googleNDT_']=(new Date()).getTime();}(function() {window.googleAltLoader=4;var sffeData_={service_host:"www.startpage.com/sp",hash:"7671338626507399651",packages:"search",module:"ads",version:"3",m:{cei:"17301293,17301321,17301323",ah:true,uatm:500,ecfc2:true,llrm:1000,lldl:"bS5zZWFycy5jb20=",abf:{"_enableLazyLoading":true,"_enableMudskipperForCse":true,"_fixCtcLinksOnIos":true,"_googEnableQup":true,"_useServerProvidedDomain":true,"_waitOnConsentForFirstPartyCookie":true,"enableEnhancedTargetingRsonc":true,"enableNonblockingSasCookie":true},mdp:1800000,ssdl:"YXBwc3BvdC5jb20sYmxvZ3Nwb3QuY29tLGJyLmNvbSxjby5jb20sY2xvdWRmcm9udC5uZXQsZXUuY29tLGhvcHRvLm9yZyxpbi5uZXQsdHJhbnNsYXRlLmdvb2csdWsuY29tLHVzLmNvbSx3ZWIuYXBw",rsm:10}};/*
Copyright The Closure Library Authors.
SPDX-License-Identifier: Apache-2.0
*/
var m;function aa(a){var b=0;return function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}}}var ba="function"==typeof Object.defi
@fokklz
fokklz / vivaldi.md
Created August 15, 2023 10:14
Secure Browsing 2023

Secure Browsing

Im digitalen Zeitalter von 2023 steht die Sicherheit und Individualität beim Surfen im Internet an oberster Stelle. Dieser Guide soll helfen den Browser richtig zu konfigurieren.

Wieso Vivaldi

Der Vivaldi-Browser hebt sich in dieser Hinsicht deutlich von der Masse ab. Er ist nicht nur leistungsstark und individuell anpassbar, sondern legt auch großen Wert auf den Schutz der Privatsphäre seiner Nutzer. Ohne das Verhalten der Nutzer zu verfolgen, bietet Vivaldi eine intuitive Navigation mit umfassendem Tab-Management und eine Fülle von personalisierbaren Einstellungen. Hinzu kommen integrierte Tools, die den Bedarf an Drittanbieter-Apps reduzieren und gleichzeitig die Sicherheit erhöhen. Und mit der nahtlosen Synchronisation über alle Geräte hinweg bleibt Vivaldi stets aktuell und schützt Ihre Daten mit Ende-zu-Ende-Verschlüsselung. Kurz gesagt, für alle, die Wert auf Privatsphäre, Personalisierung und leistungsstarke Funktionen legen, ist Vivaldi die erste Wahl.

Einrichtung von Vival

@fokklz
fokklz / commands.md
Created August 7, 2023 21:09
Debian Shell Command

Reset SystemD (DNS)

systemctl disable --now systemd-resolved
rm -rf /etc/resolv.conf
ln -sf /run/systemd/resolve/stub-resolv.conf /etc/resolv.conf
sudo systemctl restart systemd-resolved

||also github hat kein markdown||

Spoiler So geht es ursprünglich in Markdown. Discord hat es nur einfacher gestaltet
function ValidateUsername {
param(
[Parameter(Position = 0)]
[string]$Username
)
$onlyLetters = "[a-zA-Z]"
$blacklist = @("admin", "administrator")
if($Username -notmatch $onlyLetters){
function Write-Out {
param(
[Parameter(Mandatory = $true, Position = 0)]
[string]$Message,
[string]$Type = "INFO",
[switch]$LogOnly,
[switch]$ForceWriteLog,
[Parameter(ValueFromRemainingArguments = $true)]
$highlighted
)
import keyboard
import time
import pydirectinput
time.sleep(6)
print('Gooo!')
pydirectinput.keyDown('w')
pydirectinput.keyDown('shift')
int hpa_to_scale(float hpa_value) {
// Define the range of HPA values that will correspond to the 1-10 scale
float min_hpa = 950.0;
float max_hpa = 1030.0;
// Normalize the HPA value to fall within the defined range
float normalized_hpa = fmax(fmin(hpa_value, max_hpa), min_hpa);
// Scale the normalized HPA value to the 1-10 range
int scale_value = round((normalized_hpa - min_hpa) * 10.0 / (max_hpa - min_hpa) + 1.0);