Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import multiple events from ICS files #1316

Closed
jluttine opened this issue Jan 6, 2023 · 9 comments · Fixed by #1700
Closed

Import multiple events from ICS files #1316

jluttine opened this issue Jan 6, 2023 · 9 comments · Fixed by #1700

Comments

@jluttine
Copy link

jluttine commented Jan 6, 2023

ICS calendar files may contain multiple events. However, when importing the file with Etar, only one (the first?) event is imported and the others ignored. Etar should import all those events.

@rparkins999
Copy link
Contributor

This is difficult because the architecture only handles creation of one event at a time. There is code to do this in my fork at rparkins999/Etar-Calendar which does it by creating a FIFO at the application level and pushing CalendarEventModels into it. EditEventAcitivity checks the FIFO and pops theCalendarEventModels out of it and saves them into the Android CalendarProvider. I can't offer a pull request as my version has diverged too far from this version, but you are welcome to lift the code. I haven't used it lately so it may have suffered from software rot, but it did work when I wrote it.

If @jluttine only wants to do this once, install rparkins999/Etar-Calendar, read in your ICS file, and then you can go back to using Etar-Group/Etar-Calendar.

@LRN
Copy link

LRN commented Apr 23, 2023

I second this issue. After installing new LineageOS i've switched from Simple Calendar to Etar, which comes with LOS preinstalled. I've exported all of the events from SC into one ICS file, but can't import all of them into Etar, because Etar only takes the first event in the file.
Installing rparkins999/Etar-Calendar is not an option, since i have to build it first, which is not a trivial affair for me.

@woheller69
Copy link
Contributor

you can use this app:

https://f-droid.org/packages/org.sufficientlysecure.ical/

@jluttine
Copy link
Author

you can use this app:

https://f-droid.org/packages/org.sufficientlysecure.ical/

Yeah, that's one option. A problem with that app is that the imported calendar events can't be modified whereas Etar-imported events can be modified.

I think the UI in Etar could be such that when importing a file with multiple events, Etar just asks which calendar to import them into and then imports without opening the events. One can then find and edit the events in the calendar if needed. That'd be pretty simple and would work for large amounts of events. That's similar to how the linked app mentioned above works.

@woheller69
Copy link
Contributor

I have no problem modifying imported events from https://f-droid.org/packages/org.sufficientlysecure.ical/

@foxyseta
Copy link

I also second this. Apparently OP isn't available to lift @rparkins999's code at the moment?

@rparkins999
Copy link
Contributor

I had a big ics file to import, so I just tried it with rparkins999/Etar-Calendar and it didn't work 😞.

I'll try to fix the code in rparkins999/Etar-Calendar as soon as I can, but I don't exercise it very often as I only import a big ics file about twice per year.

Another option, if the calendar on your phone is synchronised to a PC, is to import the ics file into your PC and then synchronise. Most PC calendars will read a whole ics file. Evolution, which I use, successfully did so.

@Ekleog
Copy link

Ekleog commented Jan 16, 2025

I think this was not actually fixed by #1700? On 1.0.48 from f-droid, when I import ICS files shared from train/airline apps, I still only get the first trip added to my calendar.

And for those ICS files unfortunately the app listed does not work, as it seems to not be recognized as a sharing target.

@jluttine
Copy link
Author

Yes, as far as I understand, #1700 only added support for a recurring event, not having multiple events in a single ICS file. So, I think this issue should be re-opened.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
6 participants