summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.md4
-rw-r--r--wttrin.el6
-rw-r--r--wttrin.pngbin113837 -> 92979 bytes
3 files changed, 5 insertions, 5 deletions
diff --git a/README.md b/README.md
index d3055ec..6e119ff 100644
--- a/README.md
+++ b/README.md
@@ -4,10 +4,10 @@ Emacs frontend for weather web service [wttr.in].
## Usage
-set a default cities list for completion:
+Set a default cities list for completion:
```elisp
-(setq wttrin-default-city "Taipei")
+(setq wttrin-default-cities ("Taipei" "Tainan"))
```
Then run `M-x wttrin` to get the information.
diff --git a/wttrin.el b/wttrin.el
index ca35eca..a56b248 100644
--- a/wttrin.el
+++ b/wttrin.el
@@ -12,6 +12,7 @@
;; Provides the weather information from wttr.in based on your query condition.
;;; Code:
+
(require 'url)
(require 'xterm-color)
(require 'ido)
@@ -22,7 +23,7 @@
:group 'comm)
(defcustom wttrin-default-cities '("Taipei" "Keelung" "Taichung" "Tainan")
- "Specify default cities list to for quick completion"
+ "Specify default cities list for quick completion."
:group 'wttrin
:type 'list)
@@ -36,8 +37,7 @@
(decode-coding-string (buffer-string) 'utf-8))))
(defun wttrin-query (city-name)
- "Query weather of CITY-NAME via wttrin, and display the result
-in another buffer."
+ "Query weather of CITY-NAME via wttrin, and display the result in new buffer."
(let ((raw-string (wttrin-fetch-raw-string city-name)))
(if (string-match "ERROR" raw-string)
(message "Cannot get weather data. Maybe you inputed a wrong city name?")
diff --git a/wttrin.png b/wttrin.png
index 027c858..90eee7e 100644
--- a/wttrin.png
+++ b/wttrin.png
Binary files differ