Skip to content

Instantly share code, notes, and snippets.

View mizzunet's full-sized avatar
👀
Rookie

MSHB mizzunet

👀
Rookie
  • Black Hole
View GitHub Profile
@mizzunet
mizzunet / gist:69703175a4bf687f8eafedae88f8eda8
Created November 9, 2021 20:03
Enable ADB and Wireless ADB from TWRP
```
adb shell
mount system
echo '' >> /system/build.prop
echo '# Enable ADB' >> /system/build.prop
echo 'persist.service.adb.enable=1' >> build.prop
echo 'persist.service.debuggable=1' >> build.prop
echo 'persist.sys.usb.config=mtp,adb' >> build.prop
echo 'service.adb.tcp.port=5555' >> build.prop
```
@mizzunet
mizzunet / blur.sh
Created March 14, 2022 17:37
Blur Wallpaper on SwayWM using `oguri`
#!/bin/bash
# <Constants>
cache_dir="$HOME/.cache/wallblur"
display_resolution=$(swaymsg -pt get_outputs | grep Current | awk '{print $3}')
# </Constants>
# <Functions>
err() {
@mizzunet
mizzunet / 1. Key Binding
Last active March 14, 2022 19:49
Vimium C
unmapAll
# Navigating the page
map j scrollDown count=2
map k scrollUp count=2
map G scrollToBottom
map gg scrollToTop
map e scrollPageUp
map d scrollPageDown
map h scrollLeft
@mizzunet
mizzunet / 1. config
Last active March 14, 2022 19:53
SwayWM Configuration
# variables
set $mod Mod4
set $left h
set $down j
set $up k
set $right l
set $menu sirula
set $files nemo
set $browser librewolf
@mizzunet
mizzunet / config
Created March 14, 2022 19:54
Waybar Configuration
{
"layer": "top", // Waybar at top layer
"position": "top", // Waybar at the bottom of your screen
"height": 32, // Waybar height
"modules-left": ["sway/workspaces","sway/mode"],
"modules-center": ["clock",],
"modules-right": ["keyboard-state","custom/protonmail","network","pulseaudio", "battery", "tray"],
"sway/workspaces": {
"icon": false,
"disable-scroll": true,
@mizzunet
mizzunet / data.json
Created March 15, 2022 07:12
Find fastest instance. Invidious, Nitter, Searx, Wikiless, Scribe etc
## First get json of instances
You may get this from LibRedirect extension repo
https://github.com/libredirect/libredirect/tree/master/src/instances
@mizzunet
mizzunet / fastserver.sh
Last active March 16, 2022 08:15
Find fastest instance
#!/bin/bash
echo -n "Possible Values: invidious nitter bibliogram teddit wikiless scribe simplyTranslate lingva searx whoogle rimgo" \n
instances="$@"
listurl="https://raw.githubusercontent.com/tillcash/libredirect/master/src/instances/data.json"
tmpfile="/tmp/output"
# Download list
if test -f data.json; then
echo \n data.json already exists\n, using it \n
@mizzunet
mizzunet / ping.sh
Created April 15, 2022 01:28
Ping multple servers and sort
#!/bin/bash
o=output
cap=10
for server in $(cat servers)
do
ping=$(ping "$server" -c $cap)
avg=$(echo $ping| grep avg | cut -d'/' -f 5)
if [[ "$avg" != "" ]]; then
@mizzunet
mizzunet / setup.md
Last active October 18, 2024 04:03
Setup Squid Cache Proxy on Arch Linux

Installation

$ yay -S squid

Open firewall

# iptables -L -n -v | grep 3128
    0     0 ACCEPT     tcp  --  *      *       192.168.1.0/24       0.0.0.0/0            state NEW tcp dpt:3128

Generate a CA Certificate to be used by Squid

@mizzunet
mizzunet / memos-nodocker.md
Created February 9, 2023 04:24
Setup Memos server manually without Docker

1. Clone repository

git clone https://github.com/usememos/memos

2. Set working directly

Change profile.Data from memos/server/profile/profile.go (line 60) to your desired directly (/opt/memos)

3. Setup frontend

cd memos/web
yarn &amp;&amp; yarn build