Skip to content

Update posts and fix file issue#2

Open
bjhend wants to merge 4 commits into
behrisch:mainfrom
bjhend:update-posts
Open

Update posts and fix file issue#2
bjhend wants to merge 4 commits into
behrisch:mainfrom
bjhend:update-posts

Conversation

@bjhend
Copy link
Copy Markdown

@bjhend bjhend commented Apr 15, 2026

This change takes care to download only new posts on a subsequent run. To achieve this it searches for the latest downloaded post in each channel and requests only posts after that from Mattermost.

To find the latest post, the channel posts dir is searched. To avoid confusion with eventually downloaded files those are now put in a separate subdirectory files of the posts directory.

Fixed issue

For each file from Mattermost, matterbak creates two files: one with the original content and one with the metadata from Mattermost. Both used to receive the file ID as name while the original content file received the original extension and the metadata file the extension .json. This led to a name clash if the original file coincidentally also had the extension .json.

This change now assembles the name for the original file with the Mattermost file ID and the full original name.

Note: This PR requires that PR #1 is merged.

bjhend added 4 commits April 13, 2026 23:10
* Convert setup to pyproject.toml suitable for poetry or uv
* Make a proper package structure
* Add detailed backup channel configuration by file
* Update version to 0.2.0

Sorry for not splitting these changes into separate commits.
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.

1 participant