andrewbrereton / obsidian-to-ical-plugin

This is a plugin for Obsidian that searches your vault for tasks that contain dates, and generates a calendar in iCal format that can be imported into your preferred calendar application.
MIT License
52 stars 8 forks source link

[feature] Distinguish between scheduled tasks and tasks with a deadline #28

Open bepolymathe opened 7 months ago

bepolymathe commented 7 months ago

Hi,

In my day-to-day work I have tasks that start and tasks that finish. At present, they are all presented with the following emoji 🔲

I'd find it very useful to be able to distinguish between them (either visually, or in the description) ?

andrewbrereton commented 7 months ago

Could you please include what the source markdown looks like? I suspect it might be a parsing issue so I'd like to text my regular expressions against it. Thanks

bepolymathe commented 7 months ago

Hi @andrewbrereton

Yes of course. It looks like this...

BEGIN:VCALENDAR
VERSION:2.0
PRODID:-//Andrew Brereton//obsidian-ical-plugin v1.9.0//EN
X-WR-CALNAME:Obsidian Calendar
NAME:Obsidian Calendar
CALSCALE:GREGORIAN
BEGIN:VEVENT
UID:8cf9ec77-61c7-4b43-9025-1bc15705c10c
DTSTAMP:20231201T000000
DTSTART:20231201
SUMMARY:🔲 : Proposer une réunion aux personnes intéressé en janvier 🔼
LOCATION:ALTREP="obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md":obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md
END:VEVENT
BEGIN:VEVENT
UID:9f105f47-fffe-4f0b-8008-6c893b0c3924
DTSTAMP:20231109T000000
DTSTART:20231109
SUMMARY:✅ #waiting Suzie revient vers moi pour des éventuelles propositions de noms (CA 63)
LOCATION:ALTREP="obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md":obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md
END:VEVENT
BEGIN:VEVENT
UID:ab344328-0df6-4bfb-9892-865626bac610
DTSTAMP:20231005T000000
DTSTART:20231009
SUMMARY:✅ Envoyer la note d’intention à Suzie ()
LOCATION:ALTREP="obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md":obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md
END:VEVENT
BEGIN:VEVENT
UID:67046d03-caa3-4a58-85bf-f29f13750b79
DTSTAMP:20231107T000000
DTSTART:20231107
SUMMARY:✅ #renseignement Interroger  sur et ses spécificités
LOCATION:ALTREP="obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md":obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md
END:VEVENT
BEGIN:VEVENT
UID:c93a1511-31a8-4150-9f97-e9b71bd8c152
DTSTAMP:20230919T000000
DTSTART:20230919
SUMMARY:✅ Lire la revue de littérature sur l’évaluation des associations ()
LOCATION:ALTREP="obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md":obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md
END:VEVENT
BEGIN:VEVENT
UID:c053edb5-49d8-4c7e-90e1-e7e328cbd18a
DTSTAMP:20230925T000000
DTSTART:20230925
SUMMARY:🚫 Écrire à la société
LOCATION:ALTREP="obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md":obsidian://open?vault=Armoire&file=06%20-%20AIRES/PRO/PROJETS/2024_%C3%89valuation-CA63/2024%20-%20L%E2%80%99%C3%A9valuation%20en%20pratique.md
END:VEVENT
andrewbrereton commented 7 months ago

Merci @bepolymathe. Can you also include the Markdown from Obsidian that generated these events?

For example, the line:

SUMMARY:🔲 : Proposer une réunion aux personnes intéressé en janvier 🔼

Was generated by a task that would have looked something like this:

- [ ] ??? : Proposer une réunion aux personnes intéressé en janvier 🔼

I want to know what the ??? part is so that I can test.

bepolymathe commented 7 months ago

Yes. It’s a link to a project.

- [ ] [[2024 - projets ACS]] : Proposer une réunion aux personnes intéressé en janvier 🔼 ⏳ 2023-12-01

With the "keep the title" option

image

andrewbrereton commented 7 months ago

If you change that setting to Do not modify them then they will not be removed. However it will keep the [[ and ]] which does not look great.

If you want to have a title, are you able to make the wikilinks have a title like this:

- [ ] [[2024 - projets ACS|2024 - project ACS]] : Proposer une réunion aux personnes intéressé en janvier 🔼 ⏳ 2023-12-01

With the above, you have a link and a title. With the Keep the title setting, the output will be as expected.

Let me know if this is OK.

bepolymathe commented 7 months ago

Ok, thanks for reply.

With the Keep the title setting, the output will be as expected.

I misunderstood. I thought this action displayed the link title but without the double brackets. It's clearer now, thanks.

However, this doesn't solve the problem of distinguishing between scheduled tasks and tasks with deadlines. 🤔 Do you think it's a good idea to distinguish between them?