Skip to content

Instantly share code, notes, and snippets.

View xmawja's full-sized avatar
🎯
Focusing

Muja Siyam xmawja

🎯
Focusing
View GitHub Profile
@xmawja
xmawja / GitCommitEmoji.md
Created November 9, 2023 02:02 — forked from parmentf/GitCommitEmoji.md
Git Commit message Emoji
@xmawja
xmawja / qemu-networking.md
Created September 19, 2023 20:00 — forked from extremecoders-re/qemu-networking.md
Setting up Qemu with a tap interface

Setting up Qemu with a tap interface

There are two parts to networking within QEMU:

  • The virtual network device that is provided to the guest (e.g. a PCI network card).
  • The network backend that interacts with the emulated NIC (e.g. puts packets onto the host's network).

Example: User mode network

@xmawja
xmawja / networks.conf
Created September 12, 2023 14:28
VirtualBox - Failed to change host network interface parameter.
On Linux, Mac OS X and Solaris Oracle VM VirtualBox will only allow IP addresses in 192.68.56.0/21 range
to be assigned to host-only adapters.
For IPv6 only link-local addresses are allowed.
If other ranges are desired,
they can be enabled by creating /etc/vbox/networks.conf and specifying allowed ranges there.
For example, to allow 10.0.0.0/8 and 192.168.0.0/16 IPv4 ranges as well as 2001::/64 range
put the following lines into /etc/vbox/networks.conf:
* 10.0.0.0/8 192.168.0.0/16
@xmawja
xmawja / colors.sh
Last active April 22, 2023 12:36
Hex code terminal colors
#!/bin/bash
#Based on post at:
#http://www.reddit.com/r/linux/comments/qagsu/easy_colors_for_shell_scripts_color_library/
RCol='\e[0m' # Text Reset
# Regular Bold Underline High Intensity BoldHigh Intens Background High Intensity Backgrounds
Bla='\e[0;30m'; BBla='\e[1;30m'; UBla='\e[4;30m'; IBla='\e[0;90m'; BIBla='\e[1;90m'; On_Bla='\e[40m'; On_IBla='\e[0;100m';
Red='\e[0;31m'; BRed='\e[1;31m'; URed='\e[4;31m'; IRed='\e[0;91m'; BIRed='\e[1;91m'; On_Red='\e[41m'; On_IRed='\e[0;101m';
Gre='\e[0;32m'; BGre='\e[1;32m'; UGre='\e[4;32m'; IGre='\e[0;92m'; BIGre='\e[1;92m'; On_Gre='\e[42m'; On_IGre='\e[0;102m';
@xmawja
xmawja / 00_ST_Clone_Make.sh
Last active November 19, 2022 01:14
A Customized Build Of st terminal and applied some useful PATCHES.
!#/bin/sh
# A Customized Build Of st terminal and applied some useful PATCHES.
## https://st.suckless.org/
###################################################
# PATCHES! be aware of the version's
## https://st.suckless.org/patches/scrollback
# using GIT clone the repo && change the directory
git clone https://git.suckless.org/st
cd cd
@xmawja
xmawja / 00_Clone_Make.sh
Last active November 18, 2022 11:32
A customized build of dynamic window manager, on top of DWM.
!#/bin/sh
# A Customized Build Of DWM and applyed some usefol PATCHES
## https://dwm.suckless.org/
## https://dwm.suckless.org/faq/
###################################################
# PATCHES! be aware of the version's
## https://dwm.suckless.org/patches/pertag/
## https://dwm.suckless.org/patches/fullgaps/
## https://dwm.suckless.org/patches/movestack/
@xmawja
xmawja / 00_Partition_BTRFS_Disk.sh
Last active May 3, 2025 19:00
Gentoo BTRFS Installation Guide - How To Install Gentoo On BTRFS
#!/bin/sh
# Gentoo BTRFS Installation Guide
# First Step You Need to boot From Gentoo Live Cd
## reference https://gist.github.com/renich/90e0a5bed8c7c0de40d40ac9ccac6dfd
####################################################
# Partition Your Disks
# referenses https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Disks#Partitioning_the_disk_with_GPT_for_UEFI
# Print Partions That Attached TO Your System
@xmawja
xmawja / asound.conf
Last active June 15, 2023 17:58
Setting the default device sound card alsa/pulsausio/pipewire on gnu/linux
## check available sound card that attached to your system.
# cat /proc/asound/cards
## or better check card name to use insted of card number.
# cat /sys/class/sound/card*/id
## guide https://wiki.gentoo.org/wiki/ALSA#.7E.2F.asoundrc
# verification used driver
LANG=C pactl info | grep "Server Name"
# add user to audio group
@xmawja
xmawja / neovim-build.sh
Created May 17, 2022 18:53
NEOVIM text editor build from source.
#!/usr/bin/env bash
#Build and install neovim for Debian
#See: https://neovim.io/
#See: https://github.com/neovim/neovim/wiki/Building-Neovim#quick-start
#See: https://gist.github.com/darcyparker/153124662b05c679c417
#Save current dir
pushd . > /dev/null || exit
@xmawja
xmawja / Nginx-Default-Sites-Available.Conf
Created April 24, 2022 08:52
Nginx Default Sites-Available Configuration
##
# You should look at the following URL's in order to grasp a solid understanding
# of Nginx configuration files in order to fully unleash the power of Nginx.
# http://wiki.nginx.org/Pitfalls
# http://wiki.nginx.org/QuickStart
# http://wiki.nginx.org/Configuration
#
# Generally, you will want to move this file somewhere, and start with a clean
# file but keep this around for reference. Or just disable in sites-enabled.
#