Skip to content

Commit

Permalink
fixup changes in extension.js to allow merge of mew upstream code
Browse files Browse the repository at this point in the history
  • Loading branch information
Robin Bowes committed Jun 5, 2011
2 parents 2d90945 + 8433a4c commit 2c2a2fa
Show file tree
Hide file tree
Showing 22 changed files with 1,338 additions and 118 deletions.
17 changes: 17 additions & 0 deletions .gitignore
@@ -0,0 +1,17 @@
Makefile
Makefile.in
Makefile.in.in
configure
config.log
config.status
aclocal.m4
autom4te.cache/
po/POTFILES
po/stamp-it
staging/

*~
*.gmo
metadata.json
*.gschema.xml
*.gschema.valid
4 changes: 4 additions & 0 deletions Makefile.am
@@ -0,0 +1,4 @@
ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}

SUBDIRS = src po

16 changes: 16 additions & 0 deletions NEWS
@@ -0,0 +1,16 @@
0.4
===
- add autotools support

0.3
===
- add translation support

0.2
===
- add yahoo backend
- add symbolic icons

0.1 (
===
first skeleton implementation
79 changes: 70 additions & 9 deletions README.md
@@ -1,26 +1,87 @@
## gnome-shell-extension-weather

gnome-shell-extension-weather is a simple extension for displaying weather notifications in Gnome Shell.
gnome-shell-extension-weather is a simple extension for displaying weather notifications in GNOME Shell.

Currently, the weather report including forecast for today and tomorrow is fetched from [Yahoo](http://weather.yahoo.com/).
Currently, the weather report including forecast for today and tomorrow is fetched from [Yahoo! Weather](http://weather.yahoo.com/).

### Screenshot
----

![Screenshot](https://github.com/simon04/gnome-shell-extension-weather/raw/master/screenshot.png)
### Screenshots

![Screenshot](gnome-shell-extension-weather/raw/master/data/screenshot.png)

And with French translation:

![Screenshot](gnome-shell-extension-weather/raw/master/data/screenshot2.png)

----

### Installation

1. Change `YAHOO_ID` to your location in extension.js (cf. [WOEID](http://developer.yahoo.com/geo/geoplanet/guide/concepts.html))
2. Put directory `weather@venemo.com/` in `~/.local/share/gnome-shell/extensions/`
3. Restart Gnome Shell (`[Alt]+[F2]`, `r`)
4. Enjoy, contribute, ...
For installation, run the following commands:

./autogen.sh --prefix=/usr
make
sudo make install

That's it!

----

### Configuration

gnome-shell-extension-weather uses gsettings to save your configuration. You can use `dconf-editor` or `gsettings` from the command line to modify some parameters.

#### Location (cf. [WOEID](http://developer.yahoo.com/geo/geoplanet/guide/concepts.html))

You can specify your location using the following command:

gsettings set org.gnome.shell.extensions.weather woeid your_woeid

#### Temperature Units (optional, celsius by default)

You can modify the temperature unit using one of the following commands:

gsettings set org.gnome.shell.extensions.weather unit celsius
gsettings set org.gnome.shell.extensions.weather unit fahrenheit

#### Displayed Location (optional)

Sometimes your WOEID location isn't quite right (it's the next major city around). To customise the displayed city you can type:

gsettings set org.gnome.shell.extensions.weather city your_city

#### Translate Weather Conditions (optional, true by default)

You may want to configure whether to translate the weather condition. If enabled, the condition is translated based on the weather code. If disabled, the condition string from Yahoo is taken. Note: Enabling the translation sometimes results in loss of accuracy, e.g., the condition string "PM Thunderstorms" cannot be expressed in terms of weather codes.

gsettings set org.gnome.shell.extensions.weather translate-condition true
gsettings set org.gnome.shell.extensions.weather translate-condition false

#### Use Symbolic Icons (optional, false by default)

If desired, you can enable the usage of symbolic icons to display the weather condition (instead of full-colored icons).

gsettings set org.gnome.shell.extensions.weather use-symbolic-icons false
gsettings set org.gnome.shell.extensions.weather use-symbolic-icons true

#### Restart GNOME Shell

Don't forget to restart GNOME Shell:

1. Restart GNOME Shell (`[Alt]+[F2]`, `r`)
2. Fork this project as you like

----

### Licence

Copyright (C) 2011
Ecyrbe <ecyrbe+spam@gmail.com>,
Timur Kristóf <venemo@msn.com>,
Elad Alfassa <elad@fedoraproject.org>,
Simon Legner <Simon.Legner@gmail.com>
Simon Legner <Simon.Legner@gmail.com>,
Simon Claessens <gagalago@gmail.com>

This file is part of gnome-shell-extension-weather.

Expand Down
20 changes: 20 additions & 0 deletions autogen.sh
@@ -0,0 +1,20 @@
#!/bin/bash
# Run this to generate all the initial makefiles, etc.

srcdir=`dirname $0`
test -z "$srcdir" && srcdir=.

PKG_NAME="gnome-shell-extension-weather"

test -f $srcdir/configure.ac || {
echo -n "**Error**: Directory "\`$srcdir\'" does not look like the"
echo " top-level gnome-shell-extensions directory"
exit 1
}

which gnome-autogen.sh || {
echo "You need to install gnome-common from GNOME Git (or from"
echo "your OS vendor's package manager)."
exit 1
}
. gnome-autogen.sh
3 changes: 3 additions & 0 deletions config/.gitignore
@@ -0,0 +1,3 @@
install-sh
mkinstalldirs
missing
28 changes: 28 additions & 0 deletions configure.ac
@@ -0,0 +1,28 @@
AC_PREREQ(2.63)
dnl be carefull, the version needs to be in sync with your gnome shell version
AC_INIT([gnome-shell-extension-weather],[3.0],[https://github.com/ecyrbe/gnome-shell-extension-weather/issues])

AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_AUX_DIR([config])

AM_INIT_AUTOMAKE([1.10 dist-bzip2 no-dist-gzip foreign tar-ustar])

m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])

GETTEXT_PACKAGE=gnome-shell-extension-weather
AC_SUBST(GETTEXT_PACKAGE)
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE",
[The prefix for our gettext translation domains.])
IT_PROG_INTLTOOL(0.26)

PKG_PROG_PKG_CONFIG([0.22])

GLIB_GSETTINGS

dnl Please keep this sorted alphabetically
AC_CONFIG_FILES([
Makefile
po/Makefile.in
src/Makefile
])
AC_OUTPUT
Binary file added data/screenshot.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added data/screenshot2.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions m4/.gitignore
@@ -0,0 +1 @@
intltool.m4
3 changes: 3 additions & 0 deletions po/LINGUAS
@@ -0,0 +1,3 @@
fr
nb

2 changes: 2 additions & 0 deletions po/POTFILES.in
@@ -0,0 +1,2 @@
src/extension.js

0 comments on commit 2c2a2fa

Please sign in to comment.