branch: elpa/graphql-mode
commit 26a5d8a665c16f5daac8506b0d44a6684d963d4d
Author: Tim Shiu <[email protected]>
Commit: Tim Shiu <[email protected]>
make graphql-current-* function, not command. also
graphql-begining-of-variables
---
graphql-mode.el | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/graphql-mode.el b/graphql-mode.el
index 5e91075f4f..aa2dcb7afe 100644
--- a/graphql-mode.el
+++ b/graphql-mode.el
@@ -53,12 +53,14 @@
"Number of spaces for each indentation step in `graphql-mode'."
:tag "GraphQL"
:type 'integer
- :safe 'integerp)
+ :safe 'integerp
+ :group 'graphql)
(defcustom graphql-url "http://localhost:8000/graphql"
"URL address of the graphql server endpoint."
:tag "GraphQL"
- :type 'string)
+ :type 'string
+ :group 'graphql)
(defun graphql--query (query operation variables)
"Send QUERY to the server at `graphql-url' and return the
@@ -93,7 +95,6 @@ response from the server."
(defun graphql-current-query ()
"find out the current query/mutation/subscription"
- (interactive)
(let ((start
(save-excursion
(graphql-beginning-of-query)
@@ -106,7 +107,6 @@ response from the server."
(defun graphql-current-operation ()
"get the name of the query operation"
- (interactive)
(let* ((query
(save-excursion
(replace-regexp-in-string "^[ \t\n]*" "" (graphql-current-query))))
@@ -120,7 +120,6 @@ response from the server."
(defun graphql-current-variables ()
"get the content of graphql variables"
- (interactive)
(let ((variables
(save-excursion
(goto-char (point-max))
@@ -133,7 +132,6 @@ response from the server."
(defun graphql-beginning-of-variables ()
"get the beginning point of graphql variables"
- (interactive)
(save-excursion
(goto-char (point-max))
(search-backward-regexp "^variables" (point-min) t)