Skip to content

Instantly share code, notes, and snippets.

View anxkhn's full-sized avatar
🚀
tinkering...

Anas Khan anxkhn

🚀
tinkering...
View GitHub Profile
@anxkhn
anxkhn / linux-kernel-codenames.md
Last active June 12, 2026 13:03
Linux Kernel Makefile Codenames (extracted from torvalds/linux git)

Linux Kernel Makefile Codenames

Source: Extracted directly from torvalds/linux git repository + historical RC-level codenames.

Kernel Version / RC Tag Official Codename Context / Backstory
2.6.1 (none) Pre-codename era
2.6.2 – 2.6.4 Feisty Dunnart Early 2.6 codename
2.6.5 – 2.6.9 Zonked Quokka "Quokka" appears here (RC-era)
2.6.10-rc1 – 2.6.13 Woozy Numbat Australian marsupial theme

ffmpeg -i video1.mov -i video2.mkv -filter_complex "[0:v][0:a][1:v][1:a]concat=n=2:v=1:a=1" output.mp4

@anxkhn
anxkhn / tailscale-gnome-toggle-howto.md
Created May 1, 2026 13:53
GNOME Quick Settings Tailscale on/off toggle extension

GNOME Quick Settings Tailscale Toggle

This guide creates a small GNOME Shell extension that adds a Tailscale on/off button to the top-right Quick Settings menu, near Wi-Fi, Bluetooth, and VPN controls.

The toggle runs:

sudo -n tailscale up
sudo -n tailscale down
tailscale status --json
@anxkhn
anxkhn / tailscale-gnome-toggle-howto.md
Created May 1, 2026 13:51
GNOME Quick Settings Tailscale on/off toggle extension

GNOME Quick Settings Tailscale Toggle

This guide creates a small GNOME Shell extension that adds a Tailscale on/off button to the top-right Quick Settings menu, near Wi-Fi, Bluetooth, and VPN controls.

The toggle runs:

sudo -n tailscale up
sudo -n tailscale down
tailscale status --json
# DSA Question Bank
## Arrays, Hashing, Prefix/Suffix
1. Find the second largest element in one pass without extra space.
2. Find the k largest distinct elements without fully sorting the array.
3. Find the two numbers that appear once when every other number appears twice.
4. Find the majority element that appears more than n / 2 times.
5. Find all elements that appear more than n / 3 times.
6. Count inversions in an array.
@anxkhn
anxkhn / HP_1020_MacOS_Guide.md
Last active June 24, 2026 23:07
HP LaserJet 1020 on Modern macOS

HP LaserJet 1020 on Modern macOS (Ventura / Sonoma / Sequoia / macOS 26)

Note

A simpler, community-maintained, self-contained repository with all steps is now available:
https://github.com/anxkhn/hp1020-driver-mac

It is only ~4 MB compared to ~500+ MB for the Apple driver package used below.

HP never released official drivers for the LaserJet 1020 on modern macOS. This guide patches Apple's HP driver package to bypass the OS version block and uses the compatible LaserJet 1022 PPD.

Quickstart: GLM-4.6V-Flash with mlx-vlm on macOS (Apple Silicon)

This guide walks you through setting up a minimal project that uses mlx-vlm to run the

mlx-community/GLM-4.6V-Flash-4bit vision model on a sample image.

1. Install uv (if not installed)

@anxkhn
anxkhn / VSCode_Marketplace_Tutorial.md
Last active June 26, 2026 19:31
Enable Marketplace on non MS VSCode Forks.

Enabling VS Code Marketplace in VSCodium and Trae

Microsoft claims Visual Studio Code (VS Code) is open source, yet it restricts the use of its Marketplace extensions in non-Microsoft products like VSCodium (telemetry/tracking free open source fork), Cursor, Windsurf, Trae, and other VS Code-based IDEs, enforcing what some see as monopolistic control. This guide provides a workaround to enable the VS Code Marketplace in VSCodium and Trae (more to be added soon), allowing you to freely use extensions. Note that using the VS Code Marketplace with non-Microsoft products may violate its terms of use, which state that extensions are intended for use only with Microsoft Visual Studio products. Proceed at your discretion after reviewing the terms.


Enabling VS Code Marketplace in VSCodium

To configure VSCodium to use the VS Code Marketplace instead of the default OpenVSX Registry, you can either set environment variables or create a custom product.json file.

Cursor AI IDE Installation Guide

Cursor AI is a modern AI-driven IDE that boosts productivity for developers. This guide demonstrates how to install Cursor on your Linux system using a one-liner command. The script will handle dependencies, download the Cursor AppImage, and create a convenient desktop launcher.


Prerequisites

Ensure you have curl installed on your system. If not, the script will install it for you.

Run these.

sudo apt update -y
sudo apt upgrade -y
sudo apt install gcc make libssl-dev libreadline-dev zlib1g-dev libsqlite3-dev libyaml-dev
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
~/.rbenv/bin/rbenv init
eval "$(~/.rbenv/bin/rbenv init - zsh)"
mkdir -p "$(rbenv root)"/plugins
git clone https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build