Use reproducible timestamps in more doc examples (#2626)

This adds require("_date") to some example tests that use the current
date via os.date. This allows reproducibility by replacing os.date()
with a function that uses a static date from $SOURCE_DATE_EPOCH. See
commit 9d7eaf0 for more details.

Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
Uli Schlachter 2019-01-29 19:36:40 +01:00 committed by Daniel Hahler
parent cdd6e360f5
commit b5abd53cbf
3 changed files with 3 additions and 0 deletions

View File

@ -1,6 +1,7 @@
--DOC_GEN_IMAGE
--DOC_HIDE_ALL
--DOC_NO_USAGE
require("_date")
local awful = require("awful")
local gears = require("gears")
local wibox = require("wibox")

View File

@ -1,5 +1,6 @@
--DOC_GEN_IMAGE
--DOC_NO_USAGE
require("_date") --DOC_HIDE
screen[1]._resize {width = 300, height = 75} --DOC_HIDE
local awful = {tooltip = require("awful.tooltip"), wibar = require("awful.wibar")} --DOC_HIDE
local wibox = { widget = { textclock = require("wibox.widget.textclock") }, --DOC_HIDE

View File

@ -1,5 +1,6 @@
--DOC_GEN_IMAGE
--DOC_NO_USAGE
require("_date") --DOC_HIDE
screen[1]._resize {width = 300, height = 75} --DOC_HIDE
local awful = {tooltip = require("awful.tooltip"), wibar = require("awful.wibar")} --DOC_HIDE
local wibox = { widget = { textclock = require("wibox.widget.textclock") }, --DOC_HIDE