Skip to content

Commit

Permalink
Merge pull request #146 from stuartmaxwell:install-mastodon-plugin
Browse files Browse the repository at this point in the history
Add Mastodon Publishing Plugin
  • Loading branch information
stuartmaxwell authored Nov 20, 2024
2 parents 3b4f568 + 7e1a1ae commit dd5112c
Show file tree
Hide file tree
Showing 3 changed files with 151 additions and 0 deletions.
12 changes: 12 additions & 0 deletions config/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
ADMIN_URL=(str, "admin"),
BLOG_TITLE=(str, "stuartm.nz"),
POST_PREFIX=(str, "{{ year }}/{{ month }}"),
MASTODON_ACCESS_TOKEN=(str, ""),
)

environ.Env.read_env(Path(BASE_DIR / ".env"))
Expand Down Expand Up @@ -259,4 +260,15 @@
"POST_PREFIX": env("POST_PREFIX"),
"THEME": "stuartmnz",
"MARKDOWN_RENDERER": "config.markdown_renderer.mistune_renderer",
"PLUGINS": [
"djpress_publish_mastodon",
],
"PLUGIN_SETTINGS": {
"djpress_publish_mastodon": {
"instance_url": "https://fosstodon.org",
"access_token": env("MASTODON_ACCESS_TOKEN"),
"status_message": "🚀 I created a new blog post!\n\n",
"base_url": "https://stuartm.nz/",
},
},
}
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ dependencies = [
"pytest-django>=4.9.0",
"mistune>=3.0.2",
"pygments>=2.18.0",
"djpress-publish-mastodon>=1.0.0",
]

[tool.curlylint.rules]
Expand Down
138 changes: 138 additions & 0 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit dd5112c

Please sign in to comment.