home/sbin/encode: major update

- bugfixes and refactoring
- improve compatibility with Python 2
- add binary and octal encodings
- add `--url-safe` flag
- add more character conversions
- remove the ambiguous `1 -> l` conversion