Skip to content

Commit

Permalink
Fix launching on Ubuntu Touch 20.04
Browse files Browse the repository at this point in the history
APP_DIR is no longer an environment variable that can be used, but
current working directory does the same job so use it instead.
  • Loading branch information
JamiKettunen committed Feb 1, 2023
1 parent a860f9a commit 4b20691
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,7 @@ fn init_gettext() {
let domain = "webber.timsueberkrueb";
textdomain(domain).expect("Failed to setup gettext domain");

let app_dir = env::var("APP_DIR").expect("Failed to read the APP_DIR environment variable");

let mut app_dir_path = PathBuf::from(app_dir);
let mut app_dir_path = env::current_dir().expect("Failed to get the app working directory");
if !app_dir_path.is_absolute() {
app_dir_path = PathBuf::from("/usr");
}
Expand Down

0 comments on commit 4b20691

Please sign in to comment.