Initial massive renaming.

This commit is contained in:
Jordan Petridis 2018-07-24 12:50:31 +03:00
parent 518ea9c8b5
commit 04c68ba013
No known key found for this signature in database
GPG Key ID: CEABAD9F5683B9A6
112 changed files with 300 additions and 298 deletions

View File

@ -4,7 +4,7 @@ stages:
- review
variables:
BUNDLE: "hammond-dev.flatpak"
BUNDLE: "gnome-podcasts-dev.flatpak"
.cargo_cache_template: &cargo_cache
cache:
@ -34,7 +34,7 @@ variables:
script:
- rustc -Vv && cargo -Vv
# Force regeneration of gresources regardless of artifacts chage
- cd hammond-gtk/resources/ && glib-compile-resources --generate resources.xml && cd ../../
- cd podcasts-gtk/resources/ && glib-compile-resources --generate resources.xml && cd ../../
- cargo build
- cargo test -- --test-threads=1
@ -58,22 +58,22 @@ flatpak:
image: registry.gitlab.gnome.org/gnome/gnome-runtime-images/rust_bundle:3.28
stage: test
script:
- flatpak-builder --stop-at=hammond app org.gnome.Hammond.json
- flatpak-builder --stop-at=gnome-podcasts app org.gnome.Podcasts.json
# https://gitlab.gnome.org/World/hammond/issues/55
# Force regeneration of gresources regardless of artifacts chage
- flatpak-builder --run app org.gnome.Hammond.json glib-compile-resources --sourcedir=hammond-gtk/resources/ hammond-gtk/resources/resources.xml
- flatpak-builder --run app org.gnome.Podcasts.json glib-compile-resources --sourcedir=podcasts-gtk/resources/ podcasts-gtk/resources/resources.xml
# Build the flatpak repo
- flatpak-builder --run app org.gnome.Hammond.json meson --prefix=/app --libdir=/app/lib _build
- flatpak-builder --run app org.gnome.Hammond.json ninja -C _build install
- flatpak-builder --finish-only app org.gnome.Hammond.json
- flatpak-builder --run app org.gnome.Podcasts.json meson --prefix=/app --libdir=/app/lib _build
- flatpak-builder --run app org.gnome.Podcasts.json ninja -C _build install
- flatpak-builder --finish-only app org.gnome.Podcasts.json
- flatpak build-export repo app
# Create a flatpak bundle
- flatpak build-bundle repo ${BUNDLE} org.gnome.Hammond
- flatpak build-bundle repo ${BUNDLE} org.gnome.Podcasts
# Run the tests
# - flatpak-builder --run app org.gnome.Hammond.json cargo test -- --test-threads=1
# - flatpak-builder --run app org.gnome.Hammond.json cargo test -- --test-threads=1 --ignored
# - flatpak-builder --run app org.gnome.Podcasts.json cargo test -- --test-threads=1
# - flatpak-builder --run app org.gnome.Podcasts.json cargo test -- --test-threads=1 --ignored
artifacts:
paths:
@ -139,6 +139,6 @@ rustfmt:
- rustc --version && cargo --version
- cargo clippy --version
# Force regeneration of gresources regardless of artifacts chage
- cd hammond-gtk/resources/ && glib-compile-resources --generate resources.xml && cd ../../
- cd podcasts-gtk/resources/ && glib-compile-resources --generate resources.xml && cd ../../
- cargo clippy --all
<<: *cargo_cache

View File

@ -18,7 +18,7 @@ Some common cases might be:
Steps to reproduce:
1. Open Hammond
1. Open GNOME Podcasts
2. Do an action
3. ...

View File

@ -1,17 +1,17 @@
## Contributing to Hammond
## Contributing to GNOME Podcasts
Thank you for looking in this file!
When contributing to the development of Hammond, please first discuss the change you wish to make via issue, email, or any other method with the maintainers before making a change.
When contributing to the development of GNOME Podcasts, please first discuss the change you wish to make via issue, email, or any other method with the maintainers before making a change.
If you have any questions regarding the use or development of Hammond,
If you have any questions regarding the use or development of GNOME Podcasts,
want to discuss design or simply hang out, please join us in [#hammond on irc.gnome.org.](irc://irc.gnome.org/#hammond)
Please note we have a [code of conduct](https://wiki.gnome.org/Foundation/CodeOfConduc), please follow it in all your interactions with the project.
## Source repository
Hammond's main source repository is at gitlab.gnome.org. You can view
GNOME Podcasts's main source repository is at gitlab.gnome.org. You can view
the web interface [here](https://gitlab.gnome.org/World/hammond)
Development happens in the master branch.
@ -50,8 +50,8 @@ In order to run the test suite use the following: `cargo test -- --test-threads=
# Issues, issues and more issues!
There are many ways you can contribute to Hammond, and all of them involve creating issues
in [Hammond issue tracker](https://gitlab.gnome.org/World/hammond/issues). This is the entry point for your contribution.
There are many ways you can contribute to GNOME Podcasts, and all of them involve creating issues
in [GNOME Podcasts issue tracker](https://gitlab.gnome.org/World/hammond/issues). This is the entry point for your contribution.
To create an effective and high quality ticket, try to put the following information on your
ticket:
@ -74,7 +74,7 @@ If it's an issue, add the steps to reproduce like this:
Steps to reproduce:
1. Open Hammond
1. Open GNOME Podcasts
2. Do an Action
3. ...

164
Cargo.lock generated
View File

@ -897,88 +897,6 @@ dependencies = [
"pkg-config 0.3.12 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "hammond-data"
version = "0.1.0"
dependencies = [
"ammonia 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
"chrono 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
"criterion 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
"derive_builder 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
"diesel 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"diesel_migrations 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"failure 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"failure_derive 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"futures 0.1.23 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.11.27 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper-tls 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
"maplit 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"native-tls 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
"num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
"pretty_assertions 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
"rand 0.5.4 (registry+https://github.com/rust-lang/crates.io-index)",
"rayon 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"rayon-futures 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"rfc822_sanitizer 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
"rss 1.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"tempdir 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
"tokio-core 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
"url 1.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
"xdg 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"xml-rs 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "hammond-downloader"
version = "0.1.0"
dependencies = [
"error-chain 0.12.0 (registry+https://github.com/rust-lang/crates.io-index)",
"failure 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"failure_derive 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
"hammond-data 0.1.0",
"hyper 0.11.27 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
"mime_guess 1.8.6 (registry+https://github.com/rust-lang/crates.io-index)",
"pretty_assertions 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
"reqwest 0.8.6 (registry+https://github.com/rust-lang/crates.io-index)",
"tempdir 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "hammond-gtk"
version = "0.1.0"
dependencies = [
"chrono 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
"crossbeam-channel 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"failure 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"failure_derive 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"gdk 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
"gdk-pixbuf 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"gio 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
"glib 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"gstreamer 0.11.4 (registry+https://github.com/rust-lang/crates.io-index)",
"gstreamer-player 0.11.3 (registry+https://github.com/rust-lang/crates.io-index)",
"gtk 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
"hammond-data 0.1.0",
"hammond-downloader 0.1.0",
"html2text 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
"humansize 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
"loggerv 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
"open 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
"pretty_assertions 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
"rayon 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"regex 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"reqwest 0.8.6 (registry+https://github.com/rust-lang/crates.io-index)",
"send-cell 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.24 (registry+https://github.com/rust-lang/crates.io-index)",
"url 1.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "handlebars"
version = "0.32.4"
@ -1562,6 +1480,88 @@ name = "pkg-config"
version = "0.3.12"
source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "podcasts-data"
version = "0.1.0"
dependencies = [
"ammonia 1.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
"chrono 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
"criterion 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
"derive_builder 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
"diesel 1.3.2 (registry+https://github.com/rust-lang/crates.io-index)",
"diesel_migrations 1.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"failure 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"failure_derive 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"futures 0.1.23 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.11.27 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper-tls 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
"maplit 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)",
"native-tls 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)",
"num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
"pretty_assertions 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
"rand 0.5.4 (registry+https://github.com/rust-lang/crates.io-index)",
"rayon 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"rayon-futures 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"rfc822_sanitizer 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)",
"rss 1.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"tempdir 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
"tokio-core 0.1.17 (registry+https://github.com/rust-lang/crates.io-index)",
"url 1.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
"xdg 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"xml-rs 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "podcasts-downloader"
version = "0.1.0"
dependencies = [
"error-chain 0.12.0 (registry+https://github.com/rust-lang/crates.io-index)",
"failure 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"failure_derive 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.11.27 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
"mime_guess 1.8.6 (registry+https://github.com/rust-lang/crates.io-index)",
"podcasts-data 0.1.0",
"pretty_assertions 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
"reqwest 0.8.6 (registry+https://github.com/rust-lang/crates.io-index)",
"tempdir 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "podcasts-gtk"
version = "0.1.0"
dependencies = [
"chrono 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
"crossbeam-channel 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"failure 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"failure_derive 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"gdk 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)",
"gdk-pixbuf 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"gio 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
"glib 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"gstreamer 0.11.4 (registry+https://github.com/rust-lang/crates.io-index)",
"gstreamer-player 0.11.3 (registry+https://github.com/rust-lang/crates.io-index)",
"gtk 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
"html2text 0.1.8 (registry+https://github.com/rust-lang/crates.io-index)",
"humansize 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)",
"loggerv 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
"open 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
"podcasts-data 0.1.0",
"podcasts-downloader 0.1.0",
"pretty_assertions 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)",
"rayon 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"regex 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)",
"reqwest 0.8.6 (registry+https://github.com/rust-lang/crates.io-index)",
"send-cell 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
"serde_json 1.0.24 (registry+https://github.com/rust-lang/crates.io-index)",
"url 1.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "precomputed-hash"
version = "0.1.1"

View File

@ -1,8 +1,8 @@
[workspace]
members = [
"hammond-data",
"hammond-downloader",
"hammond-gtk"
"podcasts-data",
"podcasts-downloader",
"podcasts-gtk"
]
[profile.release]

View File

@ -631,7 +631,7 @@ to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
Hammond
GNOME Podcasts
Copyright (C) 2017 Jordan Petridis
This program is free software: you can redistribute it and/or modify
@ -652,7 +652,7 @@ Also add information on how to contact you by electronic and paper mail.
If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:
Hammond Copyright (C) 2017 Jordan Petridis
GNOME Podcasts Copyright (C) 2017 Jordan Petridis
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.

View File

@ -1,4 +1,4 @@
# Hammond
# GNOME Podcasts
### A Podcast Client for GNOME written in Rust.
@ -8,18 +8,18 @@
## Quick start
Hammond can be built and run with [Gnome Builder](https://wiki.gnome.org/Apps/Builder) >= 3.28.
GNOME Podcasts can be built and run with [Gnome Builder](https://wiki.gnome.org/Apps/Builder) >= 3.28.
Get Builder [here](https://wiki.gnome.org/Apps/Builder/Downloads)
## Broken Feeds
Found a feed that does not work in Hammond?
Found a feed that does not work in GNOME Podcasts?
Please [open an issue](https://gitlab.gnome.org/World/hammond/issues/new) and choose the `BrokenFeed` template so we will know and fix it!
## Getting in Touch
If you have any questions regarding the use or development of Hammond,
If you have any questions regarding the use or development of GNOME Podcasts,
want to discuss design or simply hang out, please join us in `#hammond` on
[irc.gnome.org.][irc] or [matrix][matrix].
@ -31,11 +31,11 @@ There isn't much documentation yet, so you will probably have question about par
### Flatpak
Flatpak is the reccomended way of building and installing Hammond.
Flatpak is the reccomended way of building and installing GNOME Podcasts.
#### Building a Flatpak
Download the `org.gnome.Hammond.json` flatpak manifest from this repo.
Download the `org.gnome.Podcasts.json` flatpak manifest from this repo.
```bash
# Add flathub repo
@ -46,21 +46,21 @@ flatpak --user remote-add gnome-nightly --if-not-exists https://sdk.gnome.org/gn
flatpak --user install gnome-nightly org.gnome.Sdk org.gnome.Platform
# Install the required rust-stable extension from flathub
flatpak --user install flathub org.freedesktop.Sdk.Extension.rust-stable
flatpak-builder --user --repo=repo hammond org.gnome.Hammond.json --force-clean
flatpak-builder --user --repo=repo podcasts org.gnome.Podcasts.json --force-clean
```
To install the resulting flatpak you can do:
```bash
flatpak build-bundle repo hammond.flatpak org.gnome.Hammond
flatpak install --user --bundle hammond.flatpak
flatpak build-bundle repo gnome-podcasts.flatpak org.gnome.Podcasts
flatpak install --user --bundle gnome-podcasts.flatpak
```
### Building from soure
```sh
git clone https://gitlab.gnome.org/World/hammond.git
cd hammond/
cd gnome-podcasts/
meson --prefix=/usr build
ninja -C build
sudo ninja -C build install
@ -119,15 +119,15 @@ There are also some minor tasks tagged with `TODO:` and `FIXME:` in the source c
```sh
$ tree -d
├── screenshots # png's used in the README.md
├── hammond-data # Storate related stuff, SQLite, XDG setup, RSS Parser.
├── podcasts-data # Storate related stuff, SQLite, XDG setup, RSS Parser.
│   ├── migrations # Diesel SQL migrations.
│   │   └── ...
│   ├── src
│   └── tests
│   └── feeds # Raw RSS Feeds used for tests.
├── hammond-downloader # Really basic, Really crappy downloader.
├── podcasts-downloader # Really basic, Really crappy downloader.
│   └── src
├── hammond-gtk # The Gtk+ Client
├── podcasts-gtk # The Gtk+ Client
│   ├── resources # GResources folder
│   │   └── gtk # Contains the glade.ui files.
│   └── src
@ -137,13 +137,12 @@ $ tree -d
## A note about the project's name
The project was named after Allan Moore's character [Evey Hammond](https://en.wikipedia.org/wiki/Evey_Hammond) from the graphic novel V for Vendetta.
It has nothing to do with the horrible headlines on the news.
The project used to be called Hammond, after Allan Moore's character [Evey Hammond](https://en.wikipedia.org/wiki/Evey_Hammond) from the graphic novel V for Vendetta.
It was renamed to GNOME Podcasts on 2018/07/24 shortly before its first public release.
## Acknowledgments
Hammond's design is heavily insired by [GNOME Music](https://wiki.gnome.org/Design/Apps/Music) and [Vocal](http://vocalproject.net/).
GNOME Podcasts's design is heavily insired by [GNOME Music](https://wiki.gnome.org/Design/Apps/Music) and [Vocal](http://vocalproject.net/).
We also copied some elements from [GNOME News](https://wiki.gnome.org/Design/Apps/Potential/News).
@ -151,4 +150,4 @@ And almost the entirety of the build system is copied from the [Fractal](https:/
[vendor]: https://github.com/alexcrichton/cargo-vendor
[irc]: irc://irc.gnome.org/#hammond
[matrix]: https://matrix.to/#/#hammond:matrix.org
[matrix]: https://matrix.to/#/#gnome-podcasts:matrix.org

View File

@ -1,13 +0,0 @@
subdir('icons')
install_data('org.gnome.Hammond.desktop', install_dir : datadir + '/applications')
install_data('org.gnome.Hammond.appdata.xml', install_dir : datadir + '/appdata')
install_data('org.gnome.Hammond.gschema.xml', install_dir: join_paths(datadir, 'glib-2.0', 'schemas'))
configure_file(input: 'org.gnome.Hammond.service.in',
output: 'org.gnome.Hammond.service',
configuration: hammond_conf,
install_dir: join_paths([datadir,'dbus-1/services']))
meson.add_install_script('../../scripts/compile-gschema.py')

View File

@ -1,12 +0,0 @@
[Desktop Entry]
Name=Hammond
GenericName=Podcast Client
Comment=Play, Subscribe and Manage Podcast Feeds.
Icon=org.gnome.Hammond
Exec=hammond
Terminal=false
Type=Application
StartupNotify=true
Categories=AudioVideo;Audio;
Keywords=Podcast
DBusActivatable=true

View File

@ -1,3 +0,0 @@
[D-BUS Service]
Name=org.gnome.Hammond
Exec=@BINDIR@/hammond --gapplication-service

View File

@ -2,26 +2,26 @@
# https://gitlab.gnome.org/danigm/fractal/blob/6e2911f9d2353c99a18a6c19fab7f903c4bbb431/meson.build
project(
'hammond', 'rust',
'gnome-podcasts', 'rust',
version: '0.4.0',
license: 'GPLv3',
)
hammond_version = meson.project_version()
version_array = hammond_version.split('.')
hammond_major_version = version_array[0].to_int()
hammond_minor_version = version_array[1].to_int()
hammond_version_micro = version_array[2].to_int()
podcasts_version = meson.project_version()
version_array = podcasts_version.split('.')
podcasts_major_version = version_array[0].to_int()
podcasts_minor_version = version_array[1].to_int()
podcasts_version_micro = version_array[2].to_int()
hammond_prefix = get_option('prefix')
hammond_bindir = join_paths(hammond_prefix, get_option('bindir'))
podcasts_prefix = get_option('prefix')
podcasts_bindir = join_paths(podcasts_prefix, get_option('bindir'))
hammond_conf = configuration_data()
hammond_conf.set('BINDIR', hammond_bindir)
podcasts_conf = configuration_data()
podcasts_conf.set('BINDIR', podcasts_bindir)
datadir = get_option('datadir')
icondir = join_paths(datadir, 'icons')
subdir('hammond-gtk/resources')
subdir('podcasts-gtk/resources')
cargo = find_program('cargo', required: false)
gresource = find_program('glib-compile-resources', required: false)
@ -31,11 +31,11 @@ cargo_script = find_program('scripts/cargo.sh')
cargo_release = custom_target('cargo-build',
build_by_default: true,
build_always: true,
output: ['hammond'],
output: ['gnome-podcasts'],
install: true,
install_dir: hammond_bindir,
install_dir: podcasts_bindir,
command: [cargo_script, '@CURRENT_SOURCE_DIR@', '@OUTPUT@'])
run_target('release', command: ['scripts/release.sh',
meson.project_name() + '-' + hammond_version
])
meson.project_name() + '-' + podcasts_version
])

View File

@ -1,12 +1,12 @@
{
"app-id" : "org.gnome.Hammond",
"app-id" : "org.gnome.Podcasts",
"runtime" : "org.gnome.Platform",
"runtime-version" : "3.28",
"sdk" : "org.gnome.Sdk",
"sdk-extensions" : [
"org.freedesktop.Sdk.Extension.rust-stable"
],
"command" : "hammond",
"command" : "gnome-podcasts",
"tags" : [
"nightly"
],
@ -29,14 +29,14 @@
"--share=network"
],
"env" : {
"CARGO_HOME" : "/run/build/Hammond/cargo",
"CARGO_HOME" : "/run/build/Podcasts/cargo",
"RUST_BACKTRACE" : "1",
"DEBUG" : "true"
}
},
"modules" : [
{
"name" : "hammond",
"name" : "gnome-podcasts",
"buildsystem" : "meson",
"sources" : [
{

View File

@ -1,6 +1,6 @@
[package]
authors = ["Jordan Petridis <jordanpetridis@protonmail.com>"]
name = "hammond-data"
name = "podcasts-data"
version = "0.1.0"
workspace = "../"

View File

@ -5,9 +5,9 @@ extern crate criterion;
use criterion::Criterion;
// extern crate futures;
extern crate hammond_data;
extern crate hyper;
extern crate hyper_tls;
extern crate podcasts_data;
extern crate rand;
extern crate tokio_core;
// extern crate rayon;
@ -18,11 +18,11 @@ extern crate rss;
// use futures::future::*;
use tokio_core::reactor::Core;
use hammond_data::database::truncate_db;
use hammond_data::pipeline;
use hammond_data::FeedBuilder;
use hammond_data::Source;
// use hammond_data::errors::*;
use podcasts_data::database::truncate_db;
use podcasts_data::pipeline;
use podcasts_data::FeedBuilder;
use podcasts_data::Source;
// use podcasts_data::errors::*;
use std::io::BufReader;

View File

@ -24,7 +24,9 @@ lazy_static! {
#[cfg(not(test))]
lazy_static! {
static ref DB_PATH: PathBuf = xdg_dirs::HAMMOND_XDG.place_data_file("hammond.db").unwrap();
static ref DB_PATH: PathBuf = xdg_dirs::PODCASTS_XDG
.place_data_file("podcasts.db")
.unwrap();
}
#[cfg(test)]
@ -32,8 +34,8 @@ extern crate tempdir;
#[cfg(test)]
lazy_static! {
static ref TEMPDIR: tempdir::TempDir = { tempdir::TempDir::new("hammond_unit_test").unwrap() };
static ref DB_PATH: PathBuf = TEMPDIR.path().join("hammond.db");
static ref TEMPDIR: tempdir::TempDir = { tempdir::TempDir::new("podcasts_unit_test").unwrap() };
static ref DB_PATH: PathBuf = TEMPDIR.path().join("podcasts.db");
}
/// Get an r2d2 `SqliteConnection`.

View File

@ -125,28 +125,28 @@ pub mod xdg_dirs {
use xdg;
lazy_static!{
pub(crate) static ref HAMMOND_XDG: xdg::BaseDirectories = {
xdg::BaseDirectories::with_prefix("hammond").unwrap()
pub(crate) static ref PODCASTS_XDG: xdg::BaseDirectories = {
xdg::BaseDirectories::with_prefix("gnome-podcasts").unwrap()
};
/// XDG_DATA Directory `Pathbuf`.
pub static ref HAMMOND_DATA: PathBuf = {
HAMMOND_XDG.create_data_directory(HAMMOND_XDG.get_data_home()).unwrap()
pub static ref PODCASTS_DATA: PathBuf = {
PODCASTS_XDG.create_data_directory(PODCASTS_XDG.get_data_home()).unwrap()
};
/// XDG_CONFIG Directory `Pathbuf`.
pub static ref HAMMOND_CONFIG: PathBuf = {
HAMMOND_XDG.create_config_directory(HAMMOND_XDG.get_config_home()).unwrap()
pub static ref PODCASTS_CONFIG: PathBuf = {
PODCASTS_XDG.create_config_directory(PODCASTS_XDG.get_config_home()).unwrap()
};
/// XDG_CACHE Directory `Pathbuf`.
pub static ref HAMMOND_CACHE: PathBuf = {
HAMMOND_XDG.create_cache_directory(HAMMOND_XDG.get_cache_home()).unwrap()
pub static ref PODCASTS_CACHE: PathBuf = {
PODCASTS_XDG.create_cache_directory(PODCASTS_XDG.get_cache_home()).unwrap()
};
/// Hammond Download Direcotry `PathBuf`.
/// GNOME Podcasts Download Direcotry `PathBuf`.
pub static ref DL_DIR: PathBuf = {
HAMMOND_XDG.create_data_directory("Downloads").unwrap()
PODCASTS_XDG.create_data_directory("Downloads").unwrap()
};
}
}

View File

@ -1,7 +1,7 @@
diff --git a/hammond-data/src/schema.rs b/hammond-data/src/schema.rs
diff --git a/podcasts-data/src/schema.rs b/podcasts-data/src/schema.rs
index 03cbed0..88f1622 100644
--- a/hammond-data/src/schema.rs
+++ b/hammond-data/src/schema.rs
--- a/podcasts-data/src/schema.rs
+++ b/podcasts-data/src/schema.rs
@@ -1,8 +1,11 @@
+#![allow(warnings)]
+

View File

@ -174,7 +174,7 @@ mod tests {
// Clean the db
truncate_db().unwrap();
// Setup tmp file stuff
let tmp_dir = TempDir::new("hammond_test").unwrap();
let tmp_dir = TempDir::new("podcasts_test").unwrap();
let valid_path = tmp_dir.path().join("virtual_dl.mp3");
let bad_path = tmp_dir.path().join("invalid_thing.mp3");
let mut tmp_file = File::create(&valid_path).unwrap();

View File

@ -1,6 +1,6 @@
[package]
authors = ["Jordan Petridis <jordanpetridis@protonmail.com>"]
name = "hammond-downloader"
name = "podcasts-downloader"
version = "0.1.0"
workspace = "../"
@ -15,8 +15,8 @@ glob = "0.2.11"
failure = "0.1.1"
failure_derive = "0.1.1"
[dependencies.hammond-data]
path = "../hammond-data"
[dependencies.podcasts-data]
path = "../podcasts-data"
[dev-dependencies]
pretty_assertions = "0.5.1"

View File

@ -11,8 +11,8 @@ use std::io::{BufWriter, Read, Write};
use std::path::Path;
use std::sync::{Arc, Mutex};
use hammond_data::xdg_dirs::HAMMOND_CACHE;
use hammond_data::{EpisodeWidgetModel, Save, ShowCoverModel};
use podcasts_data::xdg_dirs::PODCASTS_CACHE;
use podcasts_data::{EpisodeWidgetModel, Save, ShowCoverModel};
// use failure::Error;
use errors::DownloadError;
@ -78,7 +78,7 @@ fn download_into(
// Construct a temp file to save desired content.
// It has to be a `new_in` instead of new cause rename can't move cross
// filesystems.
let tempdir = TempDir::new_in(HAMMOND_CACHE.to_str().unwrap(), "temp_download")?;
let tempdir = TempDir::new_in(PODCASTS_CACHE.to_str().unwrap(), "temp_download")?;
let out_file = format!("{}/temp.part", tempdir.path().to_str().unwrap(),);
ct_len.map(|x| {
@ -206,7 +206,7 @@ pub fn cache_image(pd: &ShowCoverModel) -> Result<String, DownloadError> {
return Err(DownloadError::NoImageLocation);
}
let cache_path = HAMMOND_CACHE
let cache_path = PODCASTS_CACHE
.to_str()
.ok_or_else(|| DownloadError::InvalidCacheLocation)?;
let cache_download_fold = format!("{}{}", cache_path, pd.title().to_owned());
@ -236,14 +236,14 @@ pub fn cache_image(pd: &ShowCoverModel) -> Result<String, DownloadError> {
#[cfg(test)]
mod tests {
use super::*;
use hammond_data::dbqueries;
use hammond_data::pipeline;
use hammond_data::Source;
use podcasts_data::dbqueries;
use podcasts_data::pipeline;
use podcasts_data::Source;
use std::fs;
#[test]
// This test inserts an rss feed to your `XDG_DATA/hammond/hammond.db` so we make it explicit
// This test inserts an rss feed to your `XDG_DATA/podcasts/podcasts.db` so we make it explicit
// to run it.
#[ignore]
fn test_cache_image() {
@ -261,7 +261,7 @@ mod tests {
let img_path = cache_image(&pd);
let foo_ = format!(
"{}{}/cover.jpeg",
HAMMOND_CACHE.to_str().unwrap(),
PODCASTS_CACHE.to_str().unwrap(),
pd.title()
);
assert_eq!(img_path.unwrap(), foo_);

View File

@ -1,4 +1,4 @@
use hammond_data::errors::DataError;
use podcasts_data::errors::DataError;
use reqwest;
use std::io;

View File

@ -44,9 +44,9 @@ extern crate log;
extern crate pretty_assertions;
extern crate glob;
extern crate hammond_data;
extern crate hyper;
extern crate mime_guess;
extern crate podcasts_data;
extern crate reqwest;
extern crate tempdir;

View File

@ -1,7 +1,7 @@
[package]
authors = ["Jordan Petridis <jordanpetridis@protonmail.com>"]
build = "build.rs"
name = "hammond-gtk"
name = "podcasts-gtk"
version = "0.1.0"
workspace = "../"
@ -36,11 +36,11 @@ version = "0.4.1"
features = ["v2_50"]
version = "0.4.1"
[dependencies.hammond-data]
path = "../hammond-data"
[dependencies.podcasts-data]
path = "../podcasts-data"
[dependencies.hammond-downloader]
path = "../hammond-downloader"
[dependencies.podcasts-downloader]
path = "../podcasts-downloader"
[dev-dependencies]
pretty_assertions = "0.5.1"

View File

@ -18,7 +18,7 @@
id="svg11300"
sodipodi:version="0.32"
inkscape:version="0.92.3 (2405546, 2018-03-11)"
sodipodi:docname="org.gnome.Hammond.svg"
sodipodi:docname="org.gnome.Podcasts.svg"
inkscape:output_extension="org.inkscape.output.svg.inkscape"
version="1.0"
style="display:inline;enable-background:new"
@ -471,7 +471,7 @@
x="7.7533054"
id="tspan3023"
sodipodi:role="line"
style="stroke-width:0.33264872">org.gnome.Hammond</tspan></text>
style="stroke-width:0.33264872">org.gnome.Podcasts</tspan></text>
<g
style="display:inline;fill:#000000;enable-background:new"
transform="matrix(7.9911709,0,0,8.0036407,-167.7909,-4846.0776)"

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 22 KiB

View File

@ -12,7 +12,7 @@
version="1.1"
id="svg7384"
height="16"
sodipodi:docname="org.gnome.Hammond-symbolic.svg"
sodipodi:docname="org.gnome.Podcasts-symbolic.svg"
inkscape:version="0.92.3 (2405546, 2018-03-11)">
<sodipodi:namedview
pagecolor="#ffffff"

Before

Width:  |  Height:  |  Size: 2.7 KiB

After

Width:  |  Height:  |  Size: 2.7 KiB

View File

Before

Width:  |  Height:  |  Size: 6.1 KiB

After

Width:  |  Height:  |  Size: 6.1 KiB

View File

Before

Width:  |  Height:  |  Size: 6.1 KiB

After

Width:  |  Height:  |  Size: 6.1 KiB

View File

@ -0,0 +1,13 @@
subdir('icons')
install_data('org.gnome.Podcasts.desktop', install_dir : datadir + '/applications')
install_data('org.gnome.Podcasts.appdata.xml', install_dir : datadir + '/appdata')
install_data('org.gnome.Podcasts.gschema.xml', install_dir: join_paths(datadir, 'glib-2.0', 'schemas'))
configure_file(input: 'org.gnome.Podcasts.service.in',
output: 'org.gnome.Podcasts.service',
configuration: podcasts_conf,
install_dir: join_paths([datadir,'dbus-1/services']))
meson.add_install_script('../../scripts/compile-gschema.py')

View File

@ -1,14 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<component type="desktop">
<id>org.gnome.Hammond</id>
<name>Hammond</name>
<id>org.gnome.Podcasts</id>
<name>Podcasts</name>
<project_license>GPL-3.0</project_license>
<metadata_license>CC0-1.0</metadata_license>
<developer_name>Jordan Petridis</developer_name>
<summary>Modern Podcast application for the GNOME desktop</summary>
<description xml:lang="en">
<p>
Hammond is a modern, reliable, and fast Podcast application for the GNOME
Podcasts is a modern, reliable, and fast Podcast application for the GNOME
desktop written in Rust.
</p>
</description>

View File

@ -0,0 +1,11 @@
[Desktop Entry]
Name=Podcasts
Comment=Listen to your favorite podcasts, right from your desktop.
Icon=org.gnome.Podcasts
Exec=gnome-podcasts
Terminal=false
Type=Application
StartupNotify=true
Categories=GNOME;GTK;AudioVideo;Audio;
Keywords=Podcast;RSS;
DBusActivatable=true

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<schemalist>
<enum id="org.gnome.Hammond.timePeriods">
<enum id="org.gnome.Podcasts.timePeriods">
<value nick="seconds" value="1"/>
<value nick="minutes" value="2"/>
<value nick="hours" value="3"/>
@ -9,7 +9,7 @@
<value nick="months" value="6"/>
</enum>
<schema path="/org/gnome/hammond/" id="org.gnome.Hammond">
<schema path="/org/gnome/Podcasts/" id="org.gnome.Podcasts">
<key name="persist-window-geometry-top" type="i">
<default>-1</default>
<summary>Top position of the last open main window</summary>
@ -45,7 +45,7 @@
<default>1</default>
<summary>How many periods of time to wait between automatic refreshes</summary>
</key>
<key name="refresh-interval-period" enum="org.gnome.Hammond.timePeriods">
<key name="refresh-interval-period" enum="org.gnome.Podcasts.timePeriods">
<default>'hours'</default>
<summary>What period of time to wait between automatic refreshes</summary>
</key>
@ -59,7 +59,7 @@
<default>2</default>
<summary>How many periods of time to wait between automatic cleanups</summary>
</key>
<key name="cleanup-age-period" enum="org.gnome.Hammond.timePeriods">
<key name="cleanup-age-period" enum="org.gnome.Podcasts.timePeriods">
<default>'days'</default>
<summary>What period of time to wait between automatic cleanups</summary>
</key>

View File

@ -0,0 +1,3 @@
[D-BUS Service]
Name=org.gnome.Podcasts
Exec=@BINDIR@/gnome-podcasts --gapplication-service

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<gresources>
<gresource prefix="/org/gnome/Hammond/">
<gresource prefix="/org/gnome/Podcasts/">
<file compressed="true" preprocess="xml-stripblanks">gtk/episode_widget.ui</file>
<file compressed="true" preprocess="xml-stripblanks">gtk/show_widget.ui</file>
<file compressed="true" preprocess="xml-stripblanks">gtk/empty_view.ui</file>

View File

@ -6,7 +6,7 @@ use gtk;
use gtk::prelude::*;
use crossbeam_channel::{unbounded, Receiver, Sender};
use hammond_data::Show;
use podcasts_data::Show;
use send_cell::SendCell;
use headerbar::Header;
@ -23,6 +23,8 @@ use std::env;
use std::rc::Rc;
use std::sync::Arc;
pub const APP_ID: &str = "org.gnome.Podcasts";
/// Creates an action named $called in the action map $on with the handler $handle
macro_rules! action {
($on:expr, $called:expr, $handle:expr) => {{
@ -73,12 +75,12 @@ pub struct App {
impl App {
pub fn new(application: &gtk::Application) -> Rc<Self> {
let settings = gio::Settings::new("org.gnome.Hammond");
let settings = gio::Settings::new(APP_ID);
let (sender, receiver) = unbounded();
let window = gtk::ApplicationWindow::new(application);
window.set_title("Hammond");
window.set_title("Podcasts");
window.connect_delete_event(clone!(settings => move |window, _| {
WindowGeometry::from_window(&window).write(&settings);
Inhibit(false)
@ -293,7 +295,7 @@ impl App {
}
pub fn run() {
let application = gtk::Application::new("org.gnome.Hammond", ApplicationFlags::empty())
let application = gtk::Application::new(APP_ID, ApplicationFlags::empty())
.expect("Application Initialization failed...");
application.connect_startup(clone!(application => move |_| {
@ -309,9 +311,9 @@ impl App {
}));
// Weird magic I copy-pasted that sets the Application Name in the Shell.
glib::set_application_name("Hammond");
glib::set_prgname(Some("Hammond"));
gtk::Window::set_default_icon_name("org.gnome.Hammond");
glib::set_application_name("Podcasts");
glib::set_prgname(Some("gnome-podcasts"));
gtk::Window::set_default_icon_name(APP_ID);
let args: Vec<String> = env::args().collect();
ApplicationExtManual::run(&application, &args);
}

View File

@ -7,7 +7,7 @@ use failure::Error;
use rayon;
use url::Url;
use hammond_data::{dbqueries, Source};
use podcasts_data::{dbqueries, Source};
use app::Action;
use stacks::Content;
@ -140,8 +140,8 @@ impl AddPopover {
impl Default for Header {
fn default() -> Header {
let builder = gtk::Builder::new_from_resource("/org/gnome/Hammond/gtk/headerbar.ui");
let menus = gtk::Builder::new_from_resource("/org/gnome/Hammond/gtk/hamburger.ui");
let builder = gtk::Builder::new_from_resource("/org/gnome/Podcasts/gtk/headerbar.ui");
let menus = gtk::Builder::new_from_resource("/org/gnome/Podcasts/gtk/hamburger.ui");
let header = builder.get_object("headerbar").unwrap();
let switch = builder.get_object("switch").unwrap();

View File

@ -60,12 +60,12 @@ extern crate pretty_assertions;
extern crate chrono;
extern crate crossbeam_channel;
extern crate hammond_data;
extern crate hammond_downloader;
extern crate html2text;
extern crate humansize;
extern crate loggerv;
extern crate open;
extern crate podcasts_data;
extern crate podcasts_downloader;
extern crate rayon;
extern crate regex;
extern crate reqwest;
@ -119,7 +119,7 @@ fn main() {
// Add custom style
let provider = gtk::CssProvider::new();
gtk::CssProvider::load_from_resource(&provider, "/org/gnome/Hammond/gtk/style.css");
gtk::CssProvider::load_from_resource(&provider, "/org/gnome/Podcasts/gtk/style.css");
gtk::StyleContext::add_provider_for_screen(
&gdk::Screen::get_default().expect("Error initializing gtk css provider."),
&provider,

View File

@ -1,9 +1,9 @@
use failure::Error;
use rayon;
// use hammond_data::Episode;
use hammond_data::dbqueries;
use hammond_downloader::downloader::{get_episode, DownloadProgress};
// use podcasts_data::Episode;
use podcasts_data::dbqueries;
use podcasts_downloader::downloader::{get_episode, DownloadProgress};
use std::collections::HashMap;
use std::sync::{Arc, Mutex, RwLock};
@ -110,19 +110,19 @@ pub fn add(id: i32, directory: String) -> Result<(), Error> {
mod tests {
use super::*;
use hammond_data::dbqueries;
use hammond_data::pipeline;
use hammond_data::utils::get_download_folder;
use hammond_data::{Episode, Source};
use podcasts_data::dbqueries;
use podcasts_data::pipeline;
use podcasts_data::utils::get_download_folder;
use podcasts_data::{Episode, Source};
use hammond_downloader::downloader::get_episode;
use podcasts_downloader::downloader::get_episode;
use std::fs;
use std::path::Path;
use std::{thread, time};
#[test]
// This test inserts an rss feed to your `XDG_DATA/hammond/hammond.db` so we make it explicit
// This test inserts an rss feed to your `XDG_DATA/podcasts/podcasts.db` so we make it explicit
// to run it.
#[ignore]
// THIS IS NOT A RELIABLE TEST

View File

@ -13,7 +13,7 @@ pub struct Prefs {
impl Default for Prefs {
fn default() -> Prefs {
let builder = gtk::Builder::new_from_resource("/org/gnome/Hammond/gtk/prefs.ui");
let builder = gtk::Builder::new_from_resource("/org/gnome/Podcasts/gtk/prefs.ui");
let dialog = builder.get_object("prefs").unwrap();
let dark_toggle = builder.get_object("dark_toggle").unwrap();

View File

@ -4,8 +4,8 @@ use gtk::StackTransitionType;
use crossbeam_channel::Sender;
use failure::Error;
use hammond_data::dbqueries::is_episodes_populated;
use hammond_data::errors::DataError;
use podcasts_data::dbqueries::is_episodes_populated;
use podcasts_data::errors::DataError;
use app::Action;
use widgets::{EmptyView, HomeView};

View File

@ -5,8 +5,8 @@ use gtk::StackTransitionType;
use crossbeam_channel::Sender;
use failure::Error;
use hammond_data::dbqueries;
use hammond_data::Show;
use podcasts_data::dbqueries;
use podcasts_data::Show;
use app::Action;
use widgets::{ShowWidget, ShowsView};

View File

@ -3,7 +3,7 @@ use gtk::prelude::*;
use crossbeam_channel::Sender;
use failure::Error;
use hammond_data::dbqueries::is_podcasts_populated;
use podcasts_data::dbqueries::is_podcasts_populated;
use app::Action;
use stacks::PopulatedStack;

View File

@ -16,13 +16,13 @@ use reqwest;
use send_cell::SendCell;
use serde_json::Value;
// use hammond_data::feed;
use hammond_data::dbqueries;
use hammond_data::opml;
use hammond_data::pipeline;
use hammond_data::utils::checkup;
use hammond_data::Source;
use hammond_downloader::downloader;
// use podcasts_data::feed;
use podcasts_data::dbqueries;
use podcasts_data::opml;
use podcasts_data::pipeline;
use podcasts_data::utils::checkup;
use podcasts_data::Source;
use podcasts_downloader::downloader;
use std::collections::{HashMap, HashSet};
use std::sync::{Arc, Mutex, RwLock};
@ -374,11 +374,11 @@ pub fn on_import_clicked(window: &gtk::ApplicationWindow, sender: &Sender<Action
#[cfg(test)]
mod tests {
use super::*;
// use hammond_data::Source;
// use hammond_data::dbqueries;
// use podcasts_data::Source;
// use podcasts_data::dbqueries;
// #[test]
// This test inserts an rss feed to your `XDG_DATA/hammond/hammond.db` so we make it explicit
// This test inserts an rss feed to your `XDG_DATA/podcasts/podcasts.db` so we make it explicit
// to run it.
// #[ignore]
// Disabled till https://gitlab.gnome.org/World/hammond/issues/56

Some files were not shown because too many files have changed in this diff Show More