This is the contribute.md of our project. Great to have you here. Here are a few ways you can help make this project better!
The list of people who have contributed to Skulpt is too big and dynamic to be accurate in a document like this. Luckily Github does an excellent job of keeping track of people who have contributed
Brad Miller is the current owner of the project. But see below for the full list of people with commit privileges.
This section includes ways to get started with your open source project. Include links to documentation and to different communication channels:
This section includes advice on how to build new features for the project & what kind of process it includes.
git checkout -b feature_branch_name
./test/unit_tmpl.py
to ./test/unit
and give it a descriptive name. Make sure the functions in
your test class start with test
. Here is some documentation on the unittest module (not everything is
implemented in skulpt)../skulpt test
and ./skulpt dist
this checks that there are no regressions.git push -u origin feature_branch_name
. And create a Pull Request on github.rebase
to base your commits off the new master
. With a command
that looks like git rebase upstream/master
. Make sure you do a force push to your branch git push --force
because you've rewritten history, and all
your commits will appear in two fold if you don'tWe try to get to pull requests in a very timely way so they don't languish. Nothing is more frustrating than a project that just leaves pull requests sitting there for ages. Usually we get to them in a one or two days.
git checkout -b feature_branch_name
git commit -m 'failing test'
(you can do this more often)./skulpt.py test
and ./skulpt.py dist
git commit -m 'implement fix'
(you can do this more often)git push -u origin feature_branch_name
Here are some coding conventions to keep in mind:
Sk.ffi.remapToJs
and Sk.ffi.remapToPy
are your friends. They take care of the details
of going from a Python type to a Javascript type and vice versa. They are smart enough to work
with common types and even work well recursively converting containers. Sk.ffi.remapToJs
is
definitely preferred over foo.v
pyCheckArgs
function at the beginning of anything that will be exposed to a Python programmer.Sk.builtin.null.null$
for functions and methds that should return None
foo.js
or foo.py
__init__.js
or __init__.py
file, and possibly additional modules.In summer of 2014, we adopted the following style and conventions for our code:
'use strict';
we should add that to the compiler['{a}']
use dot notation where possible.There may very well be things I have not covered in this list, but those will be quickly revealed to you by the jshint program.
Our Travis script will run jshint over all the source. You should run jshint as well.
Many editors and IDEs do this automatically for you -- Atom, PyCharm, TextMate has a
nice plugin called JSLintMate. You can easily install jshint using the npm
package manager that comes with node.
The committers are people who are responsible for reviewing and approving pull requests . These are generally people who have been around the project for a while and have "proven" themselves by contributing good code and ideas to the Skulpt. This list may change over time as people gain or lose interest in Skulpt. If you would like to volunteer contact Brad.
Although a lot of our testing, and checking for adherence to the style guidelines is done automatically the review process I would recommend for committers is as follows:
The current group of committers is as follows:
If documentation is your thing, have we got a job for you. There are a few blog posts on how to write modules and work with skulpt but very little of the core is documented beyond the source. Having some good documentation for developers would really help get more people involved.
This section includes ideas on how non-developers can help with the project. Here's a few examples:
You can help write blog posts about the project
Create an example of the project in real world by building something or showing what others have built.
Write about other people’s projects based on this project. Show how it’s used in daily life. Take screenshots and make videos!