Skip to content

Instantly share code, notes, and snippets.

View pubkey's full-sized avatar
🤯
You don't need a backend

Daniel Meyer pubkey

🤯
You don't need a backend
View GitHub Profile
/**
* Copy this file to the root of the RxDB repository
* so that the import paths are correct.
*/
import {
createRxDatabase,
randomCouchString,
requestIdlePromise
@pubkey
pubkey / linux-ultrawide-60-hz.txt
Created May 9, 2020 13:39
ultrawide screen with linux mint 60hz
# I bought the U3419W but the default refresh rate was set to 30hz.
# I wanted 60 hz but HDMI 1.4 has a too low bandwidth for 3440x1440 with 60hz
# Maximum is 2560x1080_60
# Set this with xrandr with these commands
cvt 2560 1080 60 # Output of this is used in the --newmode command
xrandr --newmode "2560x1080_60.00" 230.00 2560 2720 2992 3424 1080 1083 1093 1120 -hsync +vsync
xrandr --addmode HDMI-1-2 "2560x1080_60.00"
xrandr --output HDMI-1-2 --mode "2560x1080_60.00" # --left-of "eDP-1-1"
@pubkey
pubkey / new_linux_server.bash
Last active July 3, 2017 17:17
new_linux_server.bash
apt-get update
apt-get upgrade -y
apt-get dist-upgrade -y
# choo choo!
apt-get install sl -y
apt-get install wget -y
apt-get install curl -y
apt-get install htop -y
@pubkey
pubkey / linux_mint_update_error.md
Last active February 9, 2017 10:34
If you have Linux mint and cant upgrade because your /boot/ is full, do this

Error-Message: Errors were encountered while processing: linux-image-extra-4.4.0-62-generic

Fix:

  • uname -a to check which kernel you currently use
  • ls /boot/ to show the kernels on the system

You can now remove all not-used kernels. For example if you have vmlinuz-4.4.0-51-generic on /boot/,

@pubkey
pubkey / corsair_headset_linux.bash
Last active October 31, 2024 00:06
Corsair Gaming VOID Headset on Linux
# Corsair headsets will stuck the apps on your linux system. This is due to wrong usb-mapping.
# thx to http://www.c0urier.net/2016/corsair-gaming-void-usb-rgb-linux-fun
# 1. open terminal
# 2. type this and search the line with your headset
lsusb
# Get the USB ID of the headset and add it to xorg.conf:
#@link http://askubuntu.com/questions/475764/docker-io-dns-doesnt-work-its-trying-to-use-8-8-8-8
nano /etc/default/docker
docker_OPTS="--dns 127.0.0.1"
nano /etc/NetworkManager/NetworkManager.conf
#dns=dnsmasq
service network-manager restart
service docker restart
#run all via:
# wget -O - https://gist.githubusercontent.com/pubkey/27083b667698b8d7b32bbcb0d413f78b/raw/6a2a75097112f1c4d25800cf03c7de025663fd17/new_linux.bash | bash
apt-get update
apt-get upgrade -y
apt-get dist-upgrade -y
# choo choo!
#show mounted drives
df -h
#overwrite drive with zeros
sudo dd if=/dev/zero of=/dev/xxx bs=1M
#regulary show state of last dd-command
watch -n5 'sudo kill -USR1 $(pgrep ^dd)'
@pubkey
pubkey / Mad_Catz_linux.bash
Last active January 18, 2024 09:44
Mad Catz R.A.T. 7/9 on Linux ubuntu/mint
#The mouse will suck on linux because of the programmable buttons.
#This script will change the button-delegation so that the mouse doesn't stuck.
#@link https://community.linuxmint.com/hardware/view/10217
sudo mkdir /etc/X11/xorg.conf.d
sudo rm /etc/X11/xorg.conf.d/910-rat.conf
# add the following to the file
echo "Section \"InputClass\"" >> /etc/X11/xorg.conf.d/910-rat.conf
@pubkey
pubkey / gist:b7ca0e930c9fdc4cac0e
Created February 2, 2016 08:30
linux mint persistent brightness
# 1. put this in any .sh script
# 2. open 'gnome-session-properties' via cmd ( linux autostart )
# 3. add this script
pkexec /usr/lib/gnome-settings-daemon/gsd-backlight-helper --set-brightness 100