Did you know ... | Search Documentation: |
Packs (add-ons) for SWI-Prolog |
Title: | Date and time library |
---|---|
Rating: | Not rated. Create the first rating! |
Latest version: | 0.1.3 |
SHA1 sum: | f468728de2e515b6973b07a6bf448952256351c0 |
Author: | Michael Hendricks <michael@ndrix.org> |
Maintainer: | Michael Hendricks <michael@ndrix.org> |
Packager: | Michael Hendricks <michael@ndrix.org> |
Home page: | https://github.com/mndrix/julian |
Download URL: | https://github.com/mndrix/julian/archive/v0.1.3.zip |
Requires: | delay |
list_util | |
typedef |
No reviews. Create the first review!.
Version | SHA1 | #Downloads | URL |
---|---|---|---|
0.0.1 | 0e06642d2feebbac52b8e6b6939bf6e7b039bd77 | 7 | http://packs.ndrix.com/julian/julian-0.0.1.tgz |
0.1.0 | c3c61e00106b0833d7c02dc811d0aef4c8c2239a | 1 | http://packs.ndrix.com/julian/julian-0.1.0.tgz |
0.1.1 | f7e8dbcddd27a3c602c3057104ee313b6723b2b2 | 13 | http://packs.ndrix.com/julian/julian-0.1.1.tgz |
0.1.2 | 47465c84923e8cca002d28695137761773748e75 | 20 | http://packs.ndrix.com/julian/julian-0.1.2.tgz |
0.1.3 | 27232e5897b902464d109d12b7e8b0d097611f95 | 214 | https://github.com/mndrix/julian/archive/v0.1.3.zip |
3eb26889b6478b4c000315361bcfe6e95978a3d4 | 262 | https://github.com/mndrix/julian.git | |
875cf44e261818087766fb059c0a7b5ba7290e0a | 205 | https://github.com/mndrix/julian.git | |
f468728de2e515b6973b07a6bf448952256351c0 | 14 | https://github.com/mndrix/julian/archive/v0.1.3.zip |
A date and time library for Prolog.
Warning: This is alpha quality software. APIs will change. There are bugs. Use with caution. Time zones are not yet supported and semantics that should account for time zone choose arbitrary, unpredictable behavior.
With that out of the way, the library can do a lot of useful stuff. See the [in-depth tutorial][tutorial] for examples.
:- use_module(library(julian)). :- use_module(library(clpfd)). solution(Year) :- % Eisenhower presidency had Fourth of July on Sunday in ... form_time([dow(sunday), Year-07-04]), Year in 1953..1961. ?- solution(Y). Y = 1954.
Using SWI-Prolog 7.1.18 or later:
?- pack_install(julian).
This module uses [semantic versioning][versioning].
Source code available and pull requests accepted at [`http://github.com/fifth-postulate/julian`][project]
Test are written with the Test Anything Protocol ([TAP][tap]) and use the [fnogatz/tap
][pack(tap)
] library.
To install the tap pack run
?- pack_install(tap).
Next, the julian
pack should be available as a library. One can install from the local installation by running
?- pack_install('file:///home/<path-to-project>/julian').
A TAP test harness should be used to run the tests in this project. To run the t/types.pl
test on could execute
prove -v -e 'swipl -q -t main -s' t/types.pl
To run all test one could use
prove -v -e 'swipl -q -t main -s' t/**.pl
Or use `make tests`.
[tutorial]: http://fifth-postulate.github.io/julian/
[versioning]: http://semver.org/
[project]: http://github.com/fifth-postulate/julian
[tap]: http://testanything.org/tap-specification.html
[pack(tap)
]: https://github.com/fnogatz/tap
Pack contains 42 files holding a total of 54.5K bytes.