* [PATCH] 26.0.50.3, add $TTL directove to dns-mode.el
@ 2017-01-12 9:37 Alexander Kuleshov
0 siblings, 0 replies; only message in thread
From: Alexander Kuleshov @ 2017-01-12 9:37 UTC (permalink / raw)
To: emacs-devel
[-- Attachment #1: Type: text/plain, Size: 427 bytes --]
Hello everyone,
This simple patch adds `$TTL` directive to dns-mode-font-lock-keywords
from the lisp/text-modes/dns-mode.el.
The global `$TTL` directive (time-to-live) specifies the duration in seconds
that the record may be cached by any resolver. In general it should looks:
$TTL amount-of-ttl (in seconds)
Additionally d/D/h/H/w/W/m/M/s/S maybe added to amount-of-ttl where d/D -
days, h/H - hours and etc..
Thank you.
[-- Attachment #2: 0001-Add-support-for-TTL-dns-directive.patch --]
[-- Type: text/plain, Size: 986 bytes --]
From 2209894bc51367570c38a3428be6f4f1e2bc25a2 Mon Sep 17 00:00:00 2001
From: Alexander Kuleshov <kuleshovmail@gmail.com>
Date: Thu, 12 Jan 2017 15:26:02 +0600
Subject: [PATCH] Add support for $TTL dns directive
* lisp/text-modes/dns-mode.el (dns-mode-font-lock-keywords): Add $TTL
directive.
---
lisp/textmodes/dns-mode.el | 1 +
1 file changed, 1 insertion(+)
diff --git a/lisp/textmodes/dns-mode.el b/lisp/textmodes/dns-mode.el
index 02cb2a2..6a3cfcb 100644
--- a/lisp/textmodes/dns-mode.el
+++ b/lisp/textmodes/dns-mode.el
@@ -79,6 +79,7 @@ dns-mode-class-face
(defcustom dns-mode-font-lock-keywords
`(("^$ORIGIN" 0 ,dns-mode-control-entity-face)
("^$INCLUDE" 0 ,dns-mode-control-entity-face)
+ ("^$TTL\s+[0-9]+[WwDdHhMmSs]?" 0 ,dns-mode-control-entity-face)
("^$[a-z0-9A-Z]+" 0 ,dns-mode-bad-control-entity-face)
(,(regexp-opt dns-mode-classes) 0 ,dns-mode-class-face)
(,(regexp-opt dns-mode-types) 0 ,dns-mode-type-face))
--
2.8.0.rc3.1353.gea9bdc0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2017-01-12 9:37 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-12 9:37 [PATCH] 26.0.50.3, add $TTL directove to dns-mode.el Alexander Kuleshov
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).