First of all, you need to have AwesomeWM installed and running.
I'm using awesome-git
, the development release.
I'm not sure whether this would work on the stable release.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://github.com/oobabooga/text-generation-webui/blob/main/README.md | |
# https://github.com/oobabooga/text-generation-webui/blob/main/docs/Spell-book.md | |
# by default the Dockerfile specifies these versions: 3.5;5.0;6.0;6.1;7.0;7.5;8.0;8.6+PTX | |
# https://developer.nvidia.com/cuda-gpus you can find the version for your card here | |
# Tesla P100 = sm_60, sm_61, sm_62 and compute_60, compute_61, compute_62 | |
# TORCH_CUDA_ARCH_LIST=6.0,6.1,6.2,7.0,7.5,8.0,8.6+PTX | |
# RTX3090 = sm_86 and compute_86 (PTX) | |
#8.6+PTX | |
# Tesla P100 = sm_60, sm_61, sm_62 and compute_60, compute_61, compute_62 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ctypes | |
import sys | |
assert sys.implementation.name == "cpython" | |
def mussolini(array: list[int]): | |
if not array: | |
return | |
highest = array[0] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
# the metadata only contains the name of the default sink | |
default_sink_name=$(pw-metadata 0 'default.audio.sink' | grep 'value' | sed "s/.* value:'//;s/' type:.*$//;" | jq .name) | |
default_sink_id=$(pw-dump Node Device | jq '.[].info.props|select(."node.name" == '" $default_sink_name "') | ."object.id"') | |
current_volume=$(pw-cli enum-params "$default_sink_id" 'Props' | grep -A 2 'Spa:Pod:Object:Param:Props:channelVolumes' | awk '/Float / {gsub(/.*Float\s/," "); print $1^(1/3) }') | |
change="${1:-0.1}" # defaults to increment of 0.1 | |
new_volume=$(echo "$current_volume $change" | awk '{printf "%f", $1 + $2}') | |
# we need to reconvert to cubic root | |
#new_volume_cube=$(echo "$new_volume" | awk '{ print $1^3 }') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 6c1d401600b76dd7d9c24ca4c6aa8d6e6b54fb05 Mon Sep 17 00:00:00 2001 | |
From: Joan Bruguera <[email protected]> | |
Date: Fri, 16 Apr 2021 09:29:24 +0200 | |
Subject: [PATCH] Tentative fix for NVIDIA 465.27 driver for Linux 5.13-rc1 | |
--- | |
nvidia-drm/nvidia-drm-crtc.c | 23 +++++++++++++++++++++++ | |
1 file changed, 23 insertions(+) | |
diff --git a/nvidia-drm/nvidia-drm-crtc.c b/nvidia-drm/nvidia-drm-crtc.c |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"pactl set-sink-volume @DEFAULT_SINK@ -1000" | |
XF86AudioLowerVolume | |
"pactl set-sink-volume @DEFAULT_SINK@ +1000" | |
XF86AudioRaiseVolume | |
"playerctl play-pause" | |
m:0x0 + c:208 | |
XF86AudioPlay | |
"playerctl play-pause" | |
m:0x0 + c:209 | |
XF86AudioPause |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
"""Python2 f-string like behavior""" | |
from __future__ import print_function | |
import inspect | |
import re | |
class F(object): | |
"""String formatter based on Python 3.6 'f' strings |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://gist.github.com/aallan/b4bb86db86079509e6159810ae9bd3e4 | |
{ | |
"OFFICIALLY XEROX": [ | |
"000000" | |
], | |
"SUPERLAN-2U": [ | |
"000001" | |
], | |
"BBN (WAS INTERNAL USAGE ONLY, NO LONGER USED)": [ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Trigger] | |
Operation = Remove | |
Type = Package | |
Target = * | |
[Action] | |
Description = Clearing cache... | |
When = PostTransaction | |
Exec = /home/<user>/.local/bin/tools/removehook |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def read_nonblocking(path, bufferSize=100, timeout=.100): | |
import time | |
""" | |
implementation of a non-blocking read | |
works with a named pipe or file | |
errno 11 occurs if pipe is still written too, wait until some data | |
is available | |
""" | |
grace = True |
NewerOlder