Skip to content

Commit ec89dcb

Browse files
committed
feat: initial standalone Met Éireann ion
0 parents  commit ec89dcb

26 files changed

Lines changed: 3012 additions & 0 deletions

.github/assets/example.png

170 KB
Loading

.github/workflows/arch-build.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
# SPDX-FileCopyrightText: 2026 Alysson Souza e Silva <alysson@ll9.com.br>
2+
# SPDX-License-Identifier: GPL-2.0-or-later
3+
4+
name: Arch build
5+
6+
on:
7+
push:
8+
branches:
9+
- main
10+
pull_request:
11+
workflow_dispatch:
12+
13+
jobs:
14+
build:
15+
runs-on: ubuntu-latest
16+
container:
17+
image: archlinux:latest
18+
19+
steps:
20+
- name: Update system and install dependencies
21+
run: |
22+
pacman -Syu --noconfirm
23+
pacman -S --noconfirm --needed \
24+
base-devel \
25+
cmake \
26+
extra-cmake-modules \
27+
git \
28+
kcoreaddons \
29+
kdeplasma-addons \
30+
ki18n \
31+
kio \
32+
kunitconversion \
33+
qt6-base \
34+
qt6-declarative
35+
36+
- name: Check out repository
37+
uses: actions/checkout@v4
38+
39+
- name: Configure
40+
run: cmake -B build -S .
41+
42+
- name: Build
43+
run: cmake --build build -j2
44+
45+
- name: Stage install
46+
run: DESTDIR="$PWD/stage" cmake --install build

.gitignore

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
build/
2+
.cache/
3+
.idea/
4+
.vscode/
5+
*.swp
6+
*.user
7+
pkg/
8+
src/
9+
*.pkg.tar.*
10+
*.src.tar.*

.reuse/dep5

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
2+
Upstream-Name: plasma-ion-meteireann
3+
Upstream-Contact: Alysson Souza e Silva <alysson@ll9.com.br>
4+
Source: https://github.com/alysson-souza/plasma-ion-meteireann
5+
6+
Files: .github/workflows/arch-build.yml .gitignore .reuse/dep5 CMakeLists.txt PKGBUILD README.md NOTICE.met-eireann.txt src/CMakeLists.txt src/ion_meteireann.cpp src/ion_meteireann.h src/metadata.json include/plasmaweatherdata_export.h include/plasmaweatherion_export.h
7+
Copyright: 2026 Alysson Souza e Silva <alysson@ll9.com.br>
8+
License: GPL-2.0-or-later
9+
10+
Files: include/ion.h
11+
Copyright: 2007-2009 Shawn Starr <shawn.starr@rogers.com>
12+
License: LGPL-2.0-or-later
13+
14+
Files: include/currentday.h include/forecast.h include/futuredays.h include/lastday.h include/lastobservation.h include/locations.h include/metadata.h include/station.h include/warnings.h
15+
Copyright: 2025 Bohdan Onofriichuk <bogdan.onofriuchuk@gmail.com>
16+
License: GPL-2.0-or-later

CMakeLists.txt

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# SPDX-FileCopyrightText: 2026 Alysson Souza e Silva <alysson@ll9.com.br>
2+
# SPDX-License-Identifier: GPL-2.0-or-later
3+
4+
cmake_minimum_required(VERSION 3.16)
5+
6+
set(PROJECT_VERSION "0.1.0")
7+
project(plasma-ion-meteireann VERSION ${PROJECT_VERSION})
8+
9+
set(QT_MIN_VERSION "6.10.0")
10+
set(KF6_MIN_VERSION "6.22.0")
11+
set(CMAKE_CXX_STANDARD 20)
12+
set(CMAKE_CXX_STANDARD_REQUIRED ON)
13+
14+
find_package(ECM ${KF6_MIN_VERSION} REQUIRED NO_MODULE)
15+
set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH})
16+
17+
include(KDEInstallDirs)
18+
include(KDECMakeSettings)
19+
include(KDECompilerSettings NO_POLICY_SCOPE)
20+
include(ECMQtDeclareLoggingCategory)
21+
include(FeatureSummary)
22+
23+
find_package(Qt6 ${QT_MIN_VERSION} CONFIG REQUIRED COMPONENTS Core Qml)
24+
find_package(KF6 ${KF6_MIN_VERSION} REQUIRED COMPONENTS
25+
CoreAddons
26+
KIO
27+
I18n
28+
UnitConversion
29+
)
30+
31+
find_library(PLASMAWEATHERION_LIBRARY NAMES plasmaweatherion REQUIRED)
32+
find_library(PLASMAWEATHERDATA_LIBRARY NAMES plasmaweatherdata REQUIRED)
33+
34+
add_subdirectory(src)
35+
36+
install(FILES
37+
NOTICE.met-eireann.txt
38+
DESTINATION ${KDE_INSTALL_DATADIR}/doc/${PROJECT_NAME}
39+
)
40+
41+
feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)

LICENSES/GPL-2.0-or-later.txt

Lines changed: 319 additions & 0 deletions
Large diffs are not rendered by default.

LICENSES/LGPL-2.0-or-later.txt

Lines changed: 446 additions & 0 deletions
Large diffs are not rendered by default.

NOTICE.met-eireann.txt

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
Met Éireann data notice
2+
=======================
3+
4+
This project redisplays and derives forecast information from Met Éireann data.
5+
6+
Source:
7+
https://www.met.ie/
8+
9+
Open data information:
10+
https://www.met.ie/about-us/specialised-services/open-data
11+
12+
Forecast API used by this project:
13+
http://openaccess.pf.api.met.ie/metno-wdb2ts/locationforecast
14+
15+
Required attribution and disclaimer text should be reviewed against Met Éireann's
16+
current Open Data terms before redistribution. In particular, the Met Éireann
17+
Open Data page requires attribution to Met Éireann, source identification,
18+
licence information, a disclaimer of liability, and notice of modifications
19+
where applicable.
20+
21+
This project modifies and reformats forecast data for use in the KDE Plasma
22+
weather widget.

PKGBUILD

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# SPDX-FileCopyrightText: 2026 Alysson Souza e Silva <alysson@ll9.com.br>
2+
# SPDX-License-Identifier: GPL-2.0-or-later
3+
#
4+
# Maintainer: Alysson Souza e Silva <alysson@ll9.com.br>
5+
6+
pkgname=plasma-ion-meteireann
7+
pkgver=0.1.0
8+
pkgrel=1
9+
pkgdesc="Met Éireann weather ion for the KDE Plasma weather widget"
10+
arch=('x86_64')
11+
license=('GPL-2.0-or-later' 'LGPL-2.0-or-later')
12+
depends=(
13+
'gcc-libs'
14+
'kcoreaddons'
15+
'kdeplasma-addons'
16+
'ki18n'
17+
'kio'
18+
'kunitconversion'
19+
'qt6-base'
20+
'qt6-declarative'
21+
)
22+
makedepends=(
23+
'cmake'
24+
'extra-cmake-modules'
25+
)
26+
27+
build() {
28+
cmake -B "${srcdir}/build" -S "${startdir}" \
29+
-DCMAKE_BUILD_TYPE=None \
30+
-DCMAKE_INSTALL_PREFIX=/usr \
31+
-DCMAKE_INSTALL_LIBDIR=lib
32+
cmake --build "${srcdir}/build"
33+
}
34+
35+
package() {
36+
DESTDIR="${pkgdir}" cmake --install "${srcdir}/build"
37+
}

README.md

Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
# plasma-ion-meteireann
2+
3+
Standalone KDE Plasma weather provider for [Met Éireann](https://www.met.ie/), the Irish Meteorological Service.
4+
5+
It adds a **Met Éireann** data source to the Plasma weather widget through the `plasma/weather_ions` plugin system.
6+
7+
![Met Éireann provider in the Plasma weather widget](.github/assets/example.png)
8+
9+
## Requirements
10+
11+
### Runtime
12+
13+
- Plasma 6 weather widget
14+
- `kdeplasma-addons`
15+
- Qt 6
16+
- KDE Frameworks 6
17+
18+
The plugin uses the weather runtime libraries shipped by `kdeplasma-addons`:
19+
20+
- `libplasmaweatherion.so`
21+
- `libplasmaweatherdata.so`
22+
23+
### Build
24+
25+
- CMake >= 3.16
26+
- Extra CMake Modules (ECM) >= 6.22
27+
- Qt 6 >= 6.10
28+
- KDE Frameworks 6 >= 6.22
29+
30+
### Arch / CachyOS build dependencies
31+
32+
```bash
33+
sudo pacman -S --needed cmake extra-cmake-modules qt6-base qt6-declarative \
34+
kcoreaddons ki18n kio kunitconversion kdeplasma-addons
35+
```
36+
37+
## Building
38+
39+
```bash
40+
cmake -B build -S .
41+
cmake --build build
42+
```
43+
44+
## Installing
45+
46+
Arch / CachyOS with `yay` from a local checkout:
47+
48+
```bash
49+
git clone https://github.com/alysson-souza/plasma-ion-meteireann.git
50+
cd plasma-ion-meteireann
51+
yay -Bi .
52+
```
53+
54+
System-wide from a local build:
55+
56+
```bash
57+
sudo cmake --install build
58+
```
59+
60+
User-local:
61+
62+
```bash
63+
cmake --install build --prefix ~/.local
64+
```
65+
66+
If Plasma does not automatically discover a user-local install, make sure your session includes:
67+
68+
```bash
69+
QT_PLUGIN_PATH=$HOME/.local/lib/qt6/plugins
70+
```
71+
72+
and restart `plasmashell`.
73+
74+
## Using it
75+
76+
1. Open the Plasma weather widget configuration
77+
2. Type your location into the search field
78+
3. Select the result labeled with **`(Met Éireann)`**
79+
4. Click **Apply** or **OK**
80+
81+
Location search is currently handled through Met Éireann website lookup endpoints.
82+
83+
## Forecast data source
84+
85+
Forecast data comes from Met Éireann's official Open Data weather forecast API:
86+
87+
- `http://openaccess.pf.api.met.ie/metno-wdb2ts/locationforecast`
88+
89+
## Met Éireann attribution
90+
91+
This project redisplays Met Éireann data. For redistribution, review:
92+
93+
- [NOTICE.met-eireann.txt](NOTICE.met-eireann.txt)
94+
- [Met Éireann Open Data](https://www.met.ie/about-us/specialised-services/open-data)
95+
96+
## License
97+
98+
This repository is mixed-license:
99+
100+
- local project files are `GPL-2.0-or-later`
101+
- vendored `include/ion.h` is `LGPL-2.0-or-later`
102+
- vendored weather data headers in `include/` are `GPL-2.0-or-later`
103+
104+
See:
105+
106+
- [LICENSES/LGPL-2.0-or-later.txt](LICENSES/LGPL-2.0-or-later.txt)
107+
- [LICENSES/GPL-2.0-or-later.txt](LICENSES/GPL-2.0-or-later.txt)

0 commit comments

Comments
 (0)