Skip to content

Instantly share code, notes, and snippets.

View SmartFinn's full-sized avatar
🇺🇦

Serhii Yeremenko SmartFinn

🇺🇦
  • Ukraine
  • 12:11 (UTC +03:00)
View GitHub Profile
@jacky9813
jacky9813 / install-nv-driver-fc41.md
Created October 31, 2024 01:47
Install NVIDIA proprietary driver on Fedora 41

There are some steps that is not documented in the RPMFusion's installation guide. Here's how I install NVIDIA driver on Fedora 41.

  1. Update all packages and reboot
  2. Install akmod-nvidia from RPMFusion, optionally with packages for CUDA or NVENC.
  3. For some reason, after akmod installation, I didn't see modeset=1 on kernel option, so:
#!/bin/bash
@coderofsalvation
coderofsalvation / app.sh
Last active February 9, 2025 16:48
podman rootless forgejo actions setup
#!/bin/sh
# below is based on this forgejo actions admin guide: https://forgejo.codeberg.page/docs/v1.20/admin/actions/
PORT=8621
TOKEN=XXXXXXX_REPLACE_TOKEN_HERE_XXXXXXXX
URL=https://yourinstancehere.org
UID=`id -u`
docker=`which docker || which podman`
test -d data || mkdir data
@galaxia4Eva
galaxia4Eva / kitty+page.lua
Last active March 25, 2025 12:52
nvim pager for kitty history
return function(INPUT_LINE_NUMBER, CURSOR_LINE, CURSOR_COLUMN)
print('kitty sent:', INPUT_LINE_NUMBER, CURSOR_LINE, CURSOR_COLUMN)
vim.opt.encoding='utf-8'
vim.opt.clipboard = 'unnamed'
vim.opt.compatible = false
vim.opt.number = false
vim.opt.relativenumber = false
vim.opt.termguicolors = true
vim.opt.showmode = false
vim.opt.ruler = false
@sebastiancarlos
sebastiancarlos / shelloptions.sh
Last active December 15, 2024 18:42
shelloptions - combine output of "set -o" and "shopt", thereby showing all Bash options in one place
# All my gist code is licensed under the terms of the MIT license.
# Video demo: https://www.youtube.com/watch?v=eN4_nmREzCQ
# copy this to your .bashrc or something like that
# shelloptions
# combine output of "bind -V", "set -o" and "shopt", thereby showing all shell
# options in one place. Display nicely with color and column alignment.
#
# -*- coding: utf-8 -*-
# pylint: disable=consider-using-f-string,invalid-name,line-too-long,super-with-arguments
'''
Ranger color-scheme using `$LS_COLORS` / `dircolors`.
Originally based on: https://github.com/ranger/colorschemes/raw/a250fe866200940eb06d877a274333a2a54c34f3/ls_colors.py
Usage: copy this file to `~/.config/ranger/colorschemes'. The base color-scheme
used for non file system entries / the unfocused pane is `default`. To change it,

ZSH CheatSheet

This is a cheat sheet for how to perform various actions to ZSH, which can be tricky to find on the web as the syntax is not intuitive and it is generally not very well-documented.

Strings

Description Syntax
Get the length of a string ${#VARNAME}
Get a single character ${VARNAME[index]}
@cihanmehmet
cihanmehmet / password-wordlist.txt
Created November 19, 2020 11:34
Password Wordlist(235k)
This file has been truncated, but you can view the full file.
password
princess
123456
sunshine
princess1
abc123
jordan23
blessed1
Password1
password1
@Atavic
Atavic / Firefox Zero user.js
Last active February 14, 2023 13:05
rev20210116
// Firefox Zero user.js
// rev20210116
// Privacy & Local Storage
user_pref("browser.bookmarks.max_backups", 0); // No bookmarks backup
user_pref("browser.cache.disk.enable", false); // Disable disk cache
user_pref("browser.cache.offline.enable", false); // Disable offline cache
user_pref("browser.messaging-system.whatsNewPanel.enabled", false);
user_pref("browser.newtabpage.activity-stream.asrouter.userprefs.cfr.addons", false);
user_pref("browser.newtabpage.activity-stream.asrouter.userprefs.cfr.features", false);
@mollymerp
mollymerp / sshfs-gcp-instance-osx.md
Last active January 10, 2024 14:52
How to mount a GCP compute instance filesystem locally using `sshfs` on MacOS

How to mount a GCP compute instance filesystem locally using sshfs

This guide assumes that:

  • you already have an instance set up on GCP that you want to mount locally
  • the GCP CLI (gcloud) is installed on your local machine
  • you have authenticated locally to your google account gcloud auth login
  1. make sure your gcloud config is correct for the instance you're trying to access:
@krisleech
krisleech / renew-gpgkey.md
Last active April 21, 2025 11:05
Renew Expired GPG key

Renew GPG key

Given that your key has expired.

$ gpg --list-keys
$ gpg --edit-key KEYID

Use the expire command to set a new expire date: