Skip to content

Instantly share code, notes, and snippets.

View oasido's full-sized avatar
💅

Ofek Asido oasido

💅
View GitHub Profile
@mjackson
mjackson / redirects-in-react-router-v6.md
Last active November 18, 2025 19:38
Notes on handling redirects in React Router v6, including a detailed explanation of how this improves on what we used to do in v4/5

Redirects in React Router v6

An important part of "routing" is handling redirects. Redirects usually happen when you want to preserve an old link and send all the traffic bound for that destination to some new URL so you don't end up with broken links.

The way we recommend handling redirects has changed in React Router v6. This document explains why.

Background

In React Router v4/5 (they have the same API, you can read about why we had to bump the major version here) we had a <Redirect> component that you could use to tell the router when to automatically redirect to another URL. You might have used it like this:

Is It Over Now? (Taylor Taylor Swift
"Slut!" (Taylor's Versi Taylor Swift
Now That We Don't Talk Taylor Swift
Say Don't Go (Taylor's Taylor Swift
I know it won't work Gracie Abrams
Out Of The Blue Jake Scott
Suburban Legends (Taylo Taylor Swift
Living My Best Life Ben Rector
Buy Dirt Jordan Davis & Lu
Feel Something Joshua Bassett
@marcoczen
marcoczen / TroubleShooting-PopOS.txt
Last active April 20, 2023 00:20
PopOS - Some Troubleshooting Commands
::: Some PopOS TroubleShooting Commands - v011 :::
( Mostly curated from posts from the PopOS Telegram Group )
: Apt/Dpkg Package Mgmt :
— sudo apt update
— sudo apt list --upgradable
— sudo apt show package_name
— sudo apt policy package_name
@jwmcgettigan
jwmcgettigan / bitwarden_duplicate_cleaner.py
Last active November 3, 2025 05:21
Identifies and removes duplicate 'items' and 'folders' from your Bitwarden vault. 🎃
#!/usr/bin/env python3
# Copyright © 2023 Justin McGettigan
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software
# and associated documentation files (the “Software”), to deal in the Software without
# restriction, including without limitation the rights to use, copy, modify, merge, publish,
# distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the
# Software is furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all copies or
// page.tsx
import PaginationControls from '@/components/PaginationControls'
import Image from 'next/image'
const data = [
'entry 1',
'entry 2',
'entry 3',
'entry 4',
@Joao-Peterson
Joao-Peterson / gmk67_linux.md
Last active September 11, 2025 18:31
Using GMK67 keyboard in linux. Function keys not working with Fn!

GMK67 with Archlinux!

Recently i bought a zuoya gmk67 keyboard, it doesn't have a function keys row and has a knob for volume control. Unfortunately, if you plug your gmk67 in a archlinux machine you will notice that using fn+1 will not produce f1 as expected, it will produce a screen brightness decrease, and if you change the physical switch in the back for the macOS mode, the function keys now work, but the modifier keys don't, quite stressful.

Fear not, you can either alter your system configuration so the keyboard functions normally, as in this gist, or remap the keys, as seen in the gist Using GMK67 keyboard in linux with key remaps!.

For this gist we are going to alter the configuration for the apple hid driver on archlinux, since this keyboard uses it, and alter the functionality of the Fn key.

This is tested on archlinux, for any other distro you might have to figure out yourself the correponding commands!

@fritz-fritz
fritz-fritz / CMakeUserPresets.json
Last active September 16, 2025 04:47
Custom obs-backgroundremoval build with support for NVIDIA cuda 12 on linux
{
"version": 3,
"cmakeMinimumRequired": {
"major": 3,
"minor": 28,
"patch": 0
},
"configurePresets": [
{
"name": "cuda12",