Skip to content

Instantly share code, notes, and snippets.

@almereyda
almereyda / upgrade_fedora
Created August 5, 2017 23:16 — forked from yuriploc/upgrade_fedora
upgrading Fedora using dnf system-upgrade
// in case you have VirtualBox and kmod-vbx, akmod-vbx, remove them
sudo dnf update
sudo dnf clean all
sudo dnf distro-sync --allowerasing
sudo dnf upgrade --refresh
sudo dnf system-upgrade download --releasever=NUM
sudo dnf system-upgrade reboot
sudo rpm --rebuilddb
sudo rpmconf -a
sudo dnf remove -y google-chrome-\* && sudo dnf install -y google-chrome-stable
@almereyda
almereyda / response
Last active May 6, 2018 22:25 — forked from y0va/500 server error
HTTP 500 for new relay domain
DoesNotExist at /admin/domains/new/
Users matching query does not exist.
Request Method: POST
Request URL: https://email.ecobytes.net/admin/domains/new/
Django Version: 1.11.12
Python Executable: /usr/bin/uwsgi-core
Python Version: 2.7.9
Python Path: ['.', '', '/srv/modoboa/env/lib/python2.7', '/srv/modoboa/env/lib/python2.7/plat-x86_64-linux-gnu', '/srv/modoboa/env/lib/python2.7/lib-tk', '/srv/modoboa/env/lib/python2.7/lib-old', '/srv/modoboa/env/lib/python2.7/lib-dynload', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk', '/srv/modoboa/env/local/lib/python2.7/site-packages', '/srv/modoboa/env/lib/python2.7/site-packages']
Server time: Sun, 6 May 2018 23:35:21 +0200
@almereyda
almereyda / autodoc-justfile.py
Created February 7, 2025 17:18 — forked from mofosyne/autodoc-justfile.py
Autogenerated Documentation For Justfiles
#!/usr/bin/env python3
# Autogenerated Documentation For Justfiles
# This was created to support this issue ticket https://github.com/casey/just/issues/2033#issuecomment-2278336973
import json
import subprocess
from typing import Any
# just --dump --dump-format json --unstable | jq > test.json
json_output = subprocess.run(
["just", "--dump", "--dump-format", "json", "--unstable"],
@almereyda
almereyda / md-filename-as-title.py
Created March 25, 2025 17:13 — forked from kmalloy24/md-filename-as-title.py
A Python script that adds the filename as Title frontmatter to all .md or .mdx files in the directory that it is run in.
import os
import re
# Function to generate title from filename
def generate_title(filename):
# Remove the extension
base = os.path.splitext(filename)[0]
# Remove numbers
base = re.sub(r'\d+', '', base)
# Replace dashes and underscores with spaces