diff options
| author | El-BG-1970 <elouan.gros.fr@gmail.com> | 2022-03-16 19:52:55 +0100 |
|---|---|---|
| committer | El-BG-1970 <elouan.gros.fr@gmail.com> | 2022-03-16 19:52:55 +0100 |
| commit | 3b0ea80811a1c939e0b1b97e0f8e34dabd54717f (patch) | |
| tree | 5c794cafac56f00946dfeb99b098d775bd89a8bb /main.c | |
| parent | bbbb16b98e64644eb2852d9fc8b81fa0b62f4013 (diff) | |
| download | org-to-conky-3b0ea80811a1c939e0b1b97e0f8e34dabd54717f.tar.gz | |
better compartimentalization
Diffstat (limited to 'main.c')
| -rw-r--r-- | main.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -79,7 +79,7 @@ int main(int argc, char **argv) { char *e; Date td = today(); Date tm = tomorrow(td); - Date nw = nextweek(td); + Date end = nextmonth(td); Date last_date = (struct Date){ -1, -1, -1 }; for (int i = 0; i < idx; i++) { if (!eql(agenda[i].date, last_date)) { @@ -92,7 +92,7 @@ int main(int argc, char **argv) { printf("\n%s [TODAY]:\n", e); else if (eql(last_date, tm)) printf("\n%s [TOMORROW]:\n", e); - else if (smaller(last_date, nw)) + else if (smaller(last_date, end)) printf("\n%s:\n", e); free(e); } else { @@ -100,7 +100,7 @@ int main(int argc, char **argv) { } } e = format_entry(agenda[i]); - if (zero(agenda[i].date) || smaller(agenda[i].date, nw)) puts(e); + if (zero(agenda[i].date) || smaller(agenda[i].date, end)) puts(e); free(e); } |
