Skip to content

Instantly share code, notes, and snippets.

View LeoVerto's full-sized avatar

Leo Verto LeoVerto

View GitHub Profile
@sbinlondon
sbinlondon / synthwaveglow.md
Last active February 22, 2024 22:40
Get the synth wave glow theme working for VS Code on Mac

Get the synth wave glow working for VS Code on Mac

These notes are pretty much the same steps as the two extensions list, it's just that I had to collate them together because neither seems to list it fully in the proper order.

  1. Install Synthwave ’84/Synthwave + Fluoromachine theme on VS Code (I used the Fluoromachine one)

  2. Install Custom CSS and JS Loader

  3. Command + Shift + P to open command palette > "Preferences: Open settings (JSON)"

@hacker1024
hacker1024 / nvidia-gpu-sensor.pl
Last active December 8, 2023 10:33
KDE KSysGuard NVIDIA GPU temperature/memory/utilization sensor, based on @frantic1048's script, but with units and total memory detection.
#!/usr/bin/perl -w
# act as a KSysGuard sensor
# provides NVIDIA GPU info via `nvidia-settings`
# Usage (e.g. add gpu temperature sensor)
# 1. save this file, make sure it has a exec permission
# 2. in KSysGuard's menu, open `File` -> `Monitor Remote Machine`
# 3.1 in new dialog, type `Host` whatever you want
# 3.2 set `Connection Type` to `Custom command`
@literalplus
literalplus / 0_Grafana_Annotations_Bash.md
Last active July 4, 2019 14:26
Collection of Bash scripts to simplify publishing annotations to Grafana.

Grafana Annotations via Bash scripts

Ever wanted to annotate Grafana panels with when your backups are executed or whatever? Have some possibly useful scripts. These create region annotations, so you're supposed to call the script again with the update operation to set the end time. If you don't, they will be zero-length, which does look a little weird in the interface. Alternatively, you can just change isRegion to false. Note that it really does need the full annotation JSON to update because Grafana replaces the document entirely. If we were to only send the new end time, all other info (description, etc.) would be deleted.

Also, you need to have jq installed for this to work.

#!/bin/sh
set -e
RED='\033[0;31m'
GREEN='\033[0;32m'
BLUE='\033[0;34m'
NC='\033[0m'
mkdir -p log
echo -e "${GREEN}Checking for wine...${NC}"
from django.contrib.admin import ModelAdmin
class MyTableAdmin(ModelAdmin):
...
paginator = LargeTablePaginator
...
@vifino
vifino / steam-in-home-streaming
Created March 2, 2016 21:13
Steam In-Home streaming UFW Profile
[steam-in-home-streaming]
title=Steam-In-Home-Streaming
description=Steam In-Home Streaming
ports=27031/udp|27036/udp|27036/tcp|27037/tcp
@Overdrivr
Overdrivr / Plot.py
Last active October 25, 2023 12:49
Reads data from a thread, plots it in another Process, with main process being free all the time ! Using PyQtGraph, python standard multiprocessing and multiprocessing.Queue
# -*- coding: utf-8 -*-
from pyqtgraph.Qt import QtGui, QtCore
import numpy as np
import pyqtgraph as pg
from multiprocessing import Process, Manager, Queue
import sched, time, threading
# This function is responsible for displaying the data
# it is run in its own process to liberate main process
def display(name,q):
@renchap
renchap / README.md
Last active October 12, 2022 17:14
One-line certificate generation/renews with Letsencrypt and nginx

Prerequisites : the letsencrypt CLI tool

This method allows your to generate and renew your Lets Encrypt certificates with 1 command. This is easily automatable to renew each 60 days, as advised.

You need nginx to answer on port 80 on all the domains you want a certificate for. Then you need to serve the challenge used by letsencrypt on /.well-known/acme-challenge. Then we invoke the letsencrypt command, telling the tool to write the challenge files in the directory we used as a root in the nginx configuration.

I redirect all HTTP requests on HTTPS, so my nginx config looks like :

server {
@tsiege
tsiege / The Technical Interview Cheat Sheet.md
Last active April 16, 2024 23:05
This is my technical interview cheat sheet. Feel free to fork it or do whatever you want with it. PLEASE let me know if there are any errors or if anything crucial is missing. I will add more links soon.

ANNOUNCEMENT

I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!






\