Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ndk-build,cargo-apk: Rename intent_filters back to intent_filter #305

Merged
merged 1 commit into from
Jul 5, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions cargo-apk/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Unreleased

# 0.9.3 (2022-07-05)

- Allow configuration of alternate debug keystore location; require keystore location for release builds. ([#299](https://github.com/rust-windowing/android-ndk-rs/pull/299))
- **Breaking:** Rename `Activity::intent_filters` back to `Activity::intent_filter`. ([#305](https://github.com/rust-windowing/android-ndk-rs/pull/305))

# 0.9.2 (2022-06-11)

Expand Down
4 changes: 2 additions & 2 deletions cargo-apk/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "cargo-apk"
version = "0.9.2"
version = "0.9.3"
authors = ["The Rust Windowing contributors"]
edition = "2018"
description = "Helps cargo build APKs"
Expand All @@ -16,7 +16,7 @@ cargo-subcommand = "0.7"
dunce = "1"
env_logger = "0.9"
log = "0.4"
ndk-build = { path = "../ndk-build", version = "0.6.0" }
ndk-build = { path = "../ndk-build", version = "0.7.0" }
serde = "1"
thiserror = "1.0.31"
toml = "0.5"
4 changes: 2 additions & 2 deletions cargo-apk/src/apk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,11 @@ impl<'a> ApkBuilder<'a> {

// Add a default `MAIN` action to launch the activity, if the user didn't supply it by hand.
if activity
.intent_filters
.intent_filter
.iter()
.all(|i| i.actions.iter().all(|f| f != "android.intent.action.MAIN"))
{
activity.intent_filters.push(IntentFilter {
activity.intent_filter.push(IntentFilter {
actions: vec!["android.intent.action.MAIN".to_string()],
categories: vec!["android.intent.category.LAUNCHER".to_string()],
data: vec![],
Expand Down
5 changes: 4 additions & 1 deletion ndk-build/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
# Unreleased

- Allow NDK r23 `-lgcc` workaround to work for target directories containing spaces. ([#298](https://github.com/rust-windowing/android-ndk-rs/pull/298))
# 0.7.0 (2022-07-05)

- Fix NDK r23 `-lgcc` workaround for target directories containing spaces. ([#298](https://github.com/rust-windowing/android-ndk-rs/pull/298))
- Invoke `clang` directly instead of through the NDK's wrapper scripts. ([#306](https://github.com/rust-windowing/android-ndk-rs/pull/306))
- **Breaking:** Rename `Activity::intent_filters` back to `Activity::intent_filter`. ([#305](https://github.com/rust-windowing/android-ndk-rs/pull/305))

# 0.6.0 (2022-06-11)

Expand Down
2 changes: 1 addition & 1 deletion ndk-build/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "ndk-build"
version = "0.6.0"
version = "0.7.0"
authors = ["The Rust Windowing contributors"]
edition = "2018"
description = "Utilities for building Android binaries"
Expand Down
6 changes: 3 additions & 3 deletions ndk-build/src/manifest.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,10 @@ pub struct Activity {
#[serde(rename(serialize = "meta-data"))]
#[serde(default)]
pub meta_data: Vec<MetaData>,
/// If no `MAIN` action exists in any intent filter, a default `MAIN` filter is serialized.
/// If no `MAIN` action exists in any intent filter, a default `MAIN` filter is serialized by `cargo-apk`.
#[serde(rename(serialize = "intent-filter"))]
#[serde(default)]
pub intent_filters: Vec<IntentFilter>,
pub intent_filter: Vec<IntentFilter>,
}

impl Default for Activity {
Expand All @@ -122,7 +122,7 @@ impl Default for Activity {
orientation: None,
exported: None,
meta_data: Default::default(),
intent_filters: Default::default(),
intent_filter: Default::default(),
}
}
}
Expand Down