Skip to content
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
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "omamail"
version = "0.10.4"
version = "0.10.5"
edition = "2024"
publish = false

Expand Down
2 changes: 1 addition & 1 deletion app/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cmake_minimum_required(VERSION 3.21)

project(omamail-app VERSION 0.10.4 LANGUAGES CXX)
project(omamail-app VERSION 0.10.5 LANGUAGES CXX)

if(WIN32)
enable_language(RC)
Expand Down
52 changes: 39 additions & 13 deletions backend-api.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"apiVersion": 5,
"releasedApiVersion": 4,
"releasedApiVersion": 5,
"protocolVersion": 1,
"methods": [
"system.info",
Expand Down Expand Up @@ -187,11 +187,18 @@
"name": "iCloud request refuses an external credential origin",
"method": "calendar.request",
"params": {
"source": {"kind": "icloud", "accountId": "imap:missing@icloud.com", "url": "https://example.org/calendar/"},
"operation": "list", "body": "report"
"source": {
"kind": "icloud",
"accountId": "imap:missing@icloud.com",
"url": "https://example.org/calendar/"
},
"operation": "list",
"body": "report"
},
"errorCode": -32000,
"equals": {"message": "calendar_origin_refused"}
"equals": {
"message": "calendar_origin_refused"
}
},
{
"name": "strict calendar discovery parameters",
Expand Down Expand Up @@ -722,21 +729,40 @@
{
"name": "gmail message mutation answers with a queue ticket",
"method": "gmail.trash",
"params": {"accountId": "contract@example.org", "id": "contract-message"},
"equals": {"queued": true},
"types": {"ticket": "string"}
"params": {
"accountId": "contract@example.org",
"id": "contract-message"
},
"equals": {
"queued": true
},
"types": {
"ticket": "string"
}
},
{
"name": "gmail batch mutation answers with a queue ticket",
"method": "gmail.batchModify",
"params": {"accountId": "contract@example.org", "ids": ["contract-message"], "addLabelIds": ["STARRED"], "removeLabelIds": []},
"equals": {"queued": true},
"types": {"ticket": "string"}
"params": {
"accountId": "contract@example.org",
"ids": [
"contract-message"
],
"addLabelIds": [
"STARRED"
],
"removeLabelIds": []
},
"equals": {
"queued": true
},
"types": {
"ticket": "string"
}
}
],
"unreleased": {
"methods": ["outlook.connectionCheck", "calendar.discover"],
"cases": ["missing Outlook connection", "strict calendar discovery parameters", "iCloud request refuses an external credential origin",
"gmail message mutation answers with a queue ticket", "gmail batch mutation answers with a queue ticket"]
"methods": [],
"cases": []
}
}
2 changes: 1 addition & 1 deletion backend-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.10.4
0.10.5
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"schemaVersion": 1,
"id": "omamail",
"name": "Omamail",
"version": "0.10.4",
"version": "0.10.5",
"author": "huacnlee",
"license": "MIT",
"homepage": "https://huacnlee.github.io/omamail/",
Expand Down
21 changes: 18 additions & 3 deletions tests/message_charset.rs
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,18 @@ fn nested_mime_and_attachment_bytes_are_preserved() {
);
}

// The registry lives where the platform contract puts it: macOS reads
// ~/Library/Application Support and ignores XDG_CONFIG_HOME.
#[cfg(target_os = "macos")]
fn config_root(root: &std::path::Path) -> std::path::PathBuf {
root.join("Library/Application Support")
}
#[cfg(all(unix, not(target_os = "macos")))]
fn config_root(root: &std::path::Path) -> std::path::PathBuf {
root.join("config")
}

#[cfg(unix)]
#[test]
fn cached_reader_redecodes_original_octets_instead_of_reusing_mojibake() {
use std::{
Expand All @@ -203,7 +215,9 @@ fn cached_reader_redecodes_original_octets_instead_of_reusing_mojibake() {
os::unix::fs::PermissionsExt,
process::{Command, Stdio},
};
let root = std::env::temp_dir().join(format!(
// macOS puts TMPDIR under /var, a symlink the private_fs path walk
// refuses (O_NOFOLLOW), so resolve it first like the other CLI tests.
let root = std::env::temp_dir().canonicalize().unwrap().join(format!(
"omamail-charset-cache-{}-{}",
std::process::id(),
std::time::SystemTime::now()
Expand All @@ -220,9 +234,10 @@ fn cached_reader_redecodes_original_octets_instead_of_reusing_mojibake() {
}
}
let _cleanup = Cleanup(root.clone());
let registry = root.join("config/omamail/accounts.json");
let config = config_root(&root);
let registry = config.join("omamail/accounts.json");
fs::create_dir_all(registry.parent().unwrap()).unwrap();
fs::set_permissions(root.join("config"), fs::Permissions::from_mode(0o700)).unwrap();
fs::set_permissions(&config, fs::Permissions::from_mode(0o700)).unwrap();
fs::set_permissions(
registry.parent().unwrap(),
fs::Permissions::from_mode(0o700),
Expand Down
Loading