Skip to content
Branch: master
Find file Copy path
Find file Copy path
2 contributors

Users who have contributed to this file

@fxha @Jocs
138 lines (87 sloc) 4.6 KB

Mark Text Contributing Guide

Hi, I'm really excited that you are interested in contributing to Mark Text 🎉. Before submitting your contribution though, please make sure to take a moment and read through the following guidelines.

Issue Reporting Guidelines

Please search for similar issues before opening an issue and always follow the issue template. Please provide a detailed description of the problem in your PR and live demo or screenshots are preferred.

Pull Request Guidelines

  • Submit PRs directly to the master branch.

  • Work in the src folder and DO NOT checkin dist in commits.

  • If you adding new feature:

    • Open a suggestion issue first.
    • Provide convincing reason to add this feature.
    • Then submit your PR.
  • If fixing a bug:

    • If you are resolving a special issue, add fix: #xxx[,#xxx] (#xxx is the issue id) in your PR title for a better release log, e.g.fix: #3899 update entities encoding/decoding.
    • Update .github/ for notable changes - like bug fixes and features.
    • Provide detailed description of the bug in your PR and/or link to the issue. You can also include screenshots.
  • Please lint and test your PR before submitting.

  • All PRs need to pass the Travis CI before merged. If it fails, please try to solve the issue(s) and feel free to ask for any help.

Where should I start?

Find a issue flagged as a bug, help wanted or enhancement . The good first issue issues are good for new comers. Discuss the solution in the issue and after the final solution is approved by the Mark Text members, you can submit/work on the PR. For small fixes, you can directly open a PR.

Other ways to help:

  • Documentation (*1)
  • Translation (*1)
  • Help to answer more detail issues or discuss changes and features.
  • Report bugs and feature ideas.

*1: More or less blocked until v1.0 release because of early development phase.

Quick Start

  1. Fork the repository.
  2. Clone your fork: git clone<username>/marktext.git
  3. Create a feature branch: git checkout -b feature
  4. Make you changes and push your branch.
  5. Create a PR against master and describe your changes.

Rebase your PR:

If there are conflicts or you want to update your local branch, please do the following:

  1. git fetch upstream
  2. git rebase upstream/master
  3. Please resolve all conflicts and force push your feature branch: git push -f

Build Instructions


Before you can get started developing, you need set up your build envoriment:

  • git
  • Node.js >=v8.12.0, npm and yarn
  • C++ compiler and development tools

Additional development dependencies on Linux:

  • libx11 (dev)
  • libxkbfile (dev)

On Debian-based Linux: sudo apt-get install libx11-dev libxkbfile-dev
On Red Hat-based Linux: sudo dnf install libx11-devel libxkbfile-devel

Let's build:

  1. Go to marktext folder
  2. Install dependencies: yarn install or yarn install --frozen-lockfile
  3. Build Mark Text: npm run build
  4. Mark Text binary is located under build folder

Copy the build app to applications folder, or if on Windows run the executable installer.

Important scripts:

$ npm run <script> # or yarn run <script>
Script Description
build Build Mark Text binaries for your OS
dev Build and run Mark Text in developer mode
lint Lint code style
test / unit Run unit tests

For more scripts please see package.json.

Style guide

  • ES6 and "best practices"
  • 2 space indent
  • JSDoc for documentation

Project Structure

  • root: Configuration files

  • package.json: Project settings

  • build: Contains generated binaries

  • dist: Build files for deployment

  • doc: Documentation and assets

  • node_modules: Dependencies

  • src: Mark Text source code

    • TBD
  • static: Application assets (images, themes, etc)

  • test: Contains (unit) tests

You can’t perform that action at this time.