Skip to content
Open
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
1 change: 1 addition & 0 deletions src/constants.vala.in
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
public class Constants {
public const string VERSION = @VERSION@;
public const string VERSIONNUM = @VERSION_NUM@;
public const string CONFIGPATH = @CONFIG_PATH@;
public const uint ANIMATION_DURATION = 400;
}
6 changes: 4 additions & 2 deletions src/functions.vala
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,8 @@ namespace SwayNotificationCenter {
path, "swaync/style.css");
}
// Fallback location. Specified in postinstall.py. Mostly for Debian
paths += "/usr/local/etc/xdg/swaync/style.css";
paths += Path.build_path (Path.DIR_SEPARATOR.to_string (),
Constants.CONFIGPATH, "style.css");

info ("Looking for CSS file in these directories:\n\t- %s",
string.joinv ("\n\t- ", paths));
Expand Down Expand Up @@ -187,7 +188,8 @@ namespace SwayNotificationCenter {
path, "swaync/config.json");
}
// Fallback location. Specified in postinstall.py. Mostly for Debian
paths += "/usr/local/etc/xdg/swaync/config.json";
paths += Path.build_path (Path.DIR_SEPARATOR.to_string (),
Constants.CONFIGPATH, "config.json");

info ("Looking for config file in these directories:\n\t- %s",
string.joinv ("\n\t- ", paths));
Expand Down
1 change: 1 addition & 0 deletions src/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ version = 'swaync @0@'.format(version)
const_config_data = configuration_data()
const_config_data.set_quoted('VERSION', version)
const_config_data.set_quoted('VERSION_NUM', meson.project_version())
const_config_data.set_quoted('CONFIG_PATH', join_paths(get_option('prefix'), config_path))
constants = configure_file(
input : 'constants.vala.in',
output : 'constants.vala',
Expand Down
Loading