aboutsummaryrefslogtreecommitdiff
path: root/qapi
diff options
context:
space:
mode:
authorAndrea Bolognani <abologna@redhat.com>2020-07-29 20:50:24 +0200
committerMarkus Armbruster <armbru@redhat.com>2020-08-03 08:28:08 +0200
commitf7160f32186b4ae1e1327e3bd05060fffec8f9ae (patch)
treef6461a9fe688f87c9959f8f8f070abe4cd30e6f2 /qapi
parentfbeed197611bda439968e68a42d8efadb2e60f81 (diff)
schemas: Add vim modeline
The various schemas included in QEMU use a JSON-based format which is, however, strictly speaking not valid JSON. As a consequence, when vim tries to apply syntax highlight rules for JSON (as guessed from the file name), the result is an unreadable mess which mostly consist of red markers pointing out supposed errors in, well, pretty much everything. Using Python syntax highlighting produces much better results, and in fact these files already start with specially-formatted comments that instruct Emacs to process them as if they were Python files. This commit adds the equivalent special comments for vim. Signed-off-by: Andrea Bolognani <abologna@redhat.com> Message-Id: <20200729185024.121766-1-abologna@redhat.com> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Reviewed-by: John Snow <jsnow@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com>
Diffstat (limited to 'qapi')
-rw-r--r--qapi/authz.json1
-rw-r--r--qapi/block-core.json1
-rw-r--r--qapi/block.json1
-rw-r--r--qapi/char.json1
-rw-r--r--qapi/common.json1
-rw-r--r--qapi/control.json1
-rw-r--r--qapi/crypto.json1
-rw-r--r--qapi/dump.json1
-rw-r--r--qapi/error.json1
-rw-r--r--qapi/introspect.json1
-rw-r--r--qapi/job.json1
-rw-r--r--qapi/machine-target.json1
-rw-r--r--qapi/machine.json1
-rw-r--r--qapi/migration.json1
-rw-r--r--qapi/misc-target.json1
-rw-r--r--qapi/misc.json1
-rw-r--r--qapi/net.json1
-rw-r--r--qapi/qapi-schema.json1
-rw-r--r--qapi/qdev.json1
-rw-r--r--qapi/qom.json1
-rw-r--r--qapi/rdma.json1
-rw-r--r--qapi/rocker.json1
-rw-r--r--qapi/run-state.json1
-rw-r--r--qapi/sockets.json1
-rw-r--r--qapi/tpm.json1
-rw-r--r--qapi/transaction.json1
-rw-r--r--qapi/ui.json1
27 files changed, 27 insertions, 0 deletions
diff --git a/qapi/authz.json b/qapi/authz.json
index 1c836a3abd..f3e9745426 100644
--- a/qapi/authz.json
+++ b/qapi/authz.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
# QAPI authz definitions
diff --git a/qapi/block-core.json b/qapi/block-core.json
index 49edb4fdae..197bdc1c36 100644
--- a/qapi/block-core.json
+++ b/qapi/block-core.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
##
# == Block core (VM unrelated)
diff --git a/qapi/block.json b/qapi/block.json
index 2ddbfa8306..c54a393cf3 100644
--- a/qapi/block.json
+++ b/qapi/block.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
##
# = Block devices
diff --git a/qapi/char.json b/qapi/char.json
index daceb20f84..8aeedf96b2 100644
--- a/qapi/char.json
+++ b/qapi/char.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/common.json b/qapi/common.json
index 7b9cbcd97b..716712d4b3 100644
--- a/qapi/common.json
+++ b/qapi/common.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
##
# = Common data types
diff --git a/qapi/control.json b/qapi/control.json
index 6b816bb61f..de51e9916c 100644
--- a/qapi/control.json
+++ b/qapi/control.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/crypto.json b/qapi/crypto.json
index 5a68e0db25..bb7930d332 100644
--- a/qapi/crypto.json
+++ b/qapi/crypto.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/dump.json b/qapi/dump.json
index a1eed7b15c..f7c4267e3f 100644
--- a/qapi/dump.json
+++ b/qapi/dump.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
# This work is licensed under the terms of the GNU GPL, version 2 or later.
# See the COPYING file in the top-level directory.
diff --git a/qapi/error.json b/qapi/error.json
index 3fad08f506..94a6502de9 100644
--- a/qapi/error.json
+++ b/qapi/error.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
##
# = QMP errors
diff --git a/qapi/introspect.json b/qapi/introspect.json
index b1aabd4cfd..944bb87a20 100644
--- a/qapi/introspect.json
+++ b/qapi/introspect.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
# Copyright (C) 2015 Red Hat, Inc.
#
diff --git a/qapi/job.json b/qapi/job.json
index c48a0c3e34..280c2f76f1 100644
--- a/qapi/job.json
+++ b/qapi/job.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
##
# == Background jobs
diff --git a/qapi/machine-target.json b/qapi/machine-target.json
index f2c82949d8..698850cc78 100644
--- a/qapi/machine-target.json
+++ b/qapi/machine-target.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
# This work is licensed under the terms of the GNU GPL, version 2 or later.
# See the COPYING file in the top-level directory.
diff --git a/qapi/machine.json b/qapi/machine.json
index daede5ab14..481b1f07ec 100644
--- a/qapi/machine.json
+++ b/qapi/machine.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
# This work is licensed under the terms of the GNU GPL, version 2 or later.
# See the COPYING file in the top-level directory.
diff --git a/qapi/migration.json b/qapi/migration.json
index d5000558c6..ea53b23dca 100644
--- a/qapi/migration.json
+++ b/qapi/migration.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/misc-target.json b/qapi/misc-target.json
index dee3b45930..1e561fa97b 100644
--- a/qapi/misc-target.json
+++ b/qapi/misc-target.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/misc.json b/qapi/misc.json
index 149c925246..9d32820dc1 100644
--- a/qapi/misc.json
+++ b/qapi/misc.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/net.json b/qapi/net.json
index 558d520a2f..ddb113e5e5 100644
--- a/qapi/net.json
+++ b/qapi/net.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/qapi-schema.json b/qapi/qapi-schema.json
index 43b0ba0dea..f03ff91ceb 100644
--- a/qapi/qapi-schema.json
+++ b/qapi/qapi-schema.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
##
# = Introduction
#
diff --git a/qapi/qdev.json b/qapi/qdev.json
index f4ed9735c4..13254529bf 100644
--- a/qapi/qdev.json
+++ b/qapi/qdev.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
# This work is licensed under the terms of the GNU GPL, version 2 or later.
# See the COPYING file in the top-level directory.
diff --git a/qapi/qom.json b/qapi/qom.json
index 8abe998962..0b0b92944b 100644
--- a/qapi/qom.json
+++ b/qapi/qom.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
# This work is licensed under the terms of the GNU GPL, version 2 or later.
# See the COPYING file in the top-level directory.
diff --git a/qapi/rdma.json b/qapi/rdma.json
index b58105b1b6..a1d2175a8b 100644
--- a/qapi/rdma.json
+++ b/qapi/rdma.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/rocker.json b/qapi/rocker.json
index 52597db491..b48e49a89b 100644
--- a/qapi/rocker.json
+++ b/qapi/rocker.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
##
# = Rocker switch device
diff --git a/qapi/run-state.json b/qapi/run-state.json
index 2e22907740..7cc9f96a5b 100644
--- a/qapi/run-state.json
+++ b/qapi/run-state.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/sockets.json b/qapi/sockets.json
index cbd6ef35d0..c0c640a5b0 100644
--- a/qapi/sockets.json
+++ b/qapi/sockets.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
##
# = Socket data types
diff --git a/qapi/tpm.json b/qapi/tpm.json
index dc1f081739..6a10c9ed8d 100644
--- a/qapi/tpm.json
+++ b/qapi/tpm.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/transaction.json b/qapi/transaction.json
index b6c11158f0..15ddebdbc3 100644
--- a/qapi/transaction.json
+++ b/qapi/transaction.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##
diff --git a/qapi/ui.json b/qapi/ui.json
index 1568cfeaad..9d6721037f 100644
--- a/qapi/ui.json
+++ b/qapi/ui.json
@@ -1,4 +1,5 @@
# -*- Mode: Python -*-
+# vim: filetype=python
#
##