The TEXMFCNF environment variable tells TeX (or rather, the kpathsea library used by TeX in typical distributions) where to look for the texmf.cnf file. (You can type kpsewhich texmf.cnf to see the location of the texmf.cnf file that will get picked up.)
For me, by default, kpsewhich texmf.cnf shows /usr/local/texlive/2017/texmf.cnf. But if I set TEXMFCNF to something else:
% export TEXMFCNF='/tmp'
% kpsewhich texmf.cnf
warning: kpathsea: configuration file texmf.cnf not found in these directories: /tmp.
However, if I instead export TEXMFCNF='/tmp:' then kpathsea searches in /tmp first, and then the default system directories (like /usr/local/texlive/2017/ or whatever).
The documentation for all this is in the kpathsea manual, sections Path searching > Path sources > Config files, and Path searching > Path expansion > Default expansion (for the stuff about the colon).
So the answer to your question, of how to maintain a local texmf.cnf file inside your user's home directory, is:
Create a file called texmf.cnf, in some place inside your home directory, say in ~/tex_config_dir. Put whatever config changes you'd like, into this file.
Somewhere in your shell config (.bashrc or .zshrc or whatever you use), set the environment variable TEXMFCNF to point to that directory, ending with a colon. For example:
export TEXMFCNF='~/tex_config_dir:'
In any new shell (for example, after restarting your terminal), type echo $TEXMFCNF to confirm that it's set correctly, and kpsewhich texmf.cnf to confirm that your config file is the one getting picked up. Enjoy.
/usr/local/texlive/2017/texmf.cnf. Perhaps you have to copy what's in the originaltexmf.cnfand add your stuff to it? – Ryo Jan 17 '18 at 10:42texmf.cnffiles in the search path, not just the first one found; definitions in earlier files override those in later files.” – ShreevatsaR Jan 17 '18 at 13:13texmf.cnfis special in this sense. I think LaTeX normally reads the version of the file it first finds and stops the search there. – Ryo Jan 18 '18 at 03:58