(equal? a b)
compares if two versions are the same
(equal? "1.2-final" "1.2") => true
compares if two versions are the same (equal? "1.2-final" "1.2") => true
(newer? a b)
returns true if the the first argument is newer than the second
(newer? "1.2" "1.0") => true
(newer? "1.2.2" "1.0.4") => true
returns true if the the first argument is newer than the second (newer? "1.2" "1.0") => true (newer? "1.2.2" "1.0.4") => true
(not-equal? a b)
(not-newer? a b)
(not-older? a b)
(older? a b)
returns true if the the first argument is older than the second
(older? "1.0-alpha" "1.0-beta") => true
(older? "1.0-rc1" "1.0") => true
returns true if the the first argument is older than the second (older? "1.0-alpha" "1.0-beta") => true (older? "1.0-rc1" "1.0") => true
(parse s)
parses a version input (parse "1.0.0-final") => {:major 1, :minor 0, :incremental 0, :qualifier 6, :release "final", :build ""}
(parse "1.0.0-alpha+build.123") => {:major 1, :minor 0, :incremental 0, :qualifier 0, :release "alpha", :build "build.123"}
parses a version input (parse "1.0.0-final") => {:major 1, :minor 0, :incremental 0, :qualifier 6, :release "final", :build ""} (parse "1.0.0-alpha+build.123") => {:major 1, :minor 0, :incremental 0, :qualifier 0, :release "alpha", :build "build.123"}
(parse-number s)
parse a number from string input
(parse-number "1") => 1
parse a number from string input (parse-number "1") => 1
(parse-qualifier release build)
parses a qualifier from string input
(parse-qualifier "" "") => 6
(parse-qualifier "alpha" "") => 0
parses a qualifier from string input (parse-qualifier "" "") => 6 (parse-qualifier "alpha" "") => 0
(version x)
like parse but also accepts maps
(version "1.0-RC5") => {:major 1, :minor 0, :incremental nil, :qualifier 3, :release "rc5", :build ""}
like parse but also accepts maps (version "1.0-RC5") => {:major 1, :minor 0, :incremental nil, :qualifier 3, :release "rc5", :build ""}
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close