Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1422792
| From | Julia Lawall <julia.lawall@lip6.fr> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci |
| Date | 2016-06-15 10:50 +0200 |
| Message-ID | <rKeGm-ez-15@gated-at.bofh.it> (permalink) |
| References | <rK4QF-2oZ-11@gated-at.bofh.it> <rK4QG-2oZ-27@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
How about the following, since Coccinelle knows what its version is? This could of course be implemented in python as well. julia diff --git a/docs/Coccilib.3cocci b/docs/Coccilib.3cocci index 0e4fbb8..ca5b061 100644 --- a/docs/Coccilib.3cocci +++ b/docs/Coccilib.3cocci @@ -232,6 +232,15 @@ is the empty list if spatch is not currently working on any file (eg, in an initialize or finalize rule). .sp +.I val cocci_version +: +.B unit -> string +.sp +Returns the a string indicating the current version. Note that if +Coccinelle has been modified since a release, the version number will be +postfixed with "-dirty". +.sp + .I val print_main : .B ?color:string -> string -> pos list -> unit diff --git a/ocaml/coccilib.ml b/ocaml/coccilib.ml index f60c6b2..2f352d8 100644 --- a/ocaml/coccilib.ml +++ b/ocaml/coccilib.ml @@ -168,6 +168,8 @@ let dir () = !Flag.dir let files () = !Flag.currentfiles +let cocci_version () = Config.version + (* ---------------------------------------------------------------------- *) (* org mode *)
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-06-15 00:20 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci Julia Lawall <julia.lawall@lip6.fr> - 2016-06-15 08:10 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-06-15 18:00 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci Julia Lawall <julia.lawall@lip6.fr> - 2016-06-15 10:50 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-06-15 17:50 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci Julia Lawall <julia.lawall@lip6.fr> - 2016-06-15 18:00 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-06-15 18:10 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci Julia Lawall <julia.lawall@lip6.fr> - 2016-06-15 18:20 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-06-15 18:50 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci Julia Lawall <julia.lawall@lip6.fr> - 2016-06-15 19:00 +0200
Re: [PATCH 4/4] scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci "Luis R. Rodriguez" <mcgrof@kernel.org> - 2016-06-15 21:10 +0200
Re: scripts/coccinelle: require coccinelle >= 1.0.4 on device_node_continue.cocci SF Markus Elfring <elfring@users.sourceforge.net> - 2016-06-15 18:10 +0200
csiph-web