Skip to content

Commit 88a083f

Browse files
Change: use uzers fork of users
1 parent 7fcc230 commit 88a083f

File tree

3 files changed

+15
-15
lines changed

3 files changed

+15
-15
lines changed

Cargo.lock

Lines changed: 11 additions & 11 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ version = "0.28.0"
8888
features = ["signal"]
8989

9090
[target.'cfg(unix)'.dependencies]
91-
users = "0.11.0"
91+
uzers = "0.12.2"
9292
flate2 = "1.0.26"
9393
tar = "0.4"
9494

src/helpers/directories.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use anyhow::{Result, anyhow};
22
use std::fs;
33
use std::path::PathBuf;
44
#[cfg(unix)]
5-
use users::os::unix::UserExt;
5+
use uzers::os::unix::UserExt;
66

77
use crate::config::Config;
88

@@ -24,7 +24,7 @@ use crate::config::Config;
2424
fn get_local_data_dir() -> Result<PathBuf> {
2525
#[cfg(unix)]
2626
if let Ok(sudo_user) = std::env::var("SUDO_USER") {
27-
if let Some(user_info) = users::get_user_by_name(&sudo_user) {
27+
if let Some(user_info) = uzers::get_user_by_name(&sudo_user) {
2828
let mut home: PathBuf = user_info.home_dir().into();
2929
if cfg!(target_os = "macos") {
3030
home.push("Library/Application Support");
@@ -64,7 +64,7 @@ pub fn get_config_file() -> Result<PathBuf> {
6464
let mut dir = None;
6565
#[cfg(unix)]
6666
if let Ok(sudo_user) = std::env::var("SUDO_USER") {
67-
if let Some(user_info) = users::get_user_by_name(&sudo_user) {
67+
if let Some(user_info) = uzers::get_user_by_name(&sudo_user) {
6868
let mut home: PathBuf = user_info.home_dir().into();
6969
if cfg!(target_os = "macos") {
7070
home.push("Library/Application Support");

0 commit comments

Comments
 (0)