From 2724ff6af8ba5f8dfd1f0f511ed95fab5cd8abd8 Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Fri, 20 Dec 2013 13:51:42 -0800 Subject: Link from symmetric encryption to fernet --- docs/cryptography-docs.py | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'docs/cryptography-docs.py') diff --git a/docs/cryptography-docs.py b/docs/cryptography-docs.py index ea7e8eef..f07c18bb 100644 --- a/docs/cryptography-docs.py +++ b/docs/cryptography-docs.py @@ -6,17 +6,30 @@ from sphinx.util.compat import Directive, make_admonition DANGER_MESSAGE = """ This is a "Hazardous Materials" module. You should **ONLY** use it if you're 100% absolutely sure that you know what you're doing because this module is -full of land mines, dragons, and dinosaurs with laser guns. """ +full of land mines, dragons, and dinosaurs with laser guns. +""" + +DANGER_ALTERNATE = """ + +You may instead be interested in :doc:`{alternate}`. +""" + class HazmatDirective(Directive): + has_content = True + def run(self): + message = DANGER_MESSAGE + if self.content: + message += DANGER_ALTERNATE.format(alternate=self.content[0]) + ad = make_admonition( Hazmat, self.name, [], self.options, - nodes.paragraph("", DANGER_MESSAGE), + nodes.paragraph("", message), self.lineno, self.content_offset, self.block_text, -- cgit v1.2.3 From 3ac297e4c9b655b3222da1830e9677c9d03a3926 Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Fri, 20 Dec 2013 14:16:34 -0800 Subject: flake8 fix --- docs/cryptography-docs.py | 1 - 1 file changed, 1 deletion(-) (limited to 'docs/cryptography-docs.py') diff --git a/docs/cryptography-docs.py b/docs/cryptography-docs.py index f07c18bb..0252d693 100644 --- a/docs/cryptography-docs.py +++ b/docs/cryptography-docs.py @@ -15,7 +15,6 @@ You may instead be interested in :doc:`{alternate}`. """ - class HazmatDirective(Directive): has_content = True -- cgit v1.2.3 From 681fca8f43f9cbed97ce2df0b871447953c7edda Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Tue, 31 Dec 2013 14:13:39 -0800 Subject: Rearange sentence on recommendation of @jacobian --- docs/cryptography-docs.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'docs/cryptography-docs.py') diff --git a/docs/cryptography-docs.py b/docs/cryptography-docs.py index 0252d693..f27a8467 100644 --- a/docs/cryptography-docs.py +++ b/docs/cryptography-docs.py @@ -23,6 +23,9 @@ class HazmatDirective(Directive): if self.content: message += DANGER_ALTERNATE.format(alternate=self.content[0]) + import pdb + pdb.set_trace() + ad = make_admonition( Hazmat, self.name, -- cgit v1.2.3 From 09aa74635f54ace5480a6d502b0da92651f516b6 Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Tue, 31 Dec 2013 15:18:34 -0800 Subject: Remove this one weird debugger --- docs/cryptography-docs.py | 3 --- 1 file changed, 3 deletions(-) (limited to 'docs/cryptography-docs.py') diff --git a/docs/cryptography-docs.py b/docs/cryptography-docs.py index f27a8467..0252d693 100644 --- a/docs/cryptography-docs.py +++ b/docs/cryptography-docs.py @@ -23,9 +23,6 @@ class HazmatDirective(Directive): if self.content: message += DANGER_ALTERNATE.format(alternate=self.content[0]) - import pdb - pdb.set_trace() - ad = make_admonition( Hazmat, self.name, -- cgit v1.2.3