added end-4's ags config
This commit is contained in:
parent
4fcc76a32c
commit
41595493a3
180 changed files with 23456 additions and 13 deletions
14
homes/me/ags/modules/.miscutils/files.js
Normal file
14
homes/me/ags/modules/.miscutils/files.js
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
const { Gio, GLib, Gtk } = imports.gi;
|
||||
|
||||
export function fileExists(filePath) {
|
||||
let file = Gio.File.new_for_path(filePath);
|
||||
return file.query_exists(null);
|
||||
}
|
||||
|
||||
export function expandTilde(path) {
|
||||
if (path.startsWith('~')) {
|
||||
return GLib.get_home_dir() + path.slice(1);
|
||||
} else {
|
||||
return path;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue