diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index b002e54..40f7355 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,30 +1,30 @@ # Contributing When contributing to this repository, please first discuss the change you wish to make via issue, -email, or any other method with the owners of this repository before making a change. +email, or any other method with the owners of this repository before making a change. Please note we have a code of conduct, please follow it in all your interactions with the project. ## Pull Request Process 1. Ensure you signed all your commits with Developer Certificate of Origin (DCO). -2. Ensure any install or build dependencies are removed before the end of the layer when doing a +2. Ensure any install or build dependencies are removed before the end of the layer when doing a build. -3. Update the README.md with details of changes to the interface, this includes new environment +3. Update the README.md with details of changes to the interface, this includes new environment variables, exposed ports, useful file locations and container parameters. 4. Increase the version numbers in any examples files and the README.md to the new version that this Pull Request would represent. The versioning scheme we use is [SemVer](http://semver.org/). -5. You may merge the Pull Request in once you have the sign-off of two other developers, or if you +5. You may merge the Pull Request in once you have the sign-off of two other developers, or if you do not have permission to do that, you may request the second reviewer to merge it for you. ## Contributor Code of Conduct -As contributors and maintainers of this project, and in the interest of fostering an open and -welcoming community, we pledge to respect all people who contribute through reporting issues, -posting feature requests, updating documentation, submitting pull requests or patches, and other +As contributors and maintainers of this project, and in the interest of fostering an open and +welcoming community, we pledge to respect all people who contribute through reporting issues, +posting feature requests, updating documentation, submitting pull requests or patches, and other activities. -We are committed to making participation in this project a harassment-free experience for everyone, -regardless of level of experience, gender, gender identity and expression, sexual orientation, +We are committed to making participation in this project a harassment-free experience for everyone, +regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, ethnicity, age, religion, or nationality. Examples of unacceptable behavior by participants include: @@ -37,26 +37,26 @@ Examples of unacceptable behavior by participants include: permission * Other unethical or unprofessional conduct. -Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, -code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct. By -adopting this Code of Conduct, project maintainers commit themselves to fairly and consistently -applying these principles to every aspect of managing this project. Project maintainers who do not +Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, +code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct. By +adopting this Code of Conduct, project maintainers commit themselves to fairly and consistently +applying these principles to every aspect of managing this project. Project maintainers who do not follow or enforce the Code of Conduct may be permanently removed from the project team. -This code of conduct applies both within project spaces and in public spaces when an individual is +This code of conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. -Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening an +Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening an issue or contacting one or more of the project maintainers. -This Code of Conduct is adapted from the [Contributor Covenant](http://contributor-covenant.org), -version 1.2.0, available at +This Code of Conduct is adapted from the [Contributor Covenant](http://contributor-covenant.org), +version 1.2.0, available at [http://contributor-covenant.org/version/1/2/0/](http://contributor-covenant.org/version/1/2/0/) ### Sign your work We use the Developer Certificate of Origin (DCO) as a additional safeguard -for the HackMD project. This is a well established and widely used +for the CodiMD project. This is a well established and widely used mechanism to assure contributors have confirmed their right to license their contribution under the project's license. Please read [contribute/developer-certificate-of-origin][dcofile]. diff --git a/CONTRIBUTORS b/CONTRIBUTORS deleted file mode 100644 index d5e679c..0000000 --- a/CONTRIBUTORS +++ /dev/null @@ -1,902 +0,0 @@ -=== .babelrc -Yukai Huang -=== .editorconfig -bananaappletw -Yukai Huang -=== .gitignore -Cheng-Han, Wu -Wu Cheng-Han -Yukai Huang -=== .sequelizerc.example -Yukai Huang -=== .travis.yml -bananaappletw -BoHong Li -Max Wu -Peter Dave Hello -=== AUTHORS -Cheng-Han, Wu -Wu Cheng-Han -=== CONTRIBUTING.md -Max Wu -=== LICENSE -Cheng-Han, Wu -jackycute -Wu Cheng-Han -=== README.md -alecdwm -bananaappletw -BoHong Li -Cheng-Han, Wu -Florian Rhiem -jackycute -Jannik Lorenz -Jason Croft -Johannes Weißl -Jun SAKATA -Laura Kyle -Max Wu -neopostmodern -NV -Sheogorath -The Gitter Badger -Wonder Chang -Wu Cheng-Han -Yukai Huang -蒼時弦也 -=== app.js -alecdwm -BoHong Li -Cheng-Han, Wu -James Stephenson -Jan Kunzmann -Jason Croft -Jordan Matelsky -knjcode -LluisArevalo -Max Wu -NV -Peter Dave Hello -Raccoon Li -robert -Sheogorath -S.Noda -Wu Cheng-Han -xnum -Yukai Huang -=== app.json -bananaappletw -Wu Cheng-Han -Yukai Huang -=== bin/heroku -bananaappletw -Yukai Huang -=== bin/setup -Sheogorath -Wu Cheng-Han -Yukai Huang -=== config.json.example -alecdwm -bananaappletw -Wu Cheng-Han -Yukai Huang -=== docs/guides/images/s3-image-upload/bucket-policy-editor.png -Yukai Huang -=== docs/guides/images/s3-image-upload/bucket-property.png -Yukai Huang -=== docs/guides/images/s3-image-upload/create-bucket.png -Yukai Huang -=== docs/guides/images/s3-image-upload/custom-policy.png -Yukai Huang -=== docs/guides/images/s3-image-upload/iam-user.png -Yukai Huang -=== docs/guides/images/s3-image-upload/review-policy.png -Yukai Huang -=== docs/guides/s3-image-upload.md -Johannes Weißl -Yukai Huang -=== lib/config/default.js -BoHong Li -=== lib/config/defaultSSL.js -BoHong Li -=== lib/config/dockerSecret.js -BoHong Li -=== lib/config/enum.js -BoHong Li -=== lib/config/environment.js -BoHong Li -Raccoon Li -=== lib/config/index.js -BoHong Li -tkykm -=== lib/config/oldEnvironment.js -BoHong Li -Raccoon Li -=== lib/config/utils.js -Raccoon Li -=== lib/history.js -BoHong Li -Wu Cheng-Han -=== lib/letter-avatars.js -alecdwm -BoHong Li -=== lib/logger.js -BoHong Li -Wu Cheng-Han -=== lib/migrations/20150504155329-create-users.js -BoHong Li -=== lib/migrations/20150508114741-create-notes.js -BoHong Li -=== lib/migrations/20150515125813-create-temp.js -BoHong Li -=== lib/migrations/20150702001020-update-to-0_3_1.js -BoHong Li -=== lib/migrations/20150915153700-change-notes-title-to-text.js -BoHong Li -=== lib/migrations/20160112220142-note-add-lastchange.js -BoHong Li -=== lib/migrations/20160420180355-note-add-alias.js -BoHong Li -=== lib/migrations/20160515114000-user-add-tokens.js -BoHong Li -Cheng-Han, Wu -=== lib/migrations/20160607060246-support-revision.js -BoHong Li -Cheng-Han, Wu -Wu Cheng-Han -=== lib/migrations/20160703062241-support-authorship.js -BoHong Li -Wu Cheng-Han -=== lib/migrations/20161009040430-support-delete-note.js -BoHong Li -Wu Cheng-Han -=== lib/migrations/20161201050312-support-email-signin.js -BoHong Li -Wu Cheng-Han -=== lib/models/author.js -BoHong Li -Wu Cheng-Han -=== lib/models/index.js -bananaappletw -BoHong Li -Cheng-Han, Wu -Wu Cheng-Han -Yukai Huang -=== lib/models/note.js -BoHong Li -Cheng-Han, Wu -NV -Wu Cheng-Han -蒼時弦也 -=== lib/models/revision.js -BoHong Li -Cheng-Han, Wu -Wu Cheng-Han -=== lib/models/temp.js -BoHong Li -Cheng-Han, Wu -=== lib/models/user.js -alecdwm -BoHong Li -Cheng-Han, Wu -Jason Croft -Wu Cheng-Han -=== lib/ot/client.js -Wu Cheng-Han -=== lib/ot/editor-socketio-server.js -Wu Cheng-Han -=== lib/ot/index.js -Wu Cheng-Han -=== lib/ot/selection.js -Wu Cheng-Han -=== lib/ot/server.js -Cheng-Han, Wu -Wu Cheng-Han -=== lib/ot/simple-text-operation.js -Wu Cheng-Han -=== lib/ot/text-operation.js -Wu Cheng-Han -=== lib/ot/wrapped-operation.js -Wu Cheng-Han -=== lib/realtime.js -BoHong Li -Cheng-Han, Wu -Florian Rhiem -Wu Cheng-Han -蒼時弦也 -=== lib/response.js -alecdwm -BoHong Li -butlerx -Cheng-Han, Wu -Florian Rhiem -Ikumi Shimizu <193s@users.noreply.github.com> -Jannik Lorenz -Jason Croft -Sheogorath -Wu Cheng-Han -xnum -蒼時弦也 -=== lib/utils.js -BoHong Li -butlerx -LluisArevalo -=== lib/web/auth/dropbox/index.js -BoHong Li -=== lib/web/auth/email/index.js -BoHong Li -=== lib/web/auth/facebook/index.js -BoHong Li -=== lib/web/auth/github/index.js -BoHong Li -Max Wu -=== lib/web/auth/gitlab/index.js -BoHong Li -=== lib/web/auth/google/index.js -BoHong Li -Kaiyu Shi -=== lib/web/auth/index.js -BoHong Li -=== lib/web/auth/ldap/index.js -BoHong Li -=== lib/web/auth/twitter/index.js -BoHong Li -=== lib/web/auth/utils.js -BoHong Li -=== lib/web/baseRouter.js -BoHong Li -=== lib/web/historyRouter.js -BoHong Li -=== lib/web/imageRouter.js -BoHong Li -Kotaro Yamamoto -Raccoon Li -=== lib/web/middleware/checkURIValid.js -BoHong Li -Max Wu -=== lib/web/middleware/redirectWithoutTrailingSlashes.js -BoHong Li -=== lib/web/middleware/tooBusy.js -BoHong Li -=== lib/web/noteRouter.js -BoHong Li -=== lib/web/statusRouter.js -BoHong Li -=== lib/web/userRouter.js -BoHong Li -=== lib/web/utils.js -BoHong Li -=== lib/workers/dmpWorker.js -BoHong Li -Wu Cheng-Han -=== locales/ca.json -Xavier Marques -=== locales/da.json -Patrick Andersen -=== locales/de.json -Jannik Lorenz -Philipp Zumstein -Simon Joda Stößer -=== locales/el.json -Stratos Gerakakis -Wu Cheng-Han -zachariast -=== locales/en.json -alecdwm -Wu Cheng-Han -=== locales/eo.json -James Stephenson -=== locales/es.json -Pablo Guerrero -Sergio Valverde -=== locales/fr.json -Colin Maudry -Ho33e5 -=== locales/hi.json -Paras -=== locales/hr.json -ivanorsolic -=== locales/it.json -GhiMax -=== locales/ja.json -tkqubo -=== locales/nl.json -Martijnpold -Tom Wyckhuys -=== locales/pl.json -Bartlomiej Szala -Jakub Sygnowski -=== locales/pt.json -Marcelo Alencar -Wu Cheng-Han -=== locales/ru.json -Himura Kazuto -p0v1n0m -=== locales/sv.json -Lars Karlsson -Patrick Andersen -Wu Cheng-Han -=== locales/tr.json -Ömer Erdinç Yağmurlu -=== locales/uk.json -Dmytro Kytsmen -Wu Cheng-Han -=== locales/zh.json -Wu Cheng-Han -=== package.json -alecdwm -bananaappletw -BoHong Li -Bryan Davis -Cheng-Han, Wu -Fabien Meghazi -greenkeeperio-bot -Jason Croft -Max Wu -Peter Dave Hello -Peter Dave Hello -Sheogorath -Wu Cheng-Han -xnum -Yukai Huang -=== public/apple-touch-icon.png -Peter Dave Hello -Wu Cheng-Han -=== public/css/bootstrap-social.css -Peter Dave Hello -Wu Cheng-Han -=== public/css/center.css -Wu Cheng-Han -=== public/css/cover.css -Cheng-Han, Wu -Jason Croft -Wu Cheng-Han -=== public/css/extra.css -Cheng-Han, Wu -Wu Cheng-Han -=== public/css/font.css -Yukai Huang -=== public/css/github-extract.css -Cheng-Han, Wu -Wu Cheng-Han -=== public/css/google-font.css -Yukai Huang -=== public/css/index.css -Cheng-Han, Wu -Jason Croft -Wu Cheng-Han -=== public/css/markdown.css -Cheng-Han, Wu -Wu Cheng-Han -=== public/css/mermaid.css -Cheng-Han, Wu -=== public/css/site.css -Cheng-Han, Wu -Wu Cheng-Han -Yukai Huang -=== public/css/slide-preview.css -Wu Cheng-Han -=== public/css/slide.css -Wu Cheng-Han -=== public/default.md -Wu Cheng-Han -=== public/docs/features.md -Cheng-Han, Wu -Max Wu -Pablo Guerrero -Sheogorath -Wu Cheng-Han -=== public/docs/release-notes.md -Cheng-Han, Wu -Peter Dave Hello -Wu Cheng-Han -=== public/docs/slide-example.md -butlerx -Cheng-Han, Wu -Wu Cheng-Han -=== public/docs/yaml-metadata.md -Cheng-Han, Wu -Wu Cheng-Han -=== public/favicon.png -Peter Dave Hello -Wu Cheng-Han -=== public/fonts/SourceCodePro-Black.eot -Yukai Huang -=== public/fonts/SourceCodePro-Black.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceCodePro-Black.woff -Yukai Huang -=== public/fonts/SourceCodePro-Bold.eot -Yukai Huang -=== public/fonts/SourceCodePro-Bold.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceCodePro-Bold.woff -Yukai Huang -=== public/fonts/SourceCodePro-ExtraLight.eot -Yukai Huang -=== public/fonts/SourceCodePro-ExtraLight.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceCodePro-ExtraLight.woff -Yukai Huang -=== public/fonts/SourceCodePro-Light.eot -Yukai Huang -=== public/fonts/SourceCodePro-Light.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceCodePro-Light.woff -Yukai Huang -=== public/fonts/SourceCodePro-Medium.eot -Yukai Huang -=== public/fonts/SourceCodePro-Medium.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceCodePro-Medium.woff -Yukai Huang -=== public/fonts/SourceCodePro-Regular.eot -Yukai Huang -=== public/fonts/SourceCodePro-Regular.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceCodePro-Regular.woff -Yukai Huang -=== public/fonts/SourceCodePro-Semibold.eot -Yukai Huang -=== public/fonts/SourceCodePro-Semibold.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceCodePro-Semibold.woff -Yukai Huang -=== public/fonts/SourceSansPro-Black.eot -Yukai Huang -=== public/fonts/SourceSansPro-Black.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-Black.woff -Yukai Huang -=== public/fonts/SourceSansPro-BlackItalic.eot -Yukai Huang -=== public/fonts/SourceSansPro-BlackItalic.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-BlackItalic.woff -Yukai Huang -=== public/fonts/SourceSansPro-Bold.eot -Yukai Huang -=== public/fonts/SourceSansPro-Bold.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-Bold.woff -Yukai Huang -=== public/fonts/SourceSansPro-BoldItalic.eot -Yukai Huang -=== public/fonts/SourceSansPro-BoldItalic.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-BoldItalic.woff -Yukai Huang -=== public/fonts/SourceSansPro-ExtraLight.eot -Yukai Huang -=== public/fonts/SourceSansPro-ExtraLight.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-ExtraLight.woff -Yukai Huang -=== public/fonts/SourceSansPro-ExtraLightItalic.eot -Yukai Huang -=== public/fonts/SourceSansPro-ExtraLightItalic.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-ExtraLightItalic.woff -Yukai Huang -=== public/fonts/SourceSansPro-Italic.eot -Yukai Huang -=== public/fonts/SourceSansPro-Italic.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-Italic.woff -Yukai Huang -=== public/fonts/SourceSansPro-Light.eot -Yukai Huang -=== public/fonts/SourceSansPro-Light.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-Light.woff -Yukai Huang -=== public/fonts/SourceSansPro-LightItalic.eot -Yukai Huang -=== public/fonts/SourceSansPro-LightItalic.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-LightItalic.woff -Yukai Huang -=== public/fonts/SourceSansPro-Regular.eot -Yukai Huang -=== public/fonts/SourceSansPro-Regular.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-Regular.woff -Yukai Huang -=== public/fonts/SourceSansPro-Semibold.eot -Yukai Huang -=== public/fonts/SourceSansPro-Semibold.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-Semibold.woff -Yukai Huang -=== public/fonts/SourceSansPro-SemiboldItalic.eot -Yukai Huang -=== public/fonts/SourceSansPro-SemiboldItalic.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSansPro-SemiboldItalic.woff -Yukai Huang -=== public/fonts/SourceSerifPro-Bold.eot -Yukai Huang -=== public/fonts/SourceSerifPro-Bold.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSerifPro-Bold.woff -Yukai Huang -=== public/fonts/SourceSerifPro-Regular.eot -Yukai Huang -=== public/fonts/SourceSerifPro-Regular.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSerifPro-Regular.woff -Yukai Huang -=== public/fonts/SourceSerifPro-Semibold.eot -Yukai Huang -=== public/fonts/SourceSerifPro-Semibold.ttf -Peter Dave Hello -Yukai Huang -=== public/fonts/SourceSerifPro-Semibold.woff -Yukai Huang -=== public/hackmd-icon-1024.png -Peter Dave Hello -Wu Cheng-Han -=== public/js/cover.js -BoHong Li -Cheng-Han, Wu -Jason Croft -NV -Wu Cheng-Han -Yukai Huang -=== public/js/extra.js -BoHong Li -Cheng-Han, Wu -NV -Wu Cheng-Han -Yukai Huang -=== public/js/google-drive-picker.js -BoHong Li -Cheng-Han, Wu -Max Wu -=== public/js/google-drive-upload.js -BoHong Li -Cheng-Han, Wu -Wu Cheng-Han -=== public/js/history.js -BoHong Li -Cheng-Han, Wu -Wu Cheng-Han -Yukai Huang -=== public/js/htmlExport.js -BoHong Li -Yukai Huang -=== public/js/index.js -BoHong Li -Cheng-Han, Wu -Jason Croft -Laura Kyle -NV -Wu Cheng-Han -xnum -Yukai Huang -Zankio -蒼時弦也 -=== public/js/lib/appState.js -Yukai Huang -=== public/js/lib/common/constant.ejs -Wu Cheng-Han -=== public/js/lib/common/login.js -BoHong Li -Wu Cheng-Han -Yukai Huang -=== public/js/lib/config/index.js -BoHong Li -Wu Cheng-Han -Yukai Huang -=== public/js/lib/editor/config.js -Yukai Huang -=== public/js/lib/editor/index.js -Wu Cheng-Han -Yukai Huang -=== public/js/lib/editor/statusbar.html -Cheng-Han, Wu -Wu Cheng-Han -Yukai Huang -=== public/js/lib/editor/ui-elements.js -Yukai Huang -=== public/js/lib/editor/utils.js -Yukai Huang -=== public/js/lib/modeType.js -Yukai Huang -=== public/js/lib/syncscroll.js -BoHong Li -Cheng-Han, Wu -Wu Cheng-Han -Yukai Huang -=== public/js/locale.js -BoHong Li -Peter Dave Hello -Wu Cheng-Han -Yukai Huang -=== public/js/pretty.js -BoHong Li -Cheng-Han, Wu -Wu Cheng-Han -Yukai Huang -=== public/js/render.js -BoHong Li -Cheng-Han, Wu -Wu Cheng-Han -Yukai Huang -=== public/js/reveal-markdown.js -BoHong Li -Cheng-Han, Wu -Peter Dave Hello -Wu Cheng-Han -=== public/js/slide.js -BoHong Li -Max Wu -Wu Cheng-Han -Yukai Huang -=== public/screenshot.png -Wu Cheng-Han -=== public/uploads/.gitkeep -Wu Cheng-Han -Yukai Huang -=== public/vendor/abcjs_basic_3.1.1-min.js -Wu Cheng-Han -=== public/vendor/bootstrap/tooltip.min.css -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/bootstrap/tooltip.min.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/codemirror-spell-checker/en_US.aff -Cheng-Han, Wu -=== public/vendor/codemirror-spell-checker/en_US.dic -Cheng-Han, Wu -=== public/vendor/codemirror-spell-checker/spell-checker.min.css -Cheng-Han, Wu -Wu Cheng-Han -=== public/vendor/codemirror-spell-checker/spell-checker.min.js -Cheng-Han, Wu -Wu Cheng-Han -Yukai Huang -=== public/vendor/inlineAttachment/codemirror.inline-attachment.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/inlineAttachment/inline-attachment.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-textcomplete/jquery.textcomplete.js -Cheng-Han, Wu -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-bg_flat_0_aaaaaa_40x100.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-bg_flat_75_ffffff_40x100.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-bg_glass_55_fbf9ee_1x400.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-bg_glass_65_ffffff_1x400.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-bg_glass_75_dadada_1x400.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-bg_glass_75_e6e6e6_1x400.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-bg_glass_95_fef1ec_1x400.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-bg_highlight-soft_75_cccccc_1x100.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-icons_222222_256x240.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-icons_2e83ff_256x240.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-icons_454545_256x240.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-icons_888888_256x240.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/images/ui-icons_cd0a0a_256x240.png -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/jquery-ui.min.css -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/jquery-ui/jquery-ui.min.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/md-toc.js -BoHong Li -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/ot/ajax-adapter.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/ot/client.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/ot/codemirror-adapter.js -Cheng-Han, Wu -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/ot/compress.sh -Wu Cheng-Han -=== public/vendor/ot/editor-client.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/ot/ot.min.js -Cheng-Han, Wu -Wu Cheng-Han -=== public/vendor/ot/selection.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/ot/socketio-adapter.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/ot/text-operation.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/ot/undo-manager.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/ot/wrapped-operation.js -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/showup/showup.css -Peter Dave Hello -Wu Cheng-Han -=== public/vendor/showup/showup.js -Peter Dave Hello -Wu Cheng-Han -=== public/views/error.ejs -Cheng-Han, Wu -Wu Cheng-Han -=== public/views/hackmd.ejs -Cheng-Han, Wu -Wu Cheng-Han -=== public/views/hackmd/body.ejs -Cheng-Han, Wu -Florian Rhiem -Ian Dees -Jason Croft -Peter Dave Hello -Wu Cheng-Han -蒼時弦也 -=== public/views/hackmd/foot.ejs -Cheng-Han, Wu -Jannik Lorenz -Peter Dave Hello -Wu Cheng-Han -Yukai Huang -=== public/views/hackmd/footer.ejs -Wu Cheng-Han -=== public/views/hackmd/head.ejs -Cheng-Han, Wu -Peter Dave Hello -Wu Cheng-Han -xnum -Yukai Huang -=== public/views/hackmd/header.ejs -Cheng-Han, Wu -Jannik Lorenz -Jason Croft -Peter Dave Hello -Wu Cheng-Han -xnum -=== public/views/html.hbs -Cheng-Han, Wu -Peter Dave Hello -Wu Cheng-Han -=== public/views/includes/header.ejs -Wu Cheng-Han -Yukai Huang -=== public/views/includes/scripts.ejs -Wu Cheng-Han -Yukai Huang -=== public/views/index.ejs -alecdwm -Cheng-Han, Wu -Florian Rhiem -James Stephenson -Jannik Lorenz -Jason Croft -Peter Dave Hello -Wu Cheng-Han -Yukai Huang -=== public/views/index/body.ejs -Wu Cheng-Han -=== public/views/index/foot.ejs -Wu Cheng-Han -=== public/views/index/footer.ejs -Wu Cheng-Han -=== public/views/index/head.ejs -Cheng-Han, Wu -Peter Dave Hello -Wu Cheng-Han -xnum -Yukai Huang -=== public/views/index/header.ejs -Wu Cheng-Han -=== public/views/pretty.ejs -Cheng-Han, Wu -Peter Dave Hello -Wu Cheng-Han -Yukai Huang -=== public/views/shared/disqus.ejs -Wu Cheng-Han -=== public/views/shared/ga.ejs -Cheng-Han, Wu -Wu Cheng-Han -=== public/views/shared/help-modal.ejs -Cheng-Han, Wu -Wu Cheng-Han -=== public/views/shared/polyfill.ejs -Peter Dave Hello -Wu Cheng-Han -=== public/views/shared/refresh-modal.ejs -Cheng-Han, Wu -Wu Cheng-Han -=== public/views/shared/revision-modal.ejs -Cheng-Han, Wu -Wu Cheng-Han -=== public/views/shared/signin-modal.ejs -alecdwm -Cheng-Han, Wu -Jason Croft -neopostmodern -Sheogorath -Wu Cheng-Han -=== public/views/slide.ejs -butlerx -Cheng-Han, Wu -Peter Dave Hello -Wu Cheng-Han -Yukai Huang -=== tmp/.keep -Wu Cheng-Han -=== webpack.config.js -BoHong Li -Yukai Huang -=== webpack.production.js -BoHong Li -geekyd -Wu Cheng-Han -Yukai Huang -=== webpackBaseConfig.js -BoHong Li -Peter Dave Hello -Wu Cheng-Han -Yukai Huang -=== yarn.lock -BoHong Li -Christian Schuhmann -Wu Cheng-Han -Yukai Huang diff --git a/README.md b/README.md index 095cc41..4cae291 100644 --- a/README.md +++ b/README.md @@ -1,18 +1,18 @@ -HackMD Community Edition +CodiMD === [![Standard - JavaScript Style Guide][standardjs-image]][standardjs-url] [![Join the chat at https://gitter.im/hackmdio/hackmd][gitter-image]][gitter-url] -[![#HackMD on matrix.org][matrix.org-image]][matrix.org-url] +[![#CodiMD on matrix.org][matrix.org-image]][matrix.org-url] [![build status][travis-image]][travis-url] [![version][github-version-badge]][github-release-page] [![Help Contribute to Open Source][codetriage-image]][codetriage-url] [![POEditor][poeditor-image]][poeditor-url] -HackMD lets you create realtime collaborative markdown notes on all platforms. -Inspired by Hackpad, with more focus on speed and flexibility. -Still in the early stage, feel free to fork or contribute to HackMD. +CodiMD lets you create real-time collaborative markdown notes on all platforms. +Inspired by Hackpad, with more focus on speed and flexibility, and build from [HackMD](https://hackmd.io) source code. +Feel free to contribute. Thanks for using! :smile: @@ -20,6 +20,7 @@ Thanks for using! :smile: # Table of Contents +- [HackMD CE became CodiMD](#hackmd-ce-became-codimd) - [Browsers Requirement](#browsers-requirement) - [Installation](#installation) - [Getting started (Native install)](#getting-started-native-install) @@ -27,7 +28,7 @@ Thanks for using! :smile: - [Instructions](#instructions) - [Heroku Deployment](#heroku-deployment) - [Kubernetes](#kubernetes) - - [HackMD by docker container](#hackmd-by-docker-container) + - [CodiMD by docker container](#codimd-by-docker-container) - [Upgrade](#upgrade) - [Native setup](#native-setup) - [Configuration](#configuration) @@ -42,6 +43,16 @@ Thanks for using! :smile: +# HackMD CE became CodiMD + +CodiMD was recently renamed from its former name was HackMD. CodiMD is the free software version of HackMD. It was the original Version of HackMD. The HackMD team initiated CodiMD and provided a solid code base. Due to the need of paying bills, A fork was created and called HackMD EE, which is a SaaS (Software as a Service) product available at [hackmd.io](https://hackmd.io). + +We decided to change the name to break the confusion between HackMD and CodiMD, formally known as HackMD CE, as it never was an open core project. + +Just to more confusion: We are still friends with HackMD :heart: + +*For the whole renaming story, see the [related issue](https://github.com/hackmdio/hackmd/issues/720)* + # Browsers Requirement - ![Chrome](http://browserbadge.com/chrome/47/18px) Chrome >= 47, Chrome for Android >= 47 @@ -60,7 +71,7 @@ Thanks for using! :smile: - Node.js 6.x or up (test up to 7.5.0) - Database (PostgreSQL, MySQL, MariaDB, SQLite, MSSQL) use charset `utf8` - npm (and its dependencies, especially [uWebSockets](https://github.com/uWebSockets/uWebSockets#nodejs-developers), [node-gyp](https://github.com/nodejs/node-gyp#installation)) -- For **building** HackMD we recommend to use a machine with at least **2GB** RAM +- For **building** CodiMD we recommend to use a machine with at least **2GB** RAM ### Instructions @@ -73,9 +84,9 @@ Thanks for using! :smile: ## Heroku Deployment -You can quickly setup a sample Heroku HackMD application by clicking the button below. +You can quickly setup a sample Heroku CodiMD application by clicking the button below. -[![Deploy on Heroku](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy?template=https://github.com/hackmdio/hackmd/tree/master) +[![Deploy on Heroku](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy?template=https://github.com/hackmdio/codimd/tree/master) If you deploy it without the button, keep in mind to use the right buildpacks. For details check `app.json`. @@ -83,10 +94,10 @@ If you deploy it without the button, keep in mind to use the right buildpacks. F To install use `helm install stable/hackmd`. -For all further details, please check out the offical HackMD [K8s helm chart](https://github.com/kubernetes/charts/tree/master/stable/hackmd). +For all further details, please check out the offical CodiMD [K8s helm chart](https://github.com/kubernetes/charts/tree/master/stable/hackmd). -## HackMD by docker container -[![Try in PWD](https://cdn.rawgit.com/play-with-docker/stacks/cff22438/assets/images/button.png)](http://play-with-docker.com?stack=https://github.com/hackmdio/docker-hackmd/raw/master/docker-compose.yml&stack_name=hackmd) +## CodiMD by docker container +[![Try in PWD](https://cdn.rawgit.com/play-with-docker/stacks/cff22438/assets/images/button.png)](http://play-with-docker.com?stack=https://github.com/hackmdio/docker-hackmd/raw/master/docker-compose.yml&stack_name=codimd) **Debian-based version:** @@ -98,11 +109,11 @@ For all further details, please check out the offical HackMD [K8s helm chart](h [![alpine](https://images.microbadger.com/badges/version/hackmdio/hackmd:alpine.svg)](https://microbadger.com/images/hackmdio/hackmd:alpine "Get your own version badge on microbadger.com") [![](https://images.microbadger.com/badges/image/hackmdio/hackmd:alpine.svg)](https://microbadger.com/images/hackmdio/hackmd:alpine "Get your own image badge on microbadger.com") -The easiest way to setup HackMD using docker are using the following three commands: +The easiest way to setup CodiMD using docker are using the following three commands: ```console git clone https://github.com/hackmdio/docker-hackmd.git -cd docker-hackmd +cd docker-codimd docker-compose up ``` Read more about it in the [docker repository…](https://github.com/hackmdio/docker-hackmd) @@ -111,14 +122,14 @@ Read more about it in the [docker repository…](https://github.com/hackmdio/doc ## Native setup -If you are upgrading HackMD from an older version, follow these steps: +If you are upgrading CodiMD from an older version, follow these steps: 1. Fully stop your old server first (important) 2. `git pull` or do whatever that updates the files 3. `npm install` to update dependencies 4. Build front-end bundle by `npm run build` (use `npm run dev` if you are in development) 5. Modify the file named `.sequelizerc`, change the value of the variable `url` with your db connection string - For example: `postgres://username:password@localhost:5432/hackmd` + For example: `postgres://username:password@localhost:5432/codimd` 6. Run `node_modules/.bin/sequelize db:migrate`, this step will migrate your db to the latest schema 7. Start your whole new server! @@ -154,80 +165,82 @@ There are some config settings you need to change in the files below. | --------- | ------ | ----------- | | `NODE_ENV` | `production` or `development` | set current environment (will apply corresponding settings in the `config.json`) | | `DEBUG` | `true` or `false` | set debug mode; show more logs | -| `HMD_DOMAIN` | `hackmd.io` | domain name | -| `HMD_URL_PATH` | `hackmd` | sub URL path, like `www.example.com/` | -| `HMD_PORT` | `80` | web app port | -| `HMD_ALLOW_ORIGIN` | `localhost, hackmd.io` | domain name whitelist (use comma to separate) | -| `HMD_PROTOCOL_USESSL` | `true` or `false` | set to use SSL protocol for resources path (only applied when domain is set) | -| `HMD_URL_ADDPORT` | `true` or `false` | set to add port on callback URL (ports `80` or `443` won't be applied) (only applied when domain is set) | -| `HMD_USECDN` | `true` or `false` | set to use CDN resources or not (default is `true`) | -| `HMD_ALLOW_ANONYMOUS` | `true` or `false` | set to allow anonymous usage (default is `true`) | -| `HMD_ALLOW_ANONYMOUS_EDITS` | `true` or `false` | if `allowAnonymous` is `true`, allow users to select `freely` permission, allowing guests to edit existing notes (default is `false`) | -| `HMD_ALLOW_FREEURL` | `true` or `false` | set to allow new note creation by accessing a nonexistent note URL | -| `HMD_DEFAULT_PERMISSION` | `freely`, `editable`, `limited`, `locked` or `private` | set notes default permission (only applied on signed users) | -| `HMD_DB_URL` | `mysql://localhost:3306/database` | set the database URL | -| `HMD_SESSION_SECRET` | no example | Secret used to sign the session cookie. If non is set, one will randomly generated on startup | -| `HMD_SESSION_LIFE` | `1209600000` | Session life time. (milliseconds) | -| `HMD_FACEBOOK_CLIENTID` | no example | Facebook API client id | -| `HMD_FACEBOOK_CLIENTSECRET` | no example | Facebook API client secret | -| `HMD_TWITTER_CONSUMERKEY` | no example | Twitter API consumer key | -| `HMD_TWITTER_CONSUMERSECRET` | no example | Twitter API consumer secret | -| `HMD_GITHUB_CLIENTID` | no example | GitHub API client id | -| `HMD_GITHUB_CLIENTSECRET` | no example | GitHub API client secret | -| `HMD_GITLAB_SCOPE` | `read_user` or `api` | GitLab API requested scope (default is `api`) (GitLab snippet import/export need `api` scope) | -| `HMD_GITLAB_BASEURL` | no example | GitLab authentication endpoint, set to use other endpoint than GitLab.com (optional) | -| `HMD_GITLAB_CLIENTID` | no example | GitLab API client id | -| `HMD_GITLAB_CLIENTSECRET` | no example | GitLab API client secret | -| `HMD_MATTERMOST_BASEURL` | no example | Mattermost authentication endpoint | -| `HMD_MATTERMOST_CLIENTID` | no example | Mattermost API client id | -| `HMD_MATTERMOST_CLIENTSECRET` | no example | Mattermost API client secret | -| `HMD_DROPBOX_CLIENTID` | no example | Dropbox API client id | -| `HMD_DROPBOX_CLIENTSECRET` | no example | Dropbox API client secret | -| `HMD_GOOGLE_CLIENTID` | no example | Google API client id | -| `HMD_GOOGLE_CLIENTSECRET` | no example | Google API client secret | -| `HMD_LDAP_URL` | `ldap://example.com` | URL of LDAP server | -| `HMD_LDAP_BINDDN` | no example | bindDn for LDAP access | -| `HMD_LDAP_BINDCREDENTIALS` | no example | bindCredentials for LDAP access | -| `HMD_LDAP_SEARCHBASE` | `o=users,dc=example,dc=com` | LDAP directory to begin search from | -| `HMD_LDAP_SEARCHFILTER` | `(uid={{username}})` | LDAP filter to search with | -| `HMD_LDAP_SEARCHATTRIBUTES` | `displayName, mail` | LDAP attributes to search with (use comma to separate) | -| `HMD_LDAP_USERIDFIELD` | `uidNumber` or `uid` or `sAMAccountName` | The LDAP field which is used uniquely identify a user on HackMD | -| `HMD_LDAP_USERNAMEFIELD` | Fallback to userid | The LDAP field which is used as the username on HackMD | -| `HMD_LDAP_TLS_CA` | `server-cert.pem, root.pem` | Root CA for LDAP TLS in PEM format (use comma to separate) | -| `HMD_LDAP_PROVIDERNAME` | `My institution` | Optional name to be displayed at login form indicating the LDAP provider | -| `HMD_SAML_IDPSSOURL` | `https://idp.example.com/sso` | authentication endpoint of IdP. for details, see [guide](docs/guides/auth.md#saml-onelogin). | -| `HMD_SAML_IDPCERT` | `/path/to/cert.pem` | certificate file path of IdP in PEM format | -| `HMD_SAML_ISSUER` | no example | identity of the service provider (optional, default: serverurl)" | -| `HMD_SAML_IDENTIFIERFORMAT` | no example | name identifier format (optional, default: `urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress`) | -| `HMD_SAML_GROUPATTRIBUTE` | `memberOf` | attribute name for group list (optional) | -| `HMD_SAML_REQUIREDGROUPS` | `Hackmd-users` | group names that allowed (use vertical bar to separate) (optional) | -| `HMD_SAML_EXTERNALGROUPS` | `Temporary-staff` | group names that not allowed (use vertical bar to separate) (optional) | -| `HMD_SAML_ATTRIBUTE_ID` | `sAMAccountName` | attribute map for `id` (optional, default: NameID of SAML response) | -| `HMD_SAML_ATTRIBUTE_USERNAME` | `mailNickname` | attribute map for `username` (optional, default: NameID of SAML response) | -| `HMD_SAML_ATTRIBUTE_EMAIL` | `mail` | attribute map for `email` (optional, default: NameID of SAML response if `HMD_SAML_IDENTIFIERFORMAT` is default) | -| `HMD_IMGUR_CLIENTID` | no example | Imgur API client id | -| `HMD_EMAIL` | `true` or `false` | set to allow email signin | -| `HMD_ALLOW_PDF_EXPORT` | `true` or `false` | Enable or disable PDF exports | -| `HMD_ALLOW_EMAIL_REGISTER` | `true` or `false` | set to allow email register (only applied when email is set, default is `true`. Note `bin/manage_users` might help you if registration is `false`.) | -| `HMD_ALLOW_GRAVATAR` | `true` or `false` | set to `false` to disable gravatar as profile picture source on your instance | -| `HMD_IMAGE_UPLOAD_TYPE` | `imgur`, `s3`, `minio` or `filesystem` | Where to upload images. For S3, see our Image Upload Guides for [S3](docs/guides/s3-image-upload.md) or [Minio](docs/guides/minio-image-upload.md) | -| `HMD_S3_ACCESS_KEY_ID` | no example | AWS access key id | -| `HMD_S3_SECRET_ACCESS_KEY` | no example | AWS secret key | -| `HMD_S3_REGION` | `ap-northeast-1` | AWS S3 region | -| `HMD_S3_BUCKET` | no example | AWS S3 bucket name | -| `HMD_MINIO_ACCESS_KEY` | no example | Minio access key | -| `HMD_MINIO_SECRET_KEY` | no example | Minio secret key | -| `HMD_MINIO_ENDPOINT` | `minio.example.org` | Address of your Minio endpoint/instance | -| `HMD_MINIO_PORT` | `9000` | Port that is used for your Minio instance | -| `HMD_MINIO_SECURE` | `true` | If set to `true` HTTPS is used for Minio | -| `HMD_AZURE_CONNECTION_STRING` | no example | Azure Blob Storage connection string | -| `HMD_AZURE_CONTAINER` | no example | Azure Blob Storage container name (automatically created if non existent) | -| `HMD_HSTS_ENABLE` | ` true` | set to enable [HSTS](https://en.wikipedia.org/wiki/HTTP_Strict_Transport_Security) if HTTPS is also enabled (default is ` true`) | -| `HMD_HSTS_INCLUDE_SUBDOMAINS` | `true` | set to include subdomains in HSTS (default is `true`) | -| `HMD_HSTS_MAX_AGE` | `31536000` | max duration in seconds to tell clients to keep HSTS status (default is a year) | -| `HMD_HSTS_PRELOAD` | `true` | whether to allow preloading of the site's HSTS status (e.g. into browsers) | -| `HMD_CSP_ENABLE` | `true` | whether to enable Content Security Policy (directives cannot be configured with environment variables) | -| `HMD_CSP_REPORTURI` | `https://.report-uri.com/r/d/csp/enforce` | Allows to add a URL for CSP reports in case of violations | +| `CMD_DOMAIN` | `codimd.org` | domain name | +| `CMD_URL_PATH` | `codimd` | sub URL path, like `www.example.com/` | +| `CMD_PORT` | `80` | web app port | +| `CMD_ALLOW_ORIGIN` | `localhost, codimd.org` | domain name whitelist (use comma to separate) | +| `CMD_PROTOCOL_USESSL` | `true` or `false` | set to use SSL protocol for resources path (only applied when domain is set) | +| `CMD_URL_ADDPORT` | `true` or `false` | set to add port on callback URL (ports `80` or `443` won't be applied) (only applied when domain is set) | +| `CMD_USECDN` | `true` or `false` | set to use CDN resources or not (default is `true`) | +| `CMD_ALLOW_ANONYMOUS` | `true` or `false` | set to allow anonymous usage (default is `true`) | +| `CMD_ALLOW_ANONYMOUS_EDITS` | `true` or `false` | if `allowAnonymous` is `true`, allow users to select `freely` permission, allowing guests to edit existing notes (default is `false`) | +| `CMD_ALLOW_FREEURL` | `true` or `false` | set to allow new note creation by accessing a nonexistent note URL | +| `CMD_DEFAULT_PERMISSION` | `freely`, `editable`, `limited`, `locked` or `private` | set notes default permission (only applied on signed users) | +| `CMD_DB_URL` | `mysql://localhost:3306/database` | set the database URL | +| `CMD_SESSION_SECRET` | no example | Secret used to sign the session cookie. If non is set, one will randomly generated on startup | +| `CMD_SESSION_LIFE` | `1209600000` | Session life time. (milliseconds) | +| `CMD_FACEBOOK_CLIENTID` | no example | Facebook API client id | +| `CMD_FACEBOOK_CLIENTSECRET` | no example | Facebook API client secret | +| `CMD_TWITTER_CONSUMERKEY` | no example | Twitter API consumer key | +| `CMD_TWITTER_CONSUMERSECRET` | no example | Twitter API consumer secret | +| `CMD_GITHUB_CLIENTID` | no example | GitHub API client id | +| `CMD_GITHUB_CLIENTSECRET` | no example | GitHub API client secret | +| `CMD_GITLAB_SCOPE` | `read_user` or `api` | GitLab API requested scope (default is `api`) (GitLab snippet import/export need `api` scope) | +| `CMD_GITLAB_BASEURL` | no example | GitLab authentication endpoint, set to use other endpoint than GitLab.com (optional) | +| `CMD_GITLAB_CLIENTID` | no example | GitLab API client id | +| `CMD_GITLAB_CLIENTSECRET` | no example | GitLab API client secret | +| `CMD_MATTERMOST_BASEURL` | no example | Mattermost authentication endpoint | +| `CMD_MATTERMOST_CLIENTID` | no example | Mattermost API client id | +| `CMD_MATTERMOST_CLIENTSECRET` | no example | Mattermost API client secret | +| `CMD_DROPBOX_CLIENTID` | no example | Dropbox API client id | +| `CMD_DROPBOX_CLIENTSECRET` | no example | Dropbox API client secret | +| `CMD_GOOGLE_CLIENTID` | no example | Google API client id | +| `CMD_GOOGLE_CLIENTSECRET` | no example | Google API client secret | +| `CMD_LDAP_URL` | `ldap://example.com` | URL of LDAP server | +| `CMD_LDAP_BINDDN` | no example | bindDn for LDAP access | +| `CMD_LDAP_BINDCREDENTIALS` | no example | bindCredentials for LDAP access | +| `CMD_LDAP_SEARCHBASE` | `o=users,dc=example,dc=com` | LDAP directory to begin search from | +| `CMD_LDAP_SEARCHFILTER` | `(uid={{username}})` | LDAP filter to search with | +| `CMD_LDAP_SEARCHATTRIBUTES` | `displayName, mail` | LDAP attributes to search with (use comma to separate) | +| `CMD_LDAP_USERIDFIELD` | `uidNumber` or `uid` or `sAMAccountName` | The LDAP field which is used uniquely identify a user on CodiMD | +| `CMD_LDAP_USERNAMEFIELD` | Fallback to userid | The LDAP field which is used as the username on CodiMD | +| `CMD_LDAP_TLS_CA` | `server-cert.pem, root.pem` | Root CA for LDAP TLS in PEM format (use comma to separate) | +| `CMD_LDAP_PROVIDERNAME` | `My institution` | Optional name to be displayed at login form indicating the LDAP provider | +| `CMD_SAML_IDPSSOURL` | `https://idp.example.com/sso` | authentication endpoint of IdP. for details, see [guide](docs/guides/auth.md#saml-onelogin). | +| `CMD_SAML_IDPCERT` | `/path/to/cert.pem` | certificate file path of IdP in PEM format | +| `CMD_SAML_ISSUER` | no example | identity of the service provider (optional, default: serverurl)" | +| `CMD_SAML_IDENTIFIERFORMAT` | no example | name identifier format (optional, default: `urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress`) | +| `CMD_SAML_GROUPATTRIBUTE` | `memberOf` | attribute name for group list (optional) | +| `CMD_SAML_REQUIREDGROUPS` | `Hackmd-users` | group names that allowed (use vertical bar to separate) (optional) | +| `CMD_SAML_EXTERNALGROUPS` | `Temporary-staff` | group names that not allowed (use vertical bar to separate) (optional) | +| `CMD_SAML_ATTRIBUTE_ID` | `sAMAccountName` | attribute map for `id` (optional, default: NameID of SAML response) | +| `CMD_SAML_ATTRIBUTE_USERNAME` | `mailNickname` | attribute map for `username` (optional, default: NameID of SAML response) | +| `CMD_SAML_ATTRIBUTE_EMAIL` | `mail` | attribute map for `email` (optional, default: NameID of SAML response if `CMD_SAML_IDENTIFIERFORMAT` is default) | +| `CMD_IMGUR_CLIENTID` | no example | Imgur API client id | +| `CMD_EMAIL` | `true` or `false` | set to allow email signin | +| `CMD_ALLOW_PDF_EXPORT` | `true` or `false` | Enable or disable PDF exports | +| `CMD_ALLOW_EMAIL_REGISTER` | `true` or `false` | set to allow email register (only applied when email is set, default is `true`. Note `bin/manage_users` might help you if registration is `false`.) | +| `CMD_ALLOW_GRAVATAR` | `true` or `false` | set to `false` to disable gravatar as profile picture source on your instance | +| `CMD_IMAGE_UPLOAD_TYPE` | `imgur`, `s3`, `minio` or `filesystem` | Where to upload images. For S3, see our Image Upload Guides for [S3](docs/guides/s3-image-upload.md) or [Minio](docs/guides/minio-image-upload.md) | +| `CMD_S3_ACCESS_KEY_ID` | no example | AWS access key id | +| `CMD_S3_SECRET_ACCESS_KEY` | no example | AWS secret key | +| `CMD_S3_REGION` | `ap-northeast-1` | AWS S3 region | +| `CMD_S3_BUCKET` | no example | AWS S3 bucket name | +| `CMD_MINIO_ACCESS_KEY` | no example | Minio access key | +| `CMD_MINIO_SECRET_KEY` | no example | Minio secret key | +| `CMD_MINIO_ENDPOINT` | `minio.example.org` | Address of your Minio endpoint/instance | +| `CMD_MINIO_PORT` | `9000` | Port that is used for your Minio instance | +| `CMD_MINIO_SECURE` | `true` | If set to `true` HTTPS is used for Minio | +| `CMD_AZURE_CONNECTION_STRING` | no example | Azure Blob Storage connection string | +| `CMD_AZURE_CONTAINER` | no example | Azure Blob Storage container name (automatically created if non existent) | +| `CMD_HSTS_ENABLE` | ` true` | set to enable [HSTS](https://en.wikipedia.org/wiki/HTTP_Strict_Transport_Security) if HTTPS is also enabled (default is ` true`) | +| `CMD_HSTS_INCLUDE_SUBDOMAINS` | `true` | set to include subdomains in HSTS (default is `true`) | +| `CMD_HSTS_MAX_AGE` | `31536000` | max duration in seconds to tell clients to keep HSTS status (default is a year) | +| `CMD_HSTS_PRELOAD` | `true` | whether to allow preloading of the site's HSTS status (e.g. into browsers) | +| `CMD_CSP_ENABLE` | `true` | whether to enable Content Security Policy (directives cannot be configured with environment variables) | +| `CMD_CSP_REPORTURI` | `https://.report-uri.com/r/d/csp/enforce` | Allows to add a URL for CSP reports in case of violations | + +***Note:** Due to the rename process we renamed all `HMD_`-prefix variables to be `CMD_`-prefixed. The old ones continue to work.* ## Application settings `config.json` @@ -235,7 +248,7 @@ There are some config settings you need to change in the files below. | --------- | ------ | ----------- | | `debug` | `true` or `false` | set debug mode, show more logs | | `domain` | `localhost` | domain name | -| `urlPath` | `hackmd` | sub URL path, like `www.example.com/` | +| `urlPath` | `codimd` | sub URL path, like `www.example.com/` | | `port` | `80` | web app port | | `allowOrigin` | `['localhost']` | domain name whitelist | | `useSSL` | `true` or `false` | set to use SSL server (if `true`, will auto turn on `protocolUseSSL`) | @@ -249,9 +262,9 @@ There are some config settings you need to change in the files below. | `allowFreeURL` | `true` or `false` | set to allow new note creation by accessing a nonexistent note URL | | `defaultPermission` | `freely`, `editable`, `limited`, `locked`, `protected` or `private` | set notes default permission (only applied on signed users) | | `dbURL` | `mysql://localhost:3306/database` | set the db URL; if set, then db config (below) won't be applied | -| `db` | `{ "dialect": "sqlite", "storage": "./db.hackmd.sqlite" }` | set the db configs, [see more here](http://sequelize.readthedocs.org/en/latest/api/sequelize/) | +| `db` | `{ "dialect": "sqlite", "storage": "./db.codimd.sqlite" }` | set the db configs, [see more here](http://sequelize.readthedocs.org/en/latest/api/sequelize/) | | `sslKeyPath` | `./cert/client.key` | SSL key path (only need when you set `useSSL`) | -| `sslCertPath` | `./cert/hackmd_io.crt` | SSL cert path (only need when you set `useSSL`) | +| `sslCertPath` | `./cert/codimd_io.crt` | SSL cert path (only need when you set `useSSL`) | | `sslCAPath` | `['./cert/COMODORSAAddTrustCA.crt']` | SSL ca chain (only need when you set `useSSL`) | | `dhParamPath` | `./cert/dhparam.pem` | SSL dhparam path (only need when you set `useSSL`) | | `tmpPath` | `./tmp/` | temp directory path | @@ -304,7 +317,7 @@ There are some config settings you need to change in the files below. ## Structure ```text -hackmd/ +codimd/ ├── tmp/ --- temporary files ├── docs/ --- document files ├── lib/ --- server libraries @@ -330,15 +343,15 @@ See more at [http://operational-transformation.github.io/](http://operational-tr [gitter-image]: https://badges.gitter.im/Join%20Chat.svg [gitter-url]: https://gitter.im/hackmdio/hackmd?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge -[matrix.org-image]: https://img.shields.io/badge/Matrix.org-%23HackMD@matrix.org-green.svg -[matrix.org-url]: https://riot.im/app/#/room/#hackmd:matrix.org -[travis-image]: https://travis-ci.org/hackmdio/hackmd.svg?branch=master -[travis-url]: https://travis-ci.org/hackmdio/hackmd -[github-version-badge]: https://img.shields.io/github/release/hackmdio/hackmd.svg -[github-release-page]: https://github.com/hackmdio/hackmd/releases +[matrix.org-image]: https://img.shields.io/badge/Matrix.org-%23CodiMD@matrix.org-green.svg +[matrix.org-url]: https://riot.im/app/#/room/#codimd:matrix.org +[travis-image]: https://travis-ci.org/hackmdio/codimd.svg?branch=master +[travis-url]: https://travis-ci.org/hackmdio/codimd +[github-version-badge]: https://img.shields.io/github/release/hackmdio/codimd.svg +[github-release-page]: https://github.com/hackmdio/codimd/releases [standardjs-image]: https://cdn.rawgit.com/feross/standard/master/badge.svg [standardjs-url]: https://github.com/feross/standard -[codetriage-image]: https://www.codetriage.com/hackmdio/hackmd/badges/users.svg -[codetriage-url]: https://www.codetriage.com/hackmdio/hackmd +[codetriage-image]: https://www.codetriage.com/hackmdio/codimd/badges/users.svg +[codetriage-url]: https://www.codetriage.com/hackmdio/codimd [poeditor-image]: https://img.shields.io/badge/POEditor-translate-blue.svg [poeditor-url]: https://poeditor.com/join/project/1OpGjF2Jir diff --git a/app.js b/app.js index bfb5a49..e247913 100644 --- a/app.js +++ b/app.js @@ -163,6 +163,7 @@ app.use(passport.session()) app.use(require('./lib/web/middleware/checkURIValid')) // redirect url without trailing slashes app.use(require('./lib/web/middleware/redirectWithoutTrailingSlashes')) +app.use(require('./lib/web/middleware/codiMDVersion')) // routes need sessions // template files @@ -234,7 +235,7 @@ process.on('uncaughtException', function (err) { // install exit handler function handleTermSignals () { - logger.info('hackmd has been killed by signal, try to exit gracefully...') + logger.info('CodiMD has been killed by signal, try to exit gracefully...') realtime.maintenance = true // disconnect all socket.io clients Object.keys(io.sockets.sockets).forEach(function (key) { diff --git a/app.json b/app.json index 36877e6..6a6142e 100644 --- a/app.json +++ b/app.json @@ -1,5 +1,5 @@ { - "name": "HackMD", + "name": "CodiMD", "description": "Realtime collaborative markdown notes on all platforms", "keywords": [ "Collaborative", @@ -7,8 +7,8 @@ "Notes" ], "website": "https://hackmd.io", - "repository": "https://github.com/hackmdio/hackmd", - "logo": "https://github.com/hackmdio/hackmd/raw/master/public/hackmd-icon-1024.png", + "repository": "https://github.com/hackmdio/codimd", + "logo": "https://github.com/hackmdio/codimd/raw/master/public/codimd-icon-1024.png", "success_url": "/", "env": { "BUILD_ASSETS": { diff --git a/bin/setup b/bin/setup index 3edffc4..122cb7a 100755 --- a/bin/setup +++ b/bin/setup @@ -33,11 +33,10 @@ BUILD_ASSETS=false npm install cat << EOF -Edit the following config file to setup hackmd server and client. -Read more info at https://github.com/hackmdio/hackmd#configuration-files +Edit the following config file to setup CodiMD server and client. +Read more info at https://github.com/hackmdio/codimd#configuration-files -* config.json -- server config -* public/js/config.js -- client config +* config.json -- CodiMD config * .sequelizerc -- db config EOF diff --git a/config.json.example b/config.json.example index e07052b..1f2ec3d 100644 --- a/config.json.example +++ b/config.json.example @@ -11,7 +11,7 @@ }, "db": { "dialect": "sqlite", - "storage": "./db.hackmd.sqlite" + "storage": "./db.codimd.sqlite" } }, "production": { @@ -34,7 +34,7 @@ "db": { "username": "", "password": "", - "database": "hackmd", + "database": "codimd", "host": "localhost", "port": "5432", "dialect": "postgres" diff --git a/docs/guides/auth/github.md b/docs/guides/auth/github.md index 62910cb..d6a1095 100644 --- a/docs/guides/auth/github.md +++ b/docs/guides/auth/github.md @@ -1,6 +1,8 @@ Authentication guide - GitHub === +***Note:** This guide was written before the renaming. Just replace `HackMD` with `CodiMD` in your mind :smile: thanks!* + 1. Sign-in or sign-up for a GitHub account 2. Navigate to developer settings in your GitHub account [here](https://github.com/settings/developers) and select the "OAuth Apps" tab 3. Click on the **New OAuth App** button, to create a new OAuth App: diff --git a/docs/guides/auth/gitlab-self-hosted.md b/docs/guides/auth/gitlab-self-hosted.md index 361ee95..89bc996 100644 --- a/docs/guides/auth/gitlab-self-hosted.md +++ b/docs/guides/auth/gitlab-self-hosted.md @@ -1,6 +1,8 @@ # GitLab (self-hosted) === +***Note:** This guide was written before the renaming. Just replace `HackMD` with `CodiMD` in your mind :smile: thanks!* + 1. Sign in to your GitLab 2. Navigate to the application management page at `https://your.gitlab.domain/admin/applications` (admin permissions required) 3. Click **New application** to create a new application and fill out the registration form: diff --git a/docs/guides/auth/saml-onelogin.md b/docs/guides/auth/saml-onelogin.md index 245876c..02a5ffa 100644 --- a/docs/guides/auth/saml-onelogin.md +++ b/docs/guides/auth/saml-onelogin.md @@ -1,6 +1,8 @@ Authentication guide - SAML (OneLogin) === +***Note:** This guide was written before the renaming. Just replace `HackMD` with `CodiMD` in your mind :smile: thanks!* + 1. Sign-in or sign-up for an OneLogin account. (available free trial for 2 weeks) 2. Go to the administration page. 3. Select the **APPS** menu and click on the **Add Apps**. diff --git a/docs/guides/auth/saml.md b/docs/guides/auth/saml.md index 9a51667..97ac9d3 100644 --- a/docs/guides/auth/saml.md +++ b/docs/guides/auth/saml.md @@ -1,6 +1,8 @@ Authentication guide - SAML === +***Note:** This guide was written before the renaming. Just replace `HackMD` with `CodiMD` in your mind :smile: thanks!* + The basic procedure is the same as the case of OneLogin which is mentioned in [OneLogin-Guide](./saml-onelogin.md). If you want to match your IdP, you can use more configurations as below. * If your IdP accepts metadata XML of the service provider to ease configuraion, use this url to download metadata XML. diff --git a/docs/guides/auth/twitter.md b/docs/guides/auth/twitter.md index 02309ca..1b96288 100644 --- a/docs/guides/auth/twitter.md +++ b/docs/guides/auth/twitter.md @@ -1,6 +1,8 @@ Authentication guide - Twitter === +***Note:** This guide was written before the renaming. Just replace `HackMD` with `CodiMD` in your mind :smile: thanks!* + 1. Sign-in or sign-up for a Twitter account 2. Go to the Twitter Application management page [here](https://apps.twitter.com/) 3. Click on the **Create New App** button to create a new Twitter app: diff --git a/docs/guides/minio-image-upload.md b/docs/guides/minio-image-upload.md index c2ba25b..7f5796c 100644 --- a/docs/guides/minio-image-upload.md +++ b/docs/guides/minio-image-upload.md @@ -1,6 +1,8 @@ -Minio Guide for HackMD +Minio Guide for CodiMD === +***Note:** This guide was written before the renaming. Just replace `HackMD` with `CodiMD` in your mind :smile: thanks!* + 1. First of all you need to setup Minio itself. Please refer to the [official Minio docs](https://docs.minio.io/) for an diff --git a/docs/guides/s3-image-upload.md b/docs/guides/s3-image-upload.md index ff9598a..dc5e420 100644 --- a/docs/guides/s3-image-upload.md +++ b/docs/guides/s3-image-upload.md @@ -1,4 +1,6 @@ -# Guide - Setup HackMD S3 image upload +# Guide - Setup CodiMD S3 image upload + +***Note:** This guide was written before the renaming. Just replace `HackMD` with `CodiMD` in your mind :smile: thanks!* 1. Go to [AWS S3 console](https://console.aws.amazon.com/s3/home) and create a new bucket. diff --git a/lib/config/default.js b/lib/config/default.js index 8e71029..5c39a4d 100644 --- a/lib/config/default.js +++ b/lib/config/default.js @@ -41,7 +41,7 @@ module.exports = { defaultNotePath: './public/default.md', docsPath: './public/docs', indexPath: './public/views/index.ejs', - hackmdPath: './public/views/hackmd.ejs', + codimdPath: './public/views/codimd.ejs', errorPath: './public/views/error.ejs', prettyPath: './public/views/pretty.ejs', slidePath: './public/views/slide.ejs', diff --git a/lib/config/environment.js b/lib/config/environment.js index 0ca3d92..d850ac9 100644 --- a/lib/config/environment.js +++ b/lib/config/environment.js @@ -3,123 +3,123 @@ const {toBooleanConfig, toArrayConfig, toIntegerConfig} = require('./utils') module.exports = { - domain: process.env.HMD_DOMAIN, - urlPath: process.env.HMD_URL_PATH, - port: toIntegerConfig(process.env.HMD_PORT), - urlAddPort: toBooleanConfig(process.env.HMD_URL_ADDPORT), - useSSL: toBooleanConfig(process.env.HMD_USESSL), + domain: process.env.CMD_DOMAIN, + urlPath: process.env.CMD_URL_PATH, + port: toIntegerConfig(process.env.CMD_PORT), + urlAddPort: toBooleanConfig(process.env.CMD_URL_ADDPORT), + useSSL: toBooleanConfig(process.env.CMD_USESSL), hsts: { - enable: toBooleanConfig(process.env.HMD_HSTS_ENABLE), - maxAgeSeconds: process.env.HMD_HSTS_MAX_AGE, - includeSubdomains: toBooleanConfig(process.env.HMD_HSTS_INCLUDE_SUBDOMAINS), - preload: toBooleanConfig(process.env.HMD_HSTS_PRELOAD) + enable: toBooleanConfig(process.env.CMD_HSTS_ENABLE), + maxAgeSeconds: process.env.CMD_HSTS_MAX_AGE, + includeSubdomains: toBooleanConfig(process.env.CMD_HSTS_INCLUDE_SUBDOMAINS), + preload: toBooleanConfig(process.env.CMD_HSTS_PRELOAD) }, csp: { - enable: toBooleanConfig(process.env.HMD_CSP_ENABLE), - reportURI: process.env.HMD_CSP_REPORTURI + enable: toBooleanConfig(process.env.CMD_CSP_ENABLE), + reportURI: process.env.CMD_CSP_REPORTURI }, - protocolUseSSL: toBooleanConfig(process.env.HMD_PROTOCOL_USESSL), - allowOrigin: toArrayConfig(process.env.HMD_ALLOW_ORIGIN), - useCDN: toBooleanConfig(process.env.HMD_USECDN), - allowAnonymous: toBooleanConfig(process.env.HMD_ALLOW_ANONYMOUS), - allowAnonymousEdits: toBooleanConfig(process.env.HMD_ALLOW_ANONYMOUS_EDITS), - allowFreeURL: toBooleanConfig(process.env.HMD_ALLOW_FREEURL), - defaultPermission: process.env.HMD_DEFAULT_PERMISSION, - dbURL: process.env.HMD_DB_URL, - sessionSecret: process.env.HMD_SESSION_SECRET, - sessionLife: toIntegerConfig(process.env.HMD_SESSION_LIFE), - imageUploadType: process.env.HMD_IMAGE_UPLOAD_TYPE, + protocolUseSSL: toBooleanConfig(process.env.CMD_PROTOCOL_USESSL), + allowOrigin: toArrayConfig(process.env.CMD_ALLOW_ORIGIN), + useCDN: toBooleanConfig(process.env.CMD_USECDN), + allowAnonymous: toBooleanConfig(process.env.CMD_ALLOW_ANONYMOUS), + allowAnonymousEdits: toBooleanConfig(process.env.CMD_ALLOW_ANONYMOUS_EDITS), + allowFreeURL: toBooleanConfig(process.env.CMD_ALLOW_FREEURL), + defaultPermission: process.env.CMD_DEFAULT_PERMISSION, + dbURL: process.env.CMD_DB_URL, + sessionSecret: process.env.CMD_SESSION_SECRET, + sessionLife: toIntegerConfig(process.env.CMD_SESSION_LIFE), + imageUploadType: process.env.CMD_IMAGE_UPLOAD_TYPE, imgur: { - clientID: process.env.HMD_IMGUR_CLIENTID + clientID: process.env.CMD_IMGUR_CLIENTID }, s3: { - accessKeyId: process.env.HMD_S3_ACCESS_KEY_ID, - secretAccessKey: process.env.HMD_S3_SECRET_ACCESS_KEY, - region: process.env.HMD_S3_REGION + accessKeyId: process.env.CMD_S3_ACCESS_KEY_ID, + secretAccessKey: process.env.CMD_S3_SECRET_ACCESS_KEY, + region: process.env.CMD_S3_REGION }, minio: { - accessKey: process.env.HMD_MINIO_ACCESS_KEY, - secretKey: process.env.HMD_MINIO_SECRET_KEY, - endPoint: process.env.HMD_MINIO_ENDPOINT, - secure: toBooleanConfig(process.env.HMD_MINIO_SECURE), - port: toIntegerConfig(process.env.HMD_MINIO_PORT) + accessKey: process.env.CMD_MINIO_ACCESS_KEY, + secretKey: process.env.CMD_MINIO_SECRET_KEY, + endPoint: process.env.CMD_MINIO_ENDPOINT, + secure: toBooleanConfig(process.env.CMD_MINIO_SECURE), + port: toIntegerConfig(process.env.CMD_MINIO_PORT) }, - s3bucket: process.env.HMD_S3_BUCKET, + s3bucket: process.env.CMD_S3_BUCKET, azure: { - connectionString: process.env.HMD_AZURE_CONNECTION_STRING, - container: process.env.HMD_AZURE_CONTAINER + connectionString: process.env.CMD_AZURE_CONNECTION_STRING, + container: process.env.CMD_AZURE_CONTAINER }, facebook: { - clientID: process.env.HMD_FACEBOOK_CLIENTID, - clientSecret: process.env.HMD_FACEBOOK_CLIENTSECRET + clientID: process.env.CMD_FACEBOOK_CLIENTID, + clientSecret: process.env.CMD_FACEBOOK_CLIENTSECRET }, twitter: { - consumerKey: process.env.HMD_TWITTER_CONSUMERKEY, - consumerSecret: process.env.HMD_TWITTER_CONSUMERSECRET + consumerKey: process.env.CMD_TWITTER_CONSUMERKEY, + consumerSecret: process.env.CMD_TWITTER_CONSUMERSECRET }, github: { - clientID: process.env.HMD_GITHUB_CLIENTID, - clientSecret: process.env.HMD_GITHUB_CLIENTSECRET + clientID: process.env.CMD_GITHUB_CLIENTID, + clientSecret: process.env.CMD_GITHUB_CLIENTSECRET }, gitlab: { - baseURL: process.env.HMD_GITLAB_BASEURL, - clientID: process.env.HMD_GITLAB_CLIENTID, - clientSecret: process.env.HMD_GITLAB_CLIENTSECRET, - scope: process.env.HMD_GITLAB_SCOPE + baseURL: process.env.CMD_GITLAB_BASEURL, + clientID: process.env.CMD_GITLAB_CLIENTID, + clientSecret: process.env.CMD_GITLAB_CLIENTSECRET, + scope: process.env.CMD_GITLAB_SCOPE }, mattermost: { - baseURL: process.env.HMD_MATTERMOST_BASEURL, - clientID: process.env.HMD_MATTERMOST_CLIENTID, - clientSecret: process.env.HMD_MATTERMOST_CLIENTSECRET + baseURL: process.env.CMD_MATTERMOST_BASEURL, + clientID: process.env.CMD_MATTERMOST_CLIENTID, + clientSecret: process.env.CMD_MATTERMOST_CLIENTSECRET }, oauth2: { - baseURL: process.env.HMD_OAUTH2_BASEURL, - userProfileURL: process.env.HMD_OAUTH2_USER_PROFILE_URL, - userProfileUsernameAttr: process.env.HMD_OAUTH2_USER_PROFILE_USERNAME_ATTR, - userProfileDisplayNameAttr: process.env.HMD_OAUTH2_USER_PROFILE_DISPLAY_NAME_ATTR, - userProfileEmailAttr: process.env.HMD_OAUTH2_USER_PROFILE_EMAIL_ATTR, - tokenURL: process.env.HMD_OAUTH2_TOKEN_URL, - authorizationURL: process.env.HMD_OAUTH2_AUTHORIZATION_URL, - clientID: process.env.HMD_OAUTH2_CLIENT_ID, - clientSecret: process.env.HMD_OAUTH2_CLIENT_SECRET + baseURL: process.env.CMD_OAUTH2_BASEURL, + userProfileURL: process.env.CMD_OAUTH2_USER_PROFILE_URL, + userProfileUsernameAttr: process.env.CMD_OAUTH2_USER_PROFILE_USERNAME_ATTR, + userProfileDisplayNameAttr: process.env.CMD_OAUTH2_USER_PROFILE_DISPLAY_NAME_ATTR, + userProfileEmailAttr: process.env.CMD_OAUTH2_USER_PROFILE_EMAIL_ATTR, + tokenURL: process.env.CMD_OAUTH2_TOKEN_URL, + authorizationURL: process.env.CMD_OAUTH2_AUTHORIZATION_URL, + clientID: process.env.CMD_OAUTH2_CLIENT_ID, + clientSecret: process.env.CMD_OAUTH2_CLIENT_SECRET }, dropbox: { - clientID: process.env.HMD_DROPBOX_CLIENTID, - clientSecret: process.env.HMD_DROPBOX_CLIENTSECRET, - appKey: process.env.HMD_DROPBOX_APPKEY + clientID: process.env.CMD_DROPBOX_CLIENTID, + clientSecret: process.env.CMD_DROPBOX_CLIENTSECRET, + appKey: process.env.CMD_DROPBOX_APPKEY }, google: { - clientID: process.env.HMD_GOOGLE_CLIENTID, - clientSecret: process.env.HMD_GOOGLE_CLIENTSECRET + clientID: process.env.CMD_GOOGLE_CLIENTID, + clientSecret: process.env.CMD_GOOGLE_CLIENTSECRET }, ldap: { - providerName: process.env.HMD_LDAP_PROVIDERNAME, - url: process.env.HMD_LDAP_URL, - bindDn: process.env.HMD_LDAP_BINDDN, - bindCredentials: process.env.HMD_LDAP_BINDCREDENTIALS, - searchBase: process.env.HMD_LDAP_SEARCHBASE, - searchFilter: process.env.HMD_LDAP_SEARCHFILTER, - searchAttributes: toArrayConfig(process.env.HMD_LDAP_SEARCHATTRIBUTES), - usernameField: process.env.HMD_LDAP_USERNAMEFIELD, - useridField: process.env.HMD_LDAP_USERIDFIELD, - tlsca: process.env.HMD_LDAP_TLS_CA + providerName: process.env.CMD_LDAP_PROVIDERNAME, + url: process.env.CMD_LDAP_URL, + bindDn: process.env.CMD_LDAP_BINDDN, + bindCredentials: process.env.CMD_LDAP_BINDCREDENTIALS, + searchBase: process.env.CMD_LDAP_SEARCHBASE, + searchFilter: process.env.CMD_LDAP_SEARCHFILTER, + searchAttributes: toArrayConfig(process.env.CMD_LDAP_SEARCHATTRIBUTES), + usernameField: process.env.CMD_LDAP_USERNAMEFIELD, + useridField: process.env.CMD_LDAP_USERIDFIELD, + tlsca: process.env.CMD_LDAP_TLS_CA }, saml: { - idpSsoUrl: process.env.HMD_SAML_IDPSSOURL, - idpCert: process.env.HMD_SAML_IDPCERT, - issuer: process.env.HMD_SAML_ISSUER, - identifierFormat: process.env.HMD_SAML_IDENTIFIERFORMAT, - groupAttribute: process.env.HMD_SAML_GROUPATTRIBUTE, - externalGroups: toArrayConfig(process.env.HMD_SAML_EXTERNALGROUPS, '|', []), - requiredGroups: toArrayConfig(process.env.HMD_SAML_REQUIREDGROUPS, '|', []), + idpSsoUrl: process.env.CMD_SAML_IDPSSOURL, + idpCert: process.env.CMD_SAML_IDPCERT, + issuer: process.env.CMD_SAML_ISSUER, + identifierFormat: process.env.CMD_SAML_IDENTIFIERFORMAT, + groupAttribute: process.env.CMD_SAML_GROUPATTRIBUTE, + externalGroups: toArrayConfig(process.env.CMD_SAML_EXTERNALGROUPS, '|', []), + requiredGroups: toArrayConfig(process.env.CMD_SAML_REQUIREDGROUPS, '|', []), attribute: { - id: process.env.HMD_SAML_ATTRIBUTE_ID, - username: process.env.HMD_SAML_ATTRIBUTE_USERNAME, - email: process.env.HMD_SAML_ATTRIBUTE_EMAIL + id: process.env.CMD_SAML_ATTRIBUTE_ID, + username: process.env.CMD_SAML_ATTRIBUTE_USERNAME, + email: process.env.CMD_SAML_ATTRIBUTE_EMAIL } }, - email: toBooleanConfig(process.env.HMD_EMAIL), - allowEmailRegister: toBooleanConfig(process.env.HMD_ALLOW_EMAIL_REGISTER), - allowGravatar: toBooleanConfig(process.env.HMD_ALLOW_GRAVATAR), - allowPDFExport: toBooleanConfig(process.env.HMD_ALLOW_PDF_EXPORT) + email: toBooleanConfig(process.env.CMD_EMAIL), + allowEmailRegister: toBooleanConfig(process.env.CMD_ALLOW_EMAIL_REGISTER), + allowGravatar: toBooleanConfig(process.env.CMD_ALLOW_GRAVATAR), + allowPDFExport: toBooleanConfig(process.env.CMD_ALLOW_PDF_EXPORT) } diff --git a/lib/config/hackmdEnvironment.js b/lib/config/hackmdEnvironment.js new file mode 100644 index 0000000..e1c1156 --- /dev/null +++ b/lib/config/hackmdEnvironment.js @@ -0,0 +1,124 @@ +'use strict' + +const {toBooleanConfig, toArrayConfig, toIntegerConfig} = require('./utils') + +module.exports = { + domain: process.env.HMD_DOMAIN, + urlPath: process.env.HMD_URL_PATH, + port: toIntegerConfig(process.env.HMD_PORT), + urlAddPort: toBooleanConfig(process.env.HMD_URL_ADDPORT), + useSSL: toBooleanConfig(process.env.HMD_USESSL), + hsts: { + enable: toBooleanConfig(process.env.HMD_HSTS_ENABLE), + maxAgeSeconds: process.env.HMD_HSTS_MAX_AGE, + includeSubdomains: toBooleanConfig(process.env.HMD_HSTS_INCLUDE_SUBDOMAINS), + preload: toBooleanConfig(process.env.HMD_HSTS_PRELOAD) + }, + csp: { + enable: toBooleanConfig(process.env.HMD_CSP_ENABLE), + reportURI: process.env.HMD_CSP_REPORTURI + }, + protocolUseSSL: toBooleanConfig(process.env.HMD_PROTOCOL_USESSL), + allowOrigin: toArrayConfig(process.env.HMD_ALLOW_ORIGIN), + useCDN: toBooleanConfig(process.env.HMD_USECDN), + allowAnonymous: toBooleanConfig(process.env.HMD_ALLOW_ANONYMOUS), + allowAnonymousEdits: toBooleanConfig(process.env.HMD_ALLOW_ANONYMOUS_EDITS), + allowFreeURL: toBooleanConfig(process.env.HMD_ALLOW_FREEURL), + defaultPermission: process.env.HMD_DEFAULT_PERMISSION, + dbURL: process.env.HMD_DB_URL, + sessionSecret: process.env.HMD_SESSION_SECRET, + sessionLife: toIntegerConfig(process.env.HMD_SESSION_LIFE), + imageUploadType: process.env.HMD_IMAGE_UPLOAD_TYPE, + imgur: { + clientID: process.env.HMD_IMGUR_CLIENTID + }, + s3: { + accessKeyId: process.env.HMD_S3_ACCESS_KEY_ID, + secretAccessKey: process.env.HMD_S3_SECRET_ACCESS_KEY, + region: process.env.HMD_S3_REGION + }, + minio: { + accessKey: process.env.HMD_MINIO_ACCESS_KEY, + secretKey: process.env.HMD_MINIO_SECRET_KEY, + endPoint: process.env.HMD_MINIO_ENDPOINT, + secure: toBooleanConfig(process.env.HMD_MINIO_SECURE), + port: toIntegerConfig(process.env.HMD_MINIO_PORT) + }, + s3bucket: process.env.HMD_S3_BUCKET, + azure: { + connectionString: process.env.HMD_AZURE_CONNECTION_STRING, + container: process.env.HMD_AZURE_CONTAINER + }, + facebook: { + clientID: process.env.HMD_FACEBOOK_CLIENTID, + clientSecret: process.env.HMD_FACEBOOK_CLIENTSECRET + }, + twitter: { + consumerKey: process.env.HMD_TWITTER_CONSUMERKEY, + consumerSecret: process.env.HMD_TWITTER_CONSUMERSECRET + }, + github: { + clientID: process.env.HMD_GITHUB_CLIENTID, + clientSecret: process.env.HMD_GITHUB_CLIENTSECRET + }, + gitlab: { + baseURL: process.env.HMD_GITLAB_BASEURL, + clientID: process.env.HMD_GITLAB_CLIENTID, + clientSecret: process.env.HMD_GITLAB_CLIENTSECRET, + scope: process.env.HMD_GITLAB_SCOPE + }, + mattermost: { + baseURL: process.env.HMD_MATTERMOST_BASEURL, + clientID: process.env.HMD_MATTERMOST_CLIENTID, + clientSecret: process.env.HMD_MATTERMOST_CLIENTSECRET + }, + oauth2: { + baseURL: process.env.HMD_OAUTH2_BASEURL, + userProfileURL: process.env.HMD_OAUTH2_USER_PROFILE_URL, + userProfileUsernameAttr: process.env.HMD_OAUTH2_USER_PROFILE_USERNAME_ATTR, + userProfileDisplayNameAttr: process.env.HMD_OAUTH2_USER_PROFILE_DISPLAY_NAME_ATTR, + userProfileEmailAttr: process.env.HMD_OAUTH2_USER_PROFILE_EMAIL_ATTR, + tokenURL: process.env.HMD_OAUTH2_TOKEN_URL, + authorizationURL: process.env.HMD_OAUTH2_AUTHORIZATION_URL, + clientID: process.env.HMD_OAUTH2_CLIENT_ID, + clientSecret: process.env.HMD_OAUTH2_CLIENT_SECRET + }, + dropbox: { + clientID: process.env.HMD_DROPBOX_CLIENTID, + clientSecret: process.env.HMD_DROPBOX_CLIENTSECRET, + appKey: process.env.HMD_DROPBOX_APPKEY + }, + google: { + clientID: process.env.HMD_GOOGLE_CLIENTID, + clientSecret: process.env.HMD_GOOGLE_CLIENTSECRET + }, + ldap: { + providerName: process.env.HMD_LDAP_PROVIDERNAME, + url: process.env.HMD_LDAP_URL, + bindDn: process.env.HMD_LDAP_BINDDN, + bindCredentials: process.env.HMD_LDAP_BINDCREDENTIALS, + searchBase: process.env.HMD_LDAP_SEARCHBASE, + searchFilter: process.env.HMD_LDAP_SEARCHFILTER, + searchAttributes: toArrayConfig(process.env.HMD_LDAP_SEARCHATTRIBUTES), + usernameField: process.env.HMD_LDAP_USERNAMEFIELD, + useridField: process.env.HMD_LDAP_USERIDFIELD, + tlsca: process.env.HMD_LDAP_TLS_CA + }, + saml: { + idpSsoUrl: process.env.HMD_SAML_IDPSSOURL, + idpCert: process.env.HMD_SAML_IDPCERT, + issuer: process.env.HMD_SAML_ISSUER, + identifierFormat: process.env.HMD_SAML_IDENTIFIERFORMAT, + groupAttribute: process.env.HMD_SAML_GROUPATTRIBUTE, + externalGroups: toArrayConfig(process.env.HMD_SAML_EXTERNALGROUPS, '|', []), + requiredGroups: toArrayConfig(process.env.HMD_SAML_REQUIREDGROUPS, '|', []), + attribute: { + id: process.env.HMD_SAML_ATTRIBUTE_ID, + username: process.env.HMD_SAML_ATTRIBUTE_USERNAME, + email: process.env.HMD_SAML_ATTRIBUTE_EMAIL + } + }, + email: toBooleanConfig(process.env.HMD_EMAIL), + allowEmailRegister: toBooleanConfig(process.env.HMD_ALLOW_EMAIL_REGISTER), + allowPDFExport: toBooleanConfig(process.env.HMD_ALLOW_PDF_EXPORT) +} diff --git a/lib/config/index.js b/lib/config/index.js index 7933044..8705b10 100644 --- a/lib/config/index.js +++ b/lib/config/index.js @@ -33,6 +33,7 @@ merge(config, debugConfig) merge(config, packageConfig) merge(config, fileConfig) merge(config, require('./oldEnvironment')) +merge(config, require('./hackmdEnvironment')) merge(config, require('./environment')) merge(config, require('./dockerSecret')) @@ -122,6 +123,11 @@ for (let i = keys.length; i--;) { } } +// Notify users about the prefix change and inform them they use legacy prefix for environment variables +if (Object.keys(process.env).toString().indexOf('HMD_') !== -1) { + logger.warn('Using legacy HMD prefix for environment variables. Please change your variables in future. For details see: https://github.com/hackmdio/codimd#environment-variables-will-overwrite-other-server-configs') +} + // Generate session secret if it stays on default values if (config.sessionSecret === 'secret') { logger.warn('Session secret not set. Using random generated one. Please set `sessionSecret` in your config.js file. All users will be logged out.') @@ -169,7 +175,7 @@ config.tmpPath = path.join(appRootPath, config.tmpPath) config.defaultNotePath = path.join(appRootPath, config.defaultNotePath) config.docsPath = path.join(appRootPath, config.docsPath) config.indexPath = path.join(appRootPath, config.indexPath) -config.hackmdPath = path.join(appRootPath, config.hackmdPath) +config.codimdPath = path.join(appRootPath, config.codimdPath) config.errorPath = path.join(appRootPath, config.errorPath) config.prettyPath = path.join(appRootPath, config.prettyPath) config.slidePath = path.join(appRootPath, config.slidePath) diff --git a/lib/csp.js b/lib/csp.js index d0f906a..a49c748 100644 --- a/lib/csp.js +++ b/lib/csp.js @@ -6,7 +6,7 @@ var CspStrategy = {} var defaultDirectives = { defaultSrc: ['\'self\''], scriptSrc: ['\'self\'', 'vimeo.com', 'https://gist.github.com', 'www.slideshare.net', 'https://query.yahooapis.com', '\'unsafe-eval\''], - // ^ TODO: Remove unsafe-eval - webpack script-loader issues https://github.com/hackmdio/hackmd/issues/594 + // ^ TODO: Remove unsafe-eval - webpack script-loader issues https://github.com/hackmdio/codimd/issues/594 imgSrc: ['*'], styleSrc: ['\'self\'', '\'unsafe-inline\'', 'https://assets-cdn.github.com'], // unsafe-inline is required for some libs, plus used in views fontSrc: ['\'self\'', 'https://public.slidesharecdn.com'], diff --git a/lib/models/note.js b/lib/models/note.js index 7d8e962..ec7e2b1 100644 --- a/lib/models/note.js +++ b/lib/models/note.js @@ -301,7 +301,7 @@ module.exports = function (sequelize, DataTypes) { return title || 'Untitled' }, generateWebTitle: function (title) { - title = !title || title === 'Untitled' ? 'HackMD - Collaborative markdown notes' : title + ' - HackMD' + title = !title || title === 'Untitled' ? 'CodiMD - Collaborative markdown notes' : title + ' - CodiMD' return title }, extractNoteTags: function (meta, $) { diff --git a/lib/response.js b/lib/response.js index d1e5e15..3a31c51 100644 --- a/lib/response.js +++ b/lib/response.js @@ -109,7 +109,7 @@ function showIndex (req, res, next) { } } -function responseHackMD (res, note) { +function responseCodiMD (res, note) { var body = note.content var extracted = models.Note.extractMeta(body) var meta = models.Note.parseMeta(extracted.meta) @@ -119,7 +119,7 @@ function responseHackMD (res, note) { 'Cache-Control': 'private', // only cache by client 'X-Robots-Tag': 'noindex, nofollow' // prevent crawling }) - res.render(config.hackmdPath, { + res.render(config.codimdPath, { url: config.serverURL, title: title, useCDN: config.useCDN, @@ -214,7 +214,7 @@ function showNote (req, res, next) { var noteId = req.params.noteId var id = models.Note.encodeNoteId(note.id) if ((note.alias && noteId !== note.alias) || (!note.alias && noteId !== id)) { return res.redirect(config.serverURL + '/' + (note.alias || id)) } - return responseHackMD(res, note) + return responseCodiMD(res, note) }) } @@ -527,7 +527,7 @@ function githubActionGist (req, res, note) { request({ url: gistUrl, headers: { - 'User-Agent': 'HackMD', + 'User-Agent': 'CodiMD', 'Authorization': 'token ' + accessToken }, method: 'POST', diff --git a/lib/web/middleware/codiMDVersion.js b/lib/web/middleware/codiMDVersion.js new file mode 100644 index 0000000..e777587 --- /dev/null +++ b/lib/web/middleware/codiMDVersion.js @@ -0,0 +1,10 @@ +'use strict' + +const config = require('../../config') + +module.exports = function (req, res, next) { + res.set({ + 'CodiMD-Version': config.version + }) + return next() +} diff --git a/lib/web/statusRouter.js b/lib/web/statusRouter.js index 4495a28..256fead 100644 --- a/lib/web/statusRouter.js +++ b/lib/web/statusRouter.js @@ -17,8 +17,7 @@ statusRouter.get('/status', function (req, res, next) { realtime.getStatus(function (data) { res.set({ 'Cache-Control': 'private', // only cache by client - 'X-Robots-Tag': 'noindex, nofollow', // prevent crawling - 'HackMD-Version': config.version + 'X-Robots-Tag': 'noindex, nofollow' // prevent crawling }) res.send(data) }) @@ -102,8 +101,7 @@ statusRouter.get('/config', function (req, res) { } res.set({ 'Cache-Control': 'private', // only cache by client - 'X-Robots-Tag': 'noindex, nofollow', // prevent crawling - 'HackMD-Version': config.version + 'X-Robots-Tag': 'noindex, nofollow' // prevent crawling }) res.render(config.constantsPath, data) }) diff --git a/package.json b/package.json index 20920e2..442d00a 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "hackmd", + "name": "CodiMD", "version": "1.1.1-ce", "description": "Realtime collaborative markdown notes on all platforms.", "main": "app.js", @@ -136,7 +136,7 @@ "engines": { "node": ">=6.x <10.x" }, - "bugs": "https://github.com/hackmdio/hackmd/issues", + "bugs": "https://github.com/hackmdio/codimd/issues", "keywords": [ "Collaborative", "Markdown", @@ -151,7 +151,7 @@ ], "repository": { "type": "git", - "url": "https://github.com/hackmdio/hackmd.git" + "url": "https://github.com/hackmdio/codimd.git" }, "devDependencies": { "babel-cli": "^6.18.0", diff --git a/public/hackmd-icon-1024.png b/public/codimd-icon-1024.png similarity index 100% rename from public/hackmd-icon-1024.png rename to public/codimd-icon-1024.png diff --git a/public/docs/features.md b/public/docs/features.md index dc6ddaf..f684ca6 100644 --- a/public/docs/features.md +++ b/public/docs/features.md @@ -3,12 +3,12 @@ Features Introduction === - **HackMD** is a realtime, multi-platform collaborative markdown note editor. + **CodiMD** is a real-time, multi-platform collaborative markdown note editor. This means that you can write notes with other people on your **desktop**, **tablet** or even on the **phone**. You can sign-in via multiple auth providers like **Facebook**, **Twitter**, **GitHub** and many more on the [_homepage_](/). -If you experience any _issues_, feel free to report it on [**GitHub**](https://github.com/hackmdio/hackmd/issues). -Or meet us on [**Matrix.org**](https://riot.im/app/#/room/#hackmd:matrix.org) or [**Gitter**](https://gitter.im/hackmdio/hackmd) for dev-talk and interactive help. +If you experience any _issues_, feel free to report it on [**GitHub**](https://github.com/hackmdio/codimd/issues). +Or meet us on [**Matrix.org**](https://riot.im/app/#/room/#codimd:matrix.org) or [**Gitter**](https://gitter.im/hackmdio/hackmd) for dev-talk and interactive help. **Thank you very much!** Workspace @@ -26,7 +26,7 @@ Workspace Edit: See only the editor. ## Night Mode: -When you are tired of a white screen and like a night mode, click on the little moon and turn on the night view of HackMD. +When you are tired of a white screen and like a night mode, click on the little moon and turn on the night view of CodiMD. The editor view, which is in night mode by default, can also be toggled between night and day view using the the little sun. diff --git a/public/docs/privacy.md.example b/public/docs/privacy.md.example index 08bf909..ff65d82 100644 --- a/public/docs/privacy.md.example +++ b/public/docs/privacy.md.example @@ -6,9 +6,9 @@ We process the following data, for the following purposes: |your data|our usage| |---------|---------| |IP-Address|Used to communicate with your browser and our servers. It's may exposed to third-parties which provide resources for this service. These services are, depending on your login method, the document you visit and the setup of this instance: Google, Disqus, MathJax, GitHub, SlideShare/LinkedIn, yahoo, Gravatar, Imgur, Amazon, and Cloudflare.| -|Usernames and profiles|Your username as well as user profiles that are connected with it are transmitted and stored by us to provide a useful login integration with services like GitHub, Facebook, Twitter, GitLab, Dropbox, Google. Depending on the setup of this HackMD instance there are maybe other third-parties involved using SAML, LDAP or the integration with a Mattermost instance.| -|Profile pictures| Your profile picture is either loaded from the service you used to login, the HackMD instance or Gravatar.| -|Uploaded pictures| Pictures that are uploaded for documents are either uploaded to Amazon S3, Imgur, a minio instance or the local filesystem of the HackMD server.| +|Usernames and profiles|Your username as well as user profiles that are connected with it are transmitted and stored by us to provide a useful login integration with services like GitHub, Facebook, Twitter, GitLab, Dropbox, Google. Depending on the setup of this CodiMD instance there are maybe other third-parties involved using SAML, LDAP or the integration with a Mattermost instance.| +|Profile pictures| Your profile picture is either loaded from the service you used to login, the CodiMD instance or Gravatar.| +|Uploaded pictures| Pictures that are uploaded for documents are either uploaded to Amazon S3, Imgur, a minio instance or the local filesystem of the CodiMD server.| All account data and notes are stored in a mysql/postgres/sqlite database. Besides the user accounts and the document themselves also relationships between the documents and the user accounts are stored. This includes ownership, authorship and revisions of all changes made during the creation of a note. diff --git a/public/docs/yaml-metadata.md b/public/docs/yaml-metadata.md index d49418f..888345f 100644 --- a/public/docs/yaml-metadata.md +++ b/public/docs/yaml-metadata.md @@ -96,7 +96,7 @@ dir: rtl breaks --- This option means the hardbreaks in the note will be parsed or be ignore. -The original markdown syntax breaks only if you put space twice, but HackMD choose to breaks every time you enter a break. +The original markdown syntax breaks only if you put space twice, but CodiMD choose to breaks every time you enter a break. You can only use whether `true` or `false`. > default: not set (which will be true) @@ -125,7 +125,7 @@ This option allow you to enable Disqus with your shortname. **Example** ```xml -disqus: hackmd +disqus: codimd ``` slideOptions @@ -146,4 +146,4 @@ https://github.com/hakimel/reveal.js/tree/master/css/theme slideOptions: transition: fade theme: white -``` \ No newline at end of file +``` diff --git a/public/js/cover.js b/public/js/cover.js index 6ca05f6..79fb3a2 100644 --- a/public/js/cover.js +++ b/public/js/cover.js @@ -318,7 +318,7 @@ $('.ui-save-history').click(() => { const blob = new Blob([history], { type: 'application/json;charset=utf-8' }) - saveAs(blob, `hackmd_history_${moment().format('YYYYMMDDHHmmss')}`, true) + saveAs(blob, `codimd_history_${moment().format('YYYYMMDDHHmmss')}`, true) }) }) diff --git a/public/js/extra.js b/public/js/extra.js index dbb0f45..d6bbb0c 100644 --- a/public/js/extra.js +++ b/public/js/extra.js @@ -105,9 +105,9 @@ function getTitle (view) { export function renderTitle (view) { let title = getTitle(view) if (title) { - title += ' - HackMD' + title += ' - CodiMD' } else { - title = 'HackMD - Collaborative markdown notes' + title = 'CodiMD - Collaborative markdown notes' } return title } diff --git a/public/views/codimd.ejs b/public/views/codimd.ejs new file mode 100644 index 0000000..7818346 --- /dev/null +++ b/public/views/codimd.ejs @@ -0,0 +1,15 @@ + + + + + <%- include codimd/head %> + + + + <%- include codimd/header %> + <%- include codimd/body %> + <%- include codimd/footer %> + <%- include codimd/foot %> + + + diff --git a/public/views/hackmd/body.ejs b/public/views/codimd/body.ejs similarity index 100% rename from public/views/hackmd/body.ejs rename to public/views/codimd/body.ejs diff --git a/public/views/hackmd/foot.ejs b/public/views/codimd/foot.ejs similarity index 100% rename from public/views/hackmd/foot.ejs rename to public/views/codimd/foot.ejs diff --git a/public/views/hackmd/footer.ejs b/public/views/codimd/footer.ejs similarity index 100% rename from public/views/hackmd/footer.ejs rename to public/views/codimd/footer.ejs diff --git a/public/views/hackmd/head.ejs b/public/views/codimd/head.ejs similarity index 100% rename from public/views/hackmd/head.ejs rename to public/views/codimd/head.ejs diff --git a/public/views/hackmd/header.ejs b/public/views/codimd/header.ejs similarity index 99% rename from public/views/hackmd/header.ejs rename to public/views/codimd/header.ejs index 21b632c..8fc050b 100644 --- a/public/views/hackmd/header.ejs +++ b/public/views/codimd/header.ejs @@ -13,7 +13,7 @@ - HackMD + CodiMD