Skip to content

Instantly share code, notes, and snippets.

@Luro02
Luro02 / ubuntu_fix.md
Last active February 10, 2019 09:09
A little tutorial for future ubuntu users, that have a fucked up apt/dpkg database and want to fix it

The Problem:

After some time the package database might get broken because you installed some incomplete stuff or did some installations manually, without thinking what you were doing. Now you get a warning everytime you run an apt-command, or even worse: it refuses to install anything.

How I fixed it:

run the following commands:

sudo bash

mv /var/lib/dpkg/status /var/lib/dpkg/status_bkup

#!/usr/bin/python3
#
# Written for Python 3.7
from __future__ import annotations
from typing import Callable
def and_x(a: bool, b: bool) -> bool:
return a and b
def or_x(a: bool, b: bool) -> bool: