aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
* Update depsSimon Ser2019-12-162-33/+25
|
* Export IMAPMessageSimon Ser2019-12-162-16/+16
| | | | This is a public type other plugins and templates may want to access.
* Add attachments support to composerSimon Ser2019-12-163-9/+57
| | | | Closes: https://todo.sr.ht/~sircmpwn/koushin/13
* go fmtSimon Ser2019-12-163-4/+4
|
* Use <label> in compose formSimon Ser2019-12-162-9/+12
|
* Add basic searchSimon Ser2019-12-165-9/+74
| | | | Closes: https://todo.sr.ht/~sircmpwn/koushin/23
* Add line break to login formSimon Ser2019-12-161-0/+1
|
* Replace Session.ConnectSMTP with Session.DoSMTPSimon Ser2019-12-162-16/+19
| | | | | This gives more flexibility in Session for optimizations, e.g. keep the SMTP connection around for some time if possible.
* Rename Session.Do to Session.DoIMAPSimon Ser2019-12-162-6/+6
|
* Remove the public/ directorySimon Ser2019-12-1615-7/+18
| | | | | Now that all templates are provided by plugins, there's no need to have a public/ directory. Themes can be in /themes instead of /public/themes.
* Introduce base pluginSimon Ser2019-12-1622-450/+521
| | | | | | This plugin offers base IMAP/SMTP functionality. References: https://todo.sr.ht/~sircmpwn/koushin/39
* Add an API for Go pluginsSimon Ser2019-12-163-1/+111
| | | | References: https://todo.sr.ht/~sircmpwn/koushin/39
* gitignore: don't ignore sourcehut themeSimon Ser2019-12-121-2/+3
|
* Add simple Sourcehut-based themeDrew DeVault2019-12-1211-4/+5967
|
* Fix undefined ErrSessionExpiredSimon Ser2019-12-122-2/+2
| | | | Fixes: f07ab5263246 ("Add docs")
* Add docsSimon Ser2019-12-114-4/+26
|
* Allow plugins to provide their own templatesSimon Ser2019-12-114-8/+27
|
* readme: add godoc badgeSimon Ser2019-12-111-0/+2
|
* Export Server.{Sessions,Plugins}Simon Ser2019-12-114-13/+12
| | | | And unexport a few internal functions.
* Unexport NewSessionManagerSimon Ser2019-12-112-2/+2
| | | | This isn't intended to be used by plugins.
* Export Context.SetSession, unexport Session.TokenSimon Ser2019-12-113-10/+10
| | | | | | | I'm uneasy exposing the token to plugins, I prefer to hide it if possible to prevent mis-use. This change allows plugins to logout users.
* Export ContextSimon Ser2019-12-113-29/+34
| | | | This allows plugins to access it.
* Add plugins/ to .gitignoreSimon Ser2019-12-101-0/+1
|
* go fmtSimon Ser2019-12-103-17/+17
|
* Introduce GlobalRenderData and RenderDataSimon Ser2019-12-102-7/+40
| | | | | | | | GlobalRenderData contains some global metadata that can be obtained from any template. RenderData is a base type for template data. It contains a Global field with global metadata and an Extra field for plugins.
* Load all themes on startupSimon Ser2019-12-101-13/+54
| | | | This is the first step to allow each user to have a different theme.
* readme: add link to mailing list & issue trackerSimon Ser2019-12-101-0/+5
|
* Rename Plugin.Render to Plugin.InjectSimon Ser2019-12-103-3/+3
| | | | | This function doesn't render anything, it just adds extra data to the template data.
* Extract Lua plugin logic into separate fileSimon Ser2019-12-102-151/+158
|
* Allow plugins to add new routesSimon Ser2019-12-103-0/+40
| | | | References: https://todo.sr.ht/~sircmpwn/koushin/6
* Reconnect to IMAP server when logged outSimon Ser2019-12-093-20/+90
| | | | | | | | | | | | | | | The session manager has been upgraded to deal with reconnections. Each session has its own expiration timer. Each time a request is received, the expiration timer is reset. A session can be closed (this is used when the user wants to logout). When the IMAP connection is closed by the server, it's set to nil in the session. The next time an IMAP command needs to be issued, the connection is re-established. Closes: https://todo.sr.ht/~sircmpwn/koushin/30
* Make SessionManager create the IMAP clientSimon Ser2019-12-094-23/+46
| | | | | This will allow SessionManager to re-connect when the IMAP server logs the user out.
* Rename ConnPool to SessionManagerSimon Ser2019-12-093-20/+20
|
* readme: sync with new Lua APISimon Ser2019-12-091-2/+5
|
* Add a Lua API to set template filtersSimon Ser2019-12-093-10/+49
|
* Change Lua API to koushin.on_renderSimon Ser2019-12-091-7/+27
|
* Make render data staticSimon Ser2019-12-091-14/+39
| | | | | | | | This makes sure fields filled by vanilla koushin keep the right type. A new Extra field allows plugins to attach their own data. This also makes it easier to write Go plugins, which would have trouble working with interface{}.
* Add basic support for pluginsSimon Ser2019-12-096-1/+115
|
* Drop define in templatesSimon Ser2019-12-096-12/+8
| | | | Just use the full filename instead, this is simpler and more explicit.
* Use imap.BodyStructure.Filename and imap.Address.AddressSimon Ser2019-12-094-6/+5
| | | | | The former fixes encoding issues in filenames. The latter is just for brevity.
* Extract HTTP handlers in separate fileSimon Ser2019-12-042-263/+277
|
* Add .gitignoreSimon Ser2019-12-041-0/+2
|
* Add basic theme supportSimon Ser2019-12-045-25/+75
| | | | References: https://todo.sr.ht/~sircmpwn/koushin/1
* Make message view's Back link set the mailbox pageSimon Ser2019-12-033-6/+9
| | | | | | | This allows to go back and forth between the mailbox view and the message view. References: https://todo.sr.ht/~sircmpwn/koushin/22
* Add separator between Prev and Next linksSimon Ser2019-12-031-0/+1
|
* Add basic pagination to message listSimon Ser2019-12-037-20/+60
| | | | References: https://todo.sr.ht/~sircmpwn/koushin/22
* Fix missing OutgoingMessage.InReplyTo assignmentSimon Ser2019-12-031-9/+5
|
* Add basic support for multiple recipientsSimon Ser2019-12-032-3/+10
|
* Add support for replying to a messageSimon Ser2019-12-035-12/+103
|
* Fix mailbox view when emptySimon Ser2019-12-032-9/+15
| | | | | | This fixes the second part of #14. References: https://todo.sr.ht/~sircmpwn/koushin/14