Skip to content

Commit 3d0d162

Browse files
committed
test ci
1 parent 78d6834 commit 3d0d162

1 file changed

Lines changed: 13 additions & 12 deletions

File tree

src-tauri/src/lib.rs

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
// FIXME: actually refactor errors instead
22
#![allow(clippy::result_large_err)]
33
use std::{fmt, path::PathBuf};
4-
#[cfg(not(windows))]
5-
use std::{
6-
fs::{set_permissions, Permissions},
7-
os::unix::fs::PermissionsExt,
8-
};
4+
// #[cfg(not(windows))]
5+
// use std::{
6+
// fs::{set_permissions, Permissions},
7+
// os::unix::fs::PermissionsExt,
8+
// };
99

1010
use chrono::NaiveDateTime;
1111
use semver::Version;
@@ -86,13 +86,14 @@ pub fn app_data_dir() -> Option<PathBuf> {
8686
/// - 700 for directories
8787
/// - 600 for files
8888
pub fn set_perms(path: &PathBuf) {
89-
#[cfg(not(windows))]
90-
{
91-
let perms = if path.is_dir() { 0o700 } else { 0o600 };
92-
if let Err(err) = set_permissions(path, Permissions::from_mode(perms)) {
93-
warn!("Failed to set permissions on path {path:?}: {err}");
94-
}
95-
}
89+
90+
// #[cfg(not(windows))]
91+
// {
92+
// let perms = if path.is_dir() { 0o700 } else { 0o600 };
93+
// if let Ok(metadata) = path.metadata() {
94+
// metadata.permissions().set_mode(perms)
95+
// };
96+
// }
9697
}
9798

9899
/// Location type used in commands to check if we using tunnel or location

0 commit comments

Comments
 (0)