Skip to content

Instantly share code, notes, and snippets.

View olealgoritme's full-sized avatar
🐧
vim >

Ole Algoritme olealgoritme

🐧
vim >
View GitHub Profile
@olealgoritme
olealgoritme / The Technical Interview Cheat Sheet.md
Created September 7, 2020 17:52 — forked from tsiege/The Technical Interview Cheat Sheet.md
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!






\

@olealgoritme
olealgoritme / ffmpeg-livestream-to-streaming-sites-vaapi-nvenc.md
Created April 26, 2020 20:35 — forked from Brainiarc7/ffmpeg-livestream-to-streaming-sites-vaapi-nvenc.md
ffmpeg livestreaming to youtube via Nvidia's NVENC and Intel's VAAPI on supported hardware

Streaming your Linux desktop to Youtube and Twitch via Nvidia's NVENC and VAAPI:

Considerations to take when live streaming:

The following best practice observations apply when using a hardware-based encoder for live streaming to any platform:

  1. Set the buffer size (-bufsize:v) equal to the target bitrate (-b:v). You want to ensure that you're encoding in CBR mode.

  2. Set up the encoders as shown:

@olealgoritme
olealgoritme / compile_newest_stable_kernel_with_acso_patch.sh
Created January 26, 2019 15:08 — forked from mdPlusPlus/compile_newest_stable_kernel_with_acso_patch.sh
Download, patch, compile and install the newest stable Linux kernel with the ACS override patch (Ubuntu / Debian)
#!/bin/bash
function install_dependencies() {
echo "Installing dependencies..."
sudo apt -qq update
sudo apt -qq install -y curl git wget
sudo apt -qq install -y bison flex kernel-package libssl-dev
}
function init() {
@olealgoritme
olealgoritme / clean-up-boot-partition-ubuntu.md
Created January 23, 2019 00:04 — forked from ipbastola/clean-up-boot-partition-ubuntu.md
Safest way to clean up boot partition - Ubuntu 14.04LTS-x64, Ubuntu 16.04LTS-x64

Safest way to clean up boot partition - Ubuntu 14.04LTS-x64, Ubuntu 16.04LTS-x64

Reference

Case I: if /boot is not 100% full and apt is working

1. Check the current kernel version

$ uname -r 
@olealgoritme
olealgoritme / huaiwei-unlock.py
Created December 21, 2018 04:07 — forked from DonnchaC/huaiwei-unlock.py
Huaiwei unlock code generator - Based on the disassembler generated C code in https://github.com/forth32/huaweicalc
#!/usr/bin/python
# -*- coding: utf-8 -*-
import os
import hashlib
import argparse
import binascii
import struct
def encrypt_v1(imei, key):
uint16_t udp_checksum(struct udphdr *p_udp_header, size_t len, uint32_t src_addr, uint32_t dest_addr)
{
const uint16_t *buf = (const uint16_t*)p_udp_header;
uint16_t *ip_src = (void*)&src_addr, *ip_dst = (void*)&dest_addr;
uint32_t sum;
size_t length = len;
// Calculate the sum
sum = 0;
while (len > 1)
@olealgoritme
olealgoritme / LICENCE SUBLIME TEXT
Created November 20, 2018 11:30
Sublime Text 3 Serial key build is 3176
## Sublime Text 3 Serial key build is 3176
> * Added these lines into /etc/hosts
127.0.0.1 www.sublimetext.com
127.0.0.1 license.sublimehq.com
> * Used the license key
----- BEGIN LICENSE -----
I use the first
—– BEGIN LICENSE —–
Michael Barnes
Single User License
EA7E-821385
8A353C41 872A0D5C DF9B2950 AFF6F667
C458EA6D 8EA3C286 98D1D650 131A97AB
AA919AEC EF20E143 B361B1E7 4C8B7F04
@olealgoritme
olealgoritme / fix-surface-pro-pen.sh
Created September 12, 2018 01:16 — forked from nonameentername/fix-surface-pro-pen.sh
Update Surface Pro in Ubuntu to support pen pressure sensitivity using the wacom drivers.
#!/bin/bash
#load wacom driver
sudo modprobe wacom
#unbind touch screen
echo 2-1.6:1.0 | sudo tee /sys/bus/usb/drivers/usbhid/unbind
#unbind pen
echo 2-1.5:1.1 | sudo tee /sys/bus/usb/drivers/usbhid/unbind
@olealgoritme
olealgoritme / install.md
Created June 21, 2018 20:44 — forked from floehopper/install.md
Install rtl-sdr on Raspian on Raspberry Pi
jamesmead@floehopper.local:~$ sudo dd bs=1m if=/Users/jamesmead/Downloads/2015-02-16-raspbian-wheezy.img of=/dev/disk2
pi@raspberrypi ~ $ sudo raspi-config
# Choose option 1 to "Expand Filesystem" - Ensures that all of the SD card storage is available to the OS
# Choose Finish & reboot

pi@raspberrypi ~ $ sudo apt-get update