├── .github └── workflows │ ├── build-and-test.yml │ └── codeql-analysis.yml ├── .gitignore ├── CHANGELOG.md ├── LICENSE ├── README.md ├── binder.go ├── binder_test.go ├── cert.go ├── cert_test.go ├── cmd └── mars-gen │ ├── filesorting.go │ ├── main.go │ ├── main_test.go │ └── reflect.go ├── compress.go ├── compress_test.go ├── config.go ├── controller.go ├── cookie.go ├── csrf.go ├── docs ├── code-generation.md ├── faq.md ├── getting-started.md ├── index.md ├── migration.md └── testing.md ├── embedded_templates.go ├── errors.go ├── examples └── servethis │ └── main.go ├── fakeapp_test.go ├── field.go ├── filter.go ├── filterconfig.go ├── filterconfig_test.go ├── flash.go ├── go.mod ├── go.sum ├── hooks.go ├── http.go ├── i18n.go ├── i18n_test.go ├── intercept.go ├── intercept_test.go ├── internal ├── pathtree │ ├── LICENSE │ ├── tree.go │ └── tree_test.go └── watcher │ ├── watcher.go │ └── watcher_test.go ├── invoker.go ├── invoker_test.go ├── mars.go ├── mime.go ├── mime_test.go ├── mkdocs.yml ├── panic.go ├── panic_test.go ├── params.go ├── params_test.go ├── reflection.go ├── reflection_test.go ├── results.go ├── results_test.go ├── router.go ├── router_test.go ├── sanitize.go ├── sanitize_test.go ├── server.go ├── server_test.go ├── session.go ├── session_fuzz_test.go ├── session_test.go ├── sign.go ├── sign_fuzz_test.go ├── sign_test.go ├── static.go ├── template.go ├── templates └── errors │ ├── 403.html │ ├── 403.json │ ├── 403.txt │ ├── 403.xml │ ├── 404-dev.html │ ├── 404.html │ ├── 404.json │ ├── 404.txt │ ├── 404.xml │ ├── 405.html │ ├── 405.json │ ├── 405.txt │ ├── 405.xml │ ├── 500-dev.html │ ├── 500.html │ ├── 500.json │ ├── 500.txt │ └── 500.xml ├── templates_test.go ├── testdata ├── conf │ ├── app.conf │ ├── mime-types.conf │ └── routes ├── i18n │ ├── config │ │ └── test_app.conf │ └── messages │ │ ├── dutch_messages.nl │ │ ├── english_messages.en │ │ ├── english_messages2.en │ │ └── invalid_message_file_name.txt ├── public │ └── js │ │ └── sessvars.js └── views │ ├── footer.html │ ├── header.html │ ├── hotels │ └── show.html │ ├── i18n.html │ └── i18n_ctx.html ├── testing ├── equal.go ├── equal_test.go └── testsuite.go ├── validation.go ├── validation_test.go ├── validators.go ├── validators_test.go └── watchfilter.go /.github/workflows/build-and-test.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/.github/workflows/build-and-test.yml -------------------------------------------------------------------------------- /.github/workflows/codeql-analysis.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/.github/workflows/codeql-analysis.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/.gitignore -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/CHANGELOG.md -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/README.md -------------------------------------------------------------------------------- /binder.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/binder.go -------------------------------------------------------------------------------- /binder_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/binder_test.go -------------------------------------------------------------------------------- /cert.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/cert.go -------------------------------------------------------------------------------- /cert_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/cert_test.go -------------------------------------------------------------------------------- /cmd/mars-gen/filesorting.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/cmd/mars-gen/filesorting.go -------------------------------------------------------------------------------- /cmd/mars-gen/main.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/cmd/mars-gen/main.go -------------------------------------------------------------------------------- /cmd/mars-gen/main_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/cmd/mars-gen/main_test.go -------------------------------------------------------------------------------- /cmd/mars-gen/reflect.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/cmd/mars-gen/reflect.go -------------------------------------------------------------------------------- /compress.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/compress.go -------------------------------------------------------------------------------- /compress_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/compress_test.go -------------------------------------------------------------------------------- /config.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/config.go -------------------------------------------------------------------------------- /controller.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/controller.go -------------------------------------------------------------------------------- /cookie.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/cookie.go -------------------------------------------------------------------------------- /csrf.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/csrf.go -------------------------------------------------------------------------------- /docs/code-generation.md: -------------------------------------------------------------------------------- 1 | # Code generation with mars-gen 2 | 3 | **WORK IN PROGRESS** 4 | -------------------------------------------------------------------------------- /docs/faq.md: -------------------------------------------------------------------------------- 1 | # Frequently Asked Questions 2 | 3 | **WORK IN PROGRESS** 4 | -------------------------------------------------------------------------------- /docs/getting-started.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/docs/getting-started.md -------------------------------------------------------------------------------- /docs/index.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/docs/index.md -------------------------------------------------------------------------------- /docs/migration.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/docs/migration.md -------------------------------------------------------------------------------- /docs/testing.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/docs/testing.md -------------------------------------------------------------------------------- /embedded_templates.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/embedded_templates.go -------------------------------------------------------------------------------- /errors.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/errors.go -------------------------------------------------------------------------------- /examples/servethis/main.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/examples/servethis/main.go -------------------------------------------------------------------------------- /fakeapp_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/fakeapp_test.go -------------------------------------------------------------------------------- /field.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/field.go -------------------------------------------------------------------------------- /filter.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/filter.go -------------------------------------------------------------------------------- /filterconfig.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/filterconfig.go -------------------------------------------------------------------------------- /filterconfig_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/filterconfig_test.go -------------------------------------------------------------------------------- /flash.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/flash.go -------------------------------------------------------------------------------- /go.mod: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/go.mod -------------------------------------------------------------------------------- /go.sum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/go.sum -------------------------------------------------------------------------------- /hooks.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/hooks.go -------------------------------------------------------------------------------- /http.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/http.go -------------------------------------------------------------------------------- /i18n.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/i18n.go -------------------------------------------------------------------------------- /i18n_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/i18n_test.go -------------------------------------------------------------------------------- /intercept.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/intercept.go -------------------------------------------------------------------------------- /intercept_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/intercept_test.go -------------------------------------------------------------------------------- /internal/pathtree/LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/internal/pathtree/LICENSE -------------------------------------------------------------------------------- /internal/pathtree/tree.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/internal/pathtree/tree.go -------------------------------------------------------------------------------- /internal/pathtree/tree_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/internal/pathtree/tree_test.go -------------------------------------------------------------------------------- /internal/watcher/watcher.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/internal/watcher/watcher.go -------------------------------------------------------------------------------- /internal/watcher/watcher_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/internal/watcher/watcher_test.go -------------------------------------------------------------------------------- /invoker.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/invoker.go -------------------------------------------------------------------------------- /invoker_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/invoker_test.go -------------------------------------------------------------------------------- /mars.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/mars.go -------------------------------------------------------------------------------- /mime.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/mime.go -------------------------------------------------------------------------------- /mime_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/mime_test.go -------------------------------------------------------------------------------- /mkdocs.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/mkdocs.yml -------------------------------------------------------------------------------- /panic.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/panic.go -------------------------------------------------------------------------------- /panic_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/panic_test.go -------------------------------------------------------------------------------- /params.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/params.go -------------------------------------------------------------------------------- /params_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/params_test.go -------------------------------------------------------------------------------- /reflection.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/reflection.go -------------------------------------------------------------------------------- /reflection_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/reflection_test.go -------------------------------------------------------------------------------- /results.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/results.go -------------------------------------------------------------------------------- /results_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/results_test.go -------------------------------------------------------------------------------- /router.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/router.go -------------------------------------------------------------------------------- /router_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/router_test.go -------------------------------------------------------------------------------- /sanitize.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/sanitize.go -------------------------------------------------------------------------------- /sanitize_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/sanitize_test.go -------------------------------------------------------------------------------- /server.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/server.go -------------------------------------------------------------------------------- /server_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/server_test.go -------------------------------------------------------------------------------- /session.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/session.go -------------------------------------------------------------------------------- /session_fuzz_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/session_fuzz_test.go -------------------------------------------------------------------------------- /session_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/session_test.go -------------------------------------------------------------------------------- /sign.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/sign.go -------------------------------------------------------------------------------- /sign_fuzz_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/sign_fuzz_test.go -------------------------------------------------------------------------------- /sign_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/sign_test.go -------------------------------------------------------------------------------- /static.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/static.go -------------------------------------------------------------------------------- /template.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/template.go -------------------------------------------------------------------------------- /templates/errors/403.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/403.html -------------------------------------------------------------------------------- /templates/errors/403.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/403.json -------------------------------------------------------------------------------- /templates/errors/403.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/403.txt -------------------------------------------------------------------------------- /templates/errors/403.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/403.xml -------------------------------------------------------------------------------- /templates/errors/404-dev.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/404-dev.html -------------------------------------------------------------------------------- /templates/errors/404.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/404.html -------------------------------------------------------------------------------- /templates/errors/404.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/404.json -------------------------------------------------------------------------------- /templates/errors/404.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/404.txt -------------------------------------------------------------------------------- /templates/errors/404.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/404.xml -------------------------------------------------------------------------------- /templates/errors/405.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/405.html -------------------------------------------------------------------------------- /templates/errors/405.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/405.json -------------------------------------------------------------------------------- /templates/errors/405.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/405.txt -------------------------------------------------------------------------------- /templates/errors/405.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/405.xml -------------------------------------------------------------------------------- /templates/errors/500-dev.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/500-dev.html -------------------------------------------------------------------------------- /templates/errors/500.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/500.html -------------------------------------------------------------------------------- /templates/errors/500.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/500.json -------------------------------------------------------------------------------- /templates/errors/500.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/500.txt -------------------------------------------------------------------------------- /templates/errors/500.xml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates/errors/500.xml -------------------------------------------------------------------------------- /templates_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/templates_test.go -------------------------------------------------------------------------------- /testdata/conf/app.conf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testdata/conf/app.conf -------------------------------------------------------------------------------- /testdata/conf/mime-types.conf: -------------------------------------------------------------------------------- 1 | bkng=application/x-booking -------------------------------------------------------------------------------- /testdata/conf/routes: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testdata/conf/routes -------------------------------------------------------------------------------- /testdata/i18n/config/test_app.conf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testdata/i18n/config/test_app.conf -------------------------------------------------------------------------------- /testdata/i18n/messages/dutch_messages.nl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testdata/i18n/messages/dutch_messages.nl -------------------------------------------------------------------------------- /testdata/i18n/messages/english_messages.en: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testdata/i18n/messages/english_messages.en -------------------------------------------------------------------------------- /testdata/i18n/messages/english_messages2.en: -------------------------------------------------------------------------------- 1 | greeting2=Yo! 2 | -------------------------------------------------------------------------------- /testdata/i18n/messages/invalid_message_file_name.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /testdata/public/js/sessvars.js: -------------------------------------------------------------------------------- 1 | console.log('Test file'); 2 | -------------------------------------------------------------------------------- /testdata/views/footer.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testdata/views/footer.html -------------------------------------------------------------------------------- /testdata/views/header.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testdata/views/header.html -------------------------------------------------------------------------------- /testdata/views/hotels/show.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testdata/views/hotels/show.html -------------------------------------------------------------------------------- /testdata/views/i18n.html: -------------------------------------------------------------------------------- 1 | {{msg $ `arguments.html` .input}} -------------------------------------------------------------------------------- /testdata/views/i18n_ctx.html: -------------------------------------------------------------------------------- 1 | {{t `arguments.html` .input}} -------------------------------------------------------------------------------- /testing/equal.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testing/equal.go -------------------------------------------------------------------------------- /testing/equal_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testing/equal_test.go -------------------------------------------------------------------------------- /testing/testsuite.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/testing/testsuite.go -------------------------------------------------------------------------------- /validation.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/validation.go -------------------------------------------------------------------------------- /validation_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/validation_test.go -------------------------------------------------------------------------------- /validators.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/validators.go -------------------------------------------------------------------------------- /validators_test.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/validators_test.go -------------------------------------------------------------------------------- /watchfilter.go: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/roblillack/mars/HEAD/watchfilter.go --------------------------------------------------------------------------------