Skip to content

Contributing

matason edited this page Jul 25, 2025 · 3 revisions

Contributing to ce-dev

We welcome contributions to ce-dev! Please feel free to fork the repository, open issues and pull requests.

Thank you!

Contributing code

If you'd like to contribute code to ce-dev, here are the steps that will enable you to check out the code and work on it.

Fork the ce-dev repository

Visit https://github.com/codeenigma/ce-dev/fork to fork the repository to your GitHub account.

Checkout your fork

Change to the directory where you do your development work, run the following on the command line, replacing your-github-username appropriately:

git clone [email protected]:your-github-username/ce-dev.git

Add the Code Enigma repository as the upstream remote

cd ce-dev && git remote add upstream [email protected]:codeenigma/ce-dev.git

At this point, the output of git remote -v should look something like this:

origin  [email protected]:your-github-username/ce-dev.git (fetch)
origin  [email protected]:your-github-username/ce-dev.git (push)
upstream        [email protected]:codeenigma/ce-dev.git (fetch)
upstream        [email protected]:codeenigma/ce-dev.git (push)

Create a branch

Create a branch off the default branch. At the time of writing, this is 2.x:

git fetch --all
git checkout 2.x
git pull upstream 2.x
git checkout -b your-branch

Making your changes and testing them

ce-dev is written in TypeScript, which is compiled to JavaScript... if you haven't already, install the required dependencies by running:

npm install

You will most likely be making changes to the TypeScript files located in the src directory. When you want to test your changes, run the following on the command line:

npm run build

You will also need to make the bin/run.js file executable with:

chmod u+x bin/run.js

Then you should be able to run:

/path/where/you/develop/ce-dev/bin/run.js

This will list all the available ce-dev commands.

Commit your changes, open a pull request

Commit your changes and push your branch to your repository with:

git push origin your-branch

Lastly, browse to https://github.com/codeenigma/ce-dev/compare to open a pull request.

Notes for the 1.x branch

If you're using ce-dev 1.x, the steps to compile the code are slightly different than on the 2.x branch. Also, if you're switching from the 2.x branch to work on the 1.x branch, it is advisable to remove the node_modules directory.

If you don't have the 1.x branch, then run the following:

git checkout -b 1.x upstream/1.x

Remove the node_modules directory and install the dependencies:

rm -rf node_modules
npm install

Finally, compile:

npm run prepack

You should now be able to make the run file executable and run ce-dev with the following:

chmod u+x bin/run
/path/where/you/develop/ce-dev/bin/run
Clone this wiki locally