Andrew Benham wrote:> We use tftp to upload, on a daily basis, our switch configuration
> files.
>
> Therefore it is useful if we can use the remapper in in.tftpd from
> tftphpa to remap the filenames to include the current date. This
> means that we can configure the switches to upload the file
> 'config', and actually store 'config-192.168.0.1-20070217'
>
> We use a mapfile which includes:
>
> Pre config.* \0-\i-\d
>
> where we have added code to handle '\d'. That code is attached as
> a patch file.
Interesting idea. However, it might be worthwhile to make it possible
to override the default date string. I'm kind of thinking something like:
\d{...}
... where "..." is a strftime pattern. That way it would work for
people with other requirements. However, it would require more changes.
-hpa