22nd Week of 2021
Coding⚑
Python⚑
Python Snippets⚑
-
New: Explain how to convert html code to readable plaintext.
pip install html2text
import html2text html = open("foobar.html").read() print(html2text.html2text(html))
-
New: Explain how to parse a datetime from a string.
from dateutil import parser parser.parse("Aug 28 1999 12:00AM") # datetime.datetime(1999, 8, 28, 0, 0)
Python Mysql⚑
- New: Explain how to interact with MySQL databases with Python.
DevOps⚑
Continuous Integration⚑
-
New: Explain how to troubleshoot the error: pathspec master did not match any file.
Remove all git hooks with
rm -r .git/hooks
.
Software Architecture⚑
Domain Driven Design⚑
-
Improvement: Add warning when migrating old code.
You may be tempted to migrate all your old code to this architecture once you fall in love with it. Truth being told, it's the best way to learn how to use it, but it's time expensive too! The last refactor I did required a change of 60% of the code. The upside is that I reduced the total lines of code a 25%.
Arts⚑
Writing⚑
Grammar and Orthography⚑
-
New: Explain what collocations are and how to avoid the word very.
Collocation refers to a natural combination of words that are closely affiliated with each other. They make it easier to avoid overused or ambiguous words like "very", "nice", or "beautiful", by using a pair of words that fit the context better and that have a more precise meaning.