diff options
| author | Thorsten Töpper <atsutane@freethoughts.de> | 2025-08-02 00:02:57 +0200 |
|---|---|---|
| committer | Thorsten Töpper <atsutane@freethoughts.de> | 2025-08-02 00:02:57 +0200 |
| commit | 31aaaca68b15fab61bf8a5e2b0187111fae27f46 (patch) | |
| tree | cf79e58e336d34d2feba574e2cc0906b84e8ce32 /include | |
| parent | d4aa1654b0136d226cf23135888077468c8e8451 (diff) | |
| download | dir_monitor-31aaaca68b15fab61bf8a5e2b0187111fae27f46.tar.gz dir_monitor-31aaaca68b15fab61bf8a5e2b0187111fae27f46.tar.bz2 | |
symlinks: destination can be resolved
Diffstat (limited to 'include')
| -rw-r--r-- | include/data_management.h | 5 | ||||
| -rw-r--r-- | include/options.h | 1 |
2 files changed, 6 insertions, 0 deletions
diff --git a/include/data_management.h b/include/data_management.h index a8d3648..3283e02 100644 --- a/include/data_management.h +++ b/include/data_management.h @@ -8,6 +8,7 @@ #ifndef LIST_MANAGEMENT_H #define LIST_MANAGEMENT_H +#include <stdbool.h> #include <sys/stat.h> /* === DEFINITIONS === */ @@ -15,6 +16,7 @@ struct list_node { struct list_node *next; char fname[256]; + char *symlink_target; struct stat ln_stat; }; @@ -27,10 +29,13 @@ struct list_head *create_list_sort_reversed(struct list_head *list); void destroy_list(struct list_head *list); struct list_head *get_data_from_directory(char *path); +char *get_symlink_target_name(char *symlink, struct stat st); int insert_sorted_by_name(struct list_head *list, struct list_node *node); int insert_sorted_by_size(struct list_head *list, struct list_node *node); int insert_sorted_by_time(struct list_head *list, struct list_node *node); +/* Makes it simpler in the output */ +bool contains_resolved_symlinks(struct list_head *list); #endif diff --git a/include/options.h b/include/options.h index c62474d..cae9aa0 100644 --- a/include/options.h +++ b/include/options.h @@ -30,6 +30,7 @@ extern bool option_sort_reverse_order; extern enum esort_type option_sort_type; extern bool option_print_boxed_table; extern bool option_print_header; +extern bool option_resolve_symlinks; extern bool option_show_hidden_entries; extern bool option_timestamp_long; extern char option_time_field; |
