Bind updating serial number for zones Local 2 way sex cam free

24 May

UPDSERIAL(date, num) if (strftime("%Y%m%d") == a:date) return a:date . '01' endfunction command Soa :%s/\(2[0-9]\)\([0-9]\); Serial/\=UPDSERIAL(submatch(1), submatch(2)) .

'; Serial'/gc "---- eof --------------------- serial is updated calling : Soa or it won't be updated - the Emacs version will automatically do the update for the relevent files.

A nice HOWTO about this is at: is also the recommended way in the DNS & BIND book (2006 ed.).Thanks to a blog posting by Tollef Fog Heen I learnt today that there is an Emacs mode for working with Zone files.(Perhaps I shouldn't be suprised; there seems to be a mode for everything! The next time you load the file in Emacs you'll see that you've got syntax highlighting, and if you write any changes to the file the Serial will be incremented appropriately.This post is helpful for configuring emacs to automatically update the “Serial” in bind zone databases.I wanted to do the same in Vim, but the solutions in the comments of that post didn’t work for me. It’s yours for free under the Affero GPL v3 (or any later version, at your preference): function s: Bind Zone Settings() function s: Update Bind Zone Serial(date, num) if (strftime("%Y%m%d") == a:date) return a:date . '01' endfunction function s: Replace Bind Zone Serial Line() :%s/\(2[0-9]\)\([0-9]\)\(\s*;\s*Serial\)/\=Update Bind Zone Serial(submatch(1), submatch(2)) .