I recently wrote a program to do some record-keeping for me. I found
myself hard-coding a bunch of different values into it. This didn't
seem right, so I made my first use of configparser.ConfigParser().
Created the configuration file and everything is working fine.
However, I wrote it based on t
On 5/22/2025 7:09 PM, Rob Cliffe via Python-list wrote:
On 22/05/2025 23:45, Mats Wichmann wrote:
On 5/22/25 13:59, Michael F. Stemper via Python-list wrote:
I recently wrote a program to do some record-keeping for me. I found
myself hard-coding a bunch of different values into it. This didn'
It occurs to me that it might be useful if Python provided a function to
search for a file with a given name in various directories (much as the
import.import_lib function searches for a module in the directories in
sys.path).
This function would perhaps be best placed in the os.path or os modu
On 5/22/25 13:59, Michael F. Stemper via Python-list wrote:
I recently wrote a program to do some record-keeping for me. I found
myself hard-coding a bunch of different values into it. This didn't
seem right, so I made my first use of configparser.ConfigParser().
Created the configuration file an
On 22/05/2025 23:45, Mats Wichmann wrote:
On 5/22/25 13:59, Michael F. Stemper via Python-list wrote:
I recently wrote a program to do some record-keeping for me. I found
myself hard-coding a bunch of different values into it. This didn't
seem right, so I made my first use of configparser.Conf
On 2025-05-23, Thomas Passin wrote:
>> Alternatively look at the PATH envronment variable, which
>> contains a list of directories separated by semicolons and which you can
>> access as os.environ['PATH'] .
>
> There is really no reason for a config file to be on the system
> path.
On Unix/Lin