summaryrefslogtreecommitdiff
path: root/README.md
blob: 39374a009828cdd31bd1687d2b65fbb43847bab8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
[![MELPA][melpa-badge]][melpa-package]
[![MELPA Stable][melpa-stable-badge]][melpa-stable-package]
[![Gitter][gitter-badge]][gitter-chatroom]
[![Build Status][travis-ci-badge]][travis-ci-status]

# wttrin.el

Emacs frontend for weather web service [wttr.in].

This fork has the following patches applied (still outstanding in bcbcarl/emacs-wttrin): 
- patch for selecting the unit system: https://github.com/bcbcarl/emacs-wttrin/pull/10
- patch for url request to return ascii rather than html https://github.com/bcbcarl/emacs-wttrin/pull/18
- patch to use https instead of http: https://github.com/bcbcarl/emacs-wttrin/pull/15

## Usage

Set a default cities list for completion:

```elisp
(setq wttrin-default-cities '("Taipei" "Tainan"))
```

You can also specify default HTTP request Header for Accept-Language:

```elisp
(setq wttrin-default-accept-language '("Accept-Language" . "zh-TW"))
```
As well as the unit system, "m" for metric and "u" for USCS/imperial (the default is to choose based on your location):

```elisp
(setq wttrin-unit-system "m")
```
Then run `M-x wttrin` to get the information.

When the weather is displayed you can press `q` to quit the buffer or `g` to query for another city.

![screenshot]

## LICENSE

MIT

[wttr.in]: http://wttr.in/
[screenshot]: wttrin.png
[melpa-badge]: http://melpa.org/packages/wttrin-badge.svg
[melpa-package]: http://melpa.org/#/wttrin
[melpa-stable-badge]: http://stable.melpa.org/packages/wttrin-badge.svg
[melpa-stable-package]: http://stable.melpa.org/#/wttrin
[gitter-badge]: https://badges.gitter.im/bcbcarl/emacs-wttrin.svg
[gitter-chatroom]: https://gitter.im/bcbcarl/emacs-wttrin?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge
[travis-ci-badge]: https://travis-ci.org/bcbcarl/emacs-wttrin.svg?branch=master
[travis-ci-status]: https://travis-ci.org/bcbcarl/emacs-wttrin