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

Templating #34

Closed
wants to merge 4 commits into from
Closed

Templating #34

wants to merge 4 commits into from

Conversation

niccokunzmann
Copy link
Collaborator

@niccokunzmann niccokunzmann commented Sep 26, 2024

Description of change

This adds templating.

  • fix docs
  • add templating for events

Have a look at the tests added ...

Contributes to #17
Contributes to #21

Pull-Request Checklist

  • Code is up-to-date with the main branch
  • This pull request follows the contributing guidelines.
  • This pull request links relevant issues as Fixes #0000
  • There are new or updated unit tests validating the change
  • Documentation has been updated to reflect this change
  • The new commits follow conventions outlined in the conventional commit spec, such as "fix(api): prevent racing of requests".
  • If pre-commit.ci is failing, try pre-commit run -a for further information.
  • If CI / test is failing, try poetry run pytest for further information.

Copy link

codecov bot commented Sep 26, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Files with missing lines Coverage Δ
src/mergecal/calendar_merger.py 86.11% <100.00%> (+6.11%) ⬆️

@niccokunzmann
Copy link
Collaborator Author

Hi @abe-101, I added templating as I thought would be useful. The yaml specification allows for a lot of flexibility in the future as well as backwards compatibility and a unified interface for Python/command line usage.

calendars=self.calendars, attribute=attribute
)
self.merged_calendar.add(attribute, value)
# add events
for cal in self.calendars:
for component in cal.walk("VEVENT"):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct me if wrong but the VEVENT templating would go here?
so as we loop through vevent component we would need to apply the VEVENT template changes?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

correct! the other components could also be added.

@abe-101
Copy link
Contributor

abe-101 commented Jan 29, 2025

I don't want to prioritize this feature for now
I would first like to get merging calendars down pat.
(Gonna leave the issue open for now)

@niccokunzmann
Copy link
Collaborator Author

I will close this and we can use it when it is needed - if at all.

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

Successfully merging this pull request may close these issues.

2 participants