[Git][reproducible-builds/reproducible-website][master] Add Coffeescript example for SOURCE_DATE_EPOCH.

Chris Lamb (@lamby) gitlab at salsa.debian.org
Mon Jun 6 08:33:50 UTC 2022



Chris Lamb pushed to branch master at Reproducible Builds / reproducible-website


Commits:
a81d0273 by Chris Lamb at 2022-06-06T09:31:05+01:00
Add Coffeescript example for SOURCE_DATE_EPOCH.

- - - - -


1 changed file:

- _docs/source-date-epoch.md


Changes:

=====================================
_docs/source-date-epoch.md
=====================================
@@ -343,6 +343,14 @@ if (process.env.SOURCE_DATE_EPOCH) {
 }
 ```
 
+### Coffeescript
+
+```
+now = new Date()
+if process.env.SOURCE_DATE_EPOCH
+  now = new Date((process.env.SOURCE_DATE_EPOCH * 1000) + (now.getTimezoneOffset() * 60000))
+```
+
 
 ### Ruby
 



View it on GitLab: https://salsa.debian.org/reproducible-builds/reproducible-website/-/commit/a81d0273ff6f8670e1de1862b20eee99913838c7

-- 
View it on GitLab: https://salsa.debian.org/reproducible-builds/reproducible-website/-/commit/a81d0273ff6f8670e1de1862b20eee99913838c7
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.reproducible-builds.org/pipermail/rb-commits/attachments/20220606/88130384/attachment.htm>


More information about the rb-commits mailing list