Skip to content

Instantly share code, notes, and snippets.

View bgeneto's full-sized avatar
🏠
Working from home

Bernhard Enders bgeneto

🏠
Working from home
View GitHub Profile
@Diegiwg
Diegiwg / !_example.py
Last active April 23, 2024 21:07
Script that automatically generates styling classes to apply to NiceGUI elements, using the Tailwind system
from Typography import Typography
from Backgrounds import Backgrounds
from Sizing import Sizing
from nicegui import ui
# STYLE LIB
s_title = (
Typography()
.text_color("text-teal-600")
@SomajitDey
SomajitDey / install_ifort_ifx.md
Last active May 4, 2024 08:04
Install INTEL Fortran compiler ifort for free on Ubuntu(WSL2). Also install MKL. OpenMP and OpenMPI runtime for coarray support.

My route:

  1. curl -Lo- https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB | sudo gpg --dearmor -o /usr/share/keyrings/oneapi-archive-keyring.gpg
  2. sudo tee /etc/apt/sources.list.d/oneAPI.list <<< "deb [signed-by=/usr/share/keyrings/oneapi-archive-keyring.gpg] https://apt.repos.intel.com/oneapi all main"
  3. sudo apt update
@AnthonyWharton
AnthonyWharton / automatedManualCertbotRenewal.sh
Last active April 12, 2024 02:23
FreeDNS (afraid.org) Cerbot/Let's Encrypt Manual Automation Script
#!/bin/bash
# Copyright 2018, Anthony Wharton
# Single script that can be called that generates certificates using the
# certbotFreeDNSAuthHook.sh and certbotFreeDNSCleanupHook.sh scripts.
# This should be used as guidence of my usage, and changed to your needs. Note
# the generic `/path/to/...` and `DOMAIN.COM`, which should be replaced with
# your script location and domain respectively. In addition, for this to be
# used on a live system, one must remove the `--dry-run` flag.
@guettli
guettli / ssh-tunnel@.service
Created December 22, 2017 11:40
Reliable persistent SSH-Tunnel via systemd (not autossh)
# Reliable persistent SSH-Tunnel via systemd (not autossh)
# https://gist.github.com/guettli/31242c61f00e365bbf5ed08d09cdc006#file-ssh-tunnel-service
[Unit]
Description=Tunnel for %i
After=network.target
[Service]
User=tunnel
ExecStart=/usr/bin/ssh -o "ExitOnForwardFailure yes" -o "ServerAliveInterval 60" -N tunnel@%i