tessellator / ring-version

A ring middleware to populate an X-Version header

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ring-version

Clojars Project

A ring middleware that populates X-Version header on a response.

Usage

(require '[ring.middleware.version :refer [wrap-version]])

(def handler
  (-> my-routes
      (wrap-version "1.0")))

This function also provides a function implementation-version that extracts the ImplementationVersion from a jar file given a type and a default value.

(require '[ring.middleware.version :refer [implementation-version wrap-version]])

(def handler
  (-> my-routes
      (wrap-version (implementation-version my.Type "dev"))))

License

Copyright © 2019 Thomas C. Taylor and contributors.

Distributed under the Eclipse Public License, the same as Clojure.

About

A ring middleware to populate an X-Version header

License:Eclipse Public License 1.0


Languages

Language:Clojure 94.1%Language:Shell 5.9%