2013-12-04 07:46:41 -08:00
<!DOCTYPE html>
< html >
< head >
< meta http-equiv = "Content-type" content = "text/html;charset=UTF-8" / >
2015-11-09 08:01:19 -08:00
< title > Contributing – Wren< / title >
2020-06-05 22:25:23 +00:00
< script type = "application/javascript" src = "prism.js" data-manual > < / script >
< script type = "application/javascript" src = "codejar.js" > < / script >
< script type = "application/javascript" src = "wren.js" > < / script >
< link rel = "stylesheet" type = "text/css" href = "prism.css" / >
2013-12-04 07:46:41 -08:00
< link rel = "stylesheet" type = "text/css" href = "style.css" / >
2015-01-15 21:18:18 -08:00
< link href = '//fonts.googleapis.com/css?family=Source+Sans+Pro:400,700,400italic,700italic|Source+Code+Pro:400|Lato:400|Sanchez:400italic,400' rel = 'stylesheet' type = 'text/css' >
2014-04-11 10:44:33 -07:00
<!-- Tell mobile browsers we're optimized for them and they don't need to crop
the viewport. -->
< meta name = "viewport" content = "width=device-width, initial-scale=1, maximum-scale=1" / >
2013-12-04 07:46:41 -08:00
< / head >
< body id = "top" >
2014-04-14 21:23:46 -07:00
< header >
< div class = "page" >
2014-04-20 21:42:17 -07:00
< div class = "main-column" >
2015-01-18 15:37:50 -08:00
< h1 > < a href = "./" > wren< / a > < / h1 >
2020-06-05 22:25:23 +00:00
< h2 > a classy little scripting language< / h2 >
2014-04-14 21:23:46 -07:00
< / div >
< / div >
2014-08-19 07:35:20 -07:00
< / header >
2014-04-14 21:23:46 -07:00
< div class = "page" >
2015-11-09 08:01:19 -08:00
< nav class = "big" >
2019-02-06 02:52:27 +00:00
< a href = "./" > < img src = "./wren.svg" class = "logo" > < / a >
2013-12-04 07:46:41 -08:00
< ul >
2014-04-09 07:53:30 -07:00
< li > < a href = "getting-started.html" > Getting Started< / a > < / li >
2015-11-09 08:01:19 -08:00
< li > < a href = "contributing.html" > Contributing< / a > < / li >
2019-02-06 02:52:27 +00:00
< li > < a href = "blog" > Blog< / a > < / li >
2020-06-05 22:25:23 +00:00
< li > < a href = "try" > Try it!< / a > < / li >
2013-12-04 07:46:41 -08:00
< / ul >
2014-08-19 07:35:20 -07:00
< section >
2019-02-06 02:52:27 +00:00
< h2 > guides< / h2 >
2014-08-19 07:35:20 -07:00
< ul >
< li > < a href = "syntax.html" > Syntax< / a > < / li >
< li > < a href = "values.html" > Values< / a > < / li >
< li > < a href = "lists.html" > Lists< / a > < / li >
< li > < a href = "maps.html" > Maps< / a > < / li >
2015-11-09 08:01:19 -08:00
< li > < a href = "method-calls.html" > Method Calls< / a > < / li >
< li > < a href = "control-flow.html" > Control Flow< / a > < / li >
< li > < a href = "variables.html" > Variables< / a > < / li >
< li > < a href = "classes.html" > Classes< / a > < / li >
2021-04-08 04:25:47 +00:00
< li > < a href = "functions.html" > Functions< / a > < / li >
2015-11-09 08:01:19 -08:00
< li > < a href = "concurrency.html" > Concurrency< / a > < / li >
< li > < a href = "error-handling.html" > Error Handling< / a > < / li >
< li > < a href = "modularity.html" > Modularity< / a > < / li >
2014-08-19 07:35:20 -07:00
< / ul >
< / section >
< section >
2020-06-05 22:25:23 +00:00
< h2 > API docs< / h2 >
2014-08-19 07:35:20 -07:00
< ul >
2015-11-09 08:01:19 -08:00
< li > < a href = "modules" > Modules< / a > < / li >
2020-06-05 22:25:23 +00:00
< / ul >
< / section >
< section >
< h2 > reference< / h2 >
< ul >
< li > < a href = "cli" > Wren CLI< / a > < / li >
2017-10-19 07:05:45 -07:00
< li > < a href = "embedding" > Embedding< / a > < / li >
2014-08-19 07:35:20 -07:00
< li > < a href = "performance.html" > Performance< / a > < / li >
< li > < a href = "qa.html" > Q & A< / a > < / li >
< / ul >
< / section >
2014-04-11 10:44:33 -07:00
< / nav >
2015-11-09 08:01:19 -08:00
< nav class = "small" >
< table >
< tr >
2019-10-03 06:50:59 +00:00
< div > < a href = "getting-started.html" > Getting Started< / a > < / div >
< div > < a href = "contributing.html" > Contributing< / a > < / div >
< div > < a href = "blog" > Blog< / a > < / div >
2020-06-05 22:25:23 +00:00
< div > < a href = "try" > Try it!< / a > < / div >
2015-11-09 08:01:19 -08:00
< / tr >
< tr >
2019-02-06 02:52:27 +00:00
< td colspan = "2" > < h2 > guides< / h2 > < / td >
2015-11-09 08:01:19 -08:00
< td > < h2 > reference< / h2 > < / td >
< / tr >
< tr >
< td >
< ul >
< li > < a href = "syntax.html" > Syntax< / a > < / li >
< li > < a href = "values.html" > Values< / a > < / li >
< li > < a href = "lists.html" > Lists< / a > < / li >
< li > < a href = "maps.html" > Maps< / a > < / li >
< li > < a href = "method-calls.html" > Method Calls< / a > < / li >
< li > < a href = "control-flow.html" > Control Flow< / a > < / li >
< / ul >
< / td >
< td >
< ul >
< li > < a href = "variables.html" > Variables< / a > < / li >
< li > < a href = "classes.html" > Classes< / a > < / li >
2021-04-08 04:25:47 +00:00
< li > < a href = "functions.html" > Functions< / a > < / li >
2015-11-09 08:01:19 -08:00
< li > < a href = "concurrency.html" > Concurrency< / a > < / li >
< li > < a href = "error-handling.html" > Error Handling< / a > < / li >
< li > < a href = "modularity.html" > Modularity< / a > < / li >
< / ul >
< / td >
< td >
< ul >
2020-06-05 22:25:23 +00:00
< li > < a href = "modules" > API/Modules< / a > < / li >
2017-10-19 07:05:45 -07:00
< li > < a href = "embedding" > Embedding< / a > < / li >
2015-11-09 08:01:19 -08:00
< li > < a href = "performance.html" > Performance< / a > < / li >
< li > < a href = "qa.html" > Q & A< / a > < / li >
< / ul >
< / td >
< / tr >
< / table >
< / nav >
2014-04-20 21:42:17 -07:00
< main >
2019-02-06 02:52:27 +00:00
< h2 > Contributing< / h2 >
2020-06-05 22:25:23 +00:00
< p > Like the bird, Wren’ s ecosystem is small but full of life. Almost everything is
under active development and there’ s lots to do. We’ d be delighted to have you
help.< / p >
< p > The first thing to do is to join < a href = "https://discord.gg/Kx6PxSX" > the discord community< / a > (or < a href = "https://groups.google.com/forum/#!forum/wren-lang" > the mailing list< / a > ) and say,
“ Hi” . There are no strangers to Wren, just friends we haven’ t met yet.< / p >
2016-01-24 15:41:12 -08:00
< h2 > Growing the ecosystem < a href = "#growing-the-ecosystem" name = "growing-the-ecosystem" class = "header-anchor" > #< / a > < / h2 >
2020-06-05 22:25:23 +00:00
< p > The simplest and often most helpful way to join the Wren party is to be a Wren
< em > user< / em > . Create an application that embeds Wren. Write a library or a handy
utility in Wren. Add syntax highlighting support for Wren to your favorite text
editor. Share that stuff and it will help the next Wren user to come along.< / p >
< p > If you do any of the above, let us know by adding it to < a href = "https://github.com/wren-lang/wren/wiki" > the wiki< / a > . < br / >
We like to keep track of:< / p >
2016-01-24 15:41:12 -08:00
< ul >
2020-06-05 22:25:23 +00:00
< li > < a href = "https://github.com/wren-lang/wren/wiki/Applications" > Applications< / a > that host Wren as a scripting language.< / li >
< li > < a href = "https://github.com/wren-lang/wren/wiki/Modules" > Modules< / a > written in Wren that others can use.< / li >
< li > < a href = "https://github.com/wren-lang/wren/wiki/Language-Bindings" > Language bindings< / a > that let you interact with Wren from other
languages.< / li >
< li > < a href = "https://github.com/wren-lang/wren/wiki/Tools" > Tools and utilities< / a > that make it easier to be a Wren programmer.< / li >
2016-01-24 15:41:12 -08:00
< / ul >
< h2 > Contributing to Wren < a href = "#contributing-to-wren" name = "contributing-to-wren" class = "header-anchor" > #< / a > < / h2 >
2020-06-05 22:25:23 +00:00
< p > You’ re also more than welcome to contribute to Wren itself, both the core VM and
the command-line interpreter. The source is developed < a href = "https://github.com/wren-lang/" > on GitHub< / a > . Our
2020-06-12 17:15:45 +00:00
hope is that the codebase, tests, and < a href = "https://github.com/wren-lang/wren/tree/main/doc/site" > documentation< / a > are easy to
2020-06-05 22:25:23 +00:00
understand and contribute to. If they aren’ t, that’ s a bug.< / p >
< p > You can learn how to build wren on the < a href = "getting-started.html#building-wren" > getting started page< / a > .< / p >
2016-01-24 15:41:12 -08:00
< h3 > Finding something to hack on < a href = "#finding-something-to-hack-on" name = "finding-something-to-hack-on" class = "header-anchor" > #< / a > < / h3 >
2020-06-05 22:25:23 +00:00
< p > Between the < a href = "https://github.com/wren-lang/wren/issues" > issue tracker< / a > and searching for < code > TODO< / code > comments in the
code, it’ s pretty easy to find something that needs doing, though we don’ t
always do a good job of writing everything down.< / p >
< p > If nothing there suits your fancy, new ideas are welcome as well! If you have an
idea for a significant change or addition, please file a < a href = "https://github.com/wren-lang/wren/labels/proposal" > proposal< / a > to discuss
it before writing lots of code. Wren tries very < em > very< / em > hard to be minimal which
means often having to say “ no” to language additions, even really cool ones.< / p >
2016-01-24 15:41:12 -08:00
< h3 > Hacking on docs < a href = "#hacking-on-docs" name = "hacking-on-docs" class = "header-anchor" > #< / a > < / h3 >
2020-06-05 22:25:23 +00:00
< p > The < a href = "/" > documentation< / a > is one of the easiest— and most
important!— parts of Wren to contribute to. The source for the site is
written in < a href = "http://daringfireball.net/projects/markdown/" > Markdown< / a > and lives under < code > doc/site< / code > . A
simple Python 3 script, < code > util/generate_docs.py< / code > , converts that to HTML and CSS.< / p >
< pre > < code > $ python util/generate_docs.py
< / code > < / pre >
< p > This generates the site in < code > build/docs/< / code > . You can run any simple static web
server from there. Python includes one:< / p >
< pre > < code > $ cd build/docs
$ python -m http.server
< / code > < / pre >
< p > Running that script every time you change a line of Markdown can be slow,
so there is also a file watching version that will automatically regenerate the
docs when you edit a file:< / p >
< pre > < code > $ python util/generate_docs.py --watch
< / code > < / pre >
2016-01-24 15:41:12 -08:00
< h3 > Hacking on the VM < a href = "#hacking-on-the-vm" name = "hacking-on-the-vm" class = "header-anchor" > #< / a > < / h3 >
2020-06-05 22:25:23 +00:00
< p > The basic process is simple:< / p >
2015-01-04 13:36:51 -08:00
< ol >
< li >
2020-06-05 22:25:23 +00:00
< p > < strong > Make sure you can build and run the tests locally.< / strong > It’ s good to ensure
you’ re starting from a happy place before you poke at the code. Running the
tests is as simple as < a href = "getting-started.html#building-wren" > building the vm project< / a > ,
which generates < code > bin/wren_test< / code > and then running the following python 3 script:< / p >
< pre > < code > $ python util/test.py
< / code > < / pre >
< p > If there are no failures, you’ re good to go.< / p >
2015-01-04 13:36:51 -08:00
< / li >
< li >
2020-06-05 22:25:23 +00:00
< p > < strong > < a href = "https://help.github.com/articles/fork-a-repo/" > Fork the repo< / a > so you can change it locally.< / strong > Please make your
2021-04-08 03:58:33 +00:00
changes in separate < a href = "https://www.atlassian.com/git/tutorials/comparing-workflows/centralized-workflow" > feature branches< / a > to make things a little easier.< / p >
2015-01-04 13:36:51 -08:00
< / li >
< li >
2020-06-05 22:25:23 +00:00
< p > < strong > Change the code.< / strong > Please follow the style of the surrounding code. That
basically means < code > camelCase< / code > names, < code > {< / code > on the next line, keep within 80
columns, and two spaces of indentation. If you see places where the existing
code is inconsistent, let us know.< / p >
2015-01-04 13:36:51 -08:00
< / li >
< li >
2020-06-05 22:25:23 +00:00
< p > < strong > Write some tests for your new functionality.< / strong > They live under < code > test/< / code > .
Take a look at some existing tests to get an idea of how to define
expectations.< / p >
2015-01-04 13:36:51 -08:00
< / li >
< li >
2020-06-05 22:25:23 +00:00
< p > < strong > Make sure the tests all pass, both the old ones and your new ones.< / strong > < / p >
2015-01-04 13:36:51 -08:00
< / li >
< li >
2020-06-12 17:15:45 +00:00
< p > < strong > Add your name and email to the < a href = "https://github.com/wren-lang/wren/tree/main/AUTHORS" > AUTHORS< / a > file if you haven’ t already.< / strong > < / p >
2015-01-04 13:36:51 -08:00
< / li >
< li >
2020-06-05 22:25:23 +00:00
< p > < strong > Send a < a href = "https://github.com/wren-lang/wren/pulls" > pull request< / a > .< / strong > Pat yourself on the back for contributing to a
2021-04-08 03:58:33 +00:00
fun open source project! < / p >
2015-01-04 13:36:51 -08:00
< / li >
< / ol >
2016-01-24 15:41:12 -08:00
< h2 > Getting help < a href = "#getting-help" name = "getting-help" class = "header-anchor" > #< / a > < / h2 >
2020-06-05 22:25:23 +00:00
< p > If at any point you have questions, feel free to < a href = "https://github.com/wren-lang/wren/issues" > file an issue< / a > or ask
on the < a href = "https://discord.gg/Kx6PxSX" > discord community< / a > (or the < a href = "https://groups.google.com/forum/#!forum/wren-lang" > mailing list< / a > ). If you’ re a Redditor, try the
< a href = "https://www.reddit.com/r/wren_lang/" > /r/wren_lang< / a > subreddit. You can also email me directly (< code > robert< / code > at
< code > stuffwithstuff.com< / code > ) if you want something less public.< / p >
2014-04-11 10:44:33 -07:00
< / main >
2014-04-14 21:23:46 -07:00
< / div >
< footer >
< div class = "page" >
2014-08-19 07:35:20 -07:00
< div class = "main-column" >
2015-11-09 08:01:19 -08:00
< p > Wren lives
2019-02-06 02:52:27 +00:00
< a href = "https://github.com/wren-lang/wren" > on GitHub< / a >
2015-11-09 08:01:19 -08:00
— Made with ❤ by
< a href = "http://journal.stuffwithstuff.com/" > Bob Nystrom< / a > and
2020-06-12 17:15:45 +00:00
< a href = "https://github.com/wren-lang/wren/blob/main/AUTHORS" > friends< / a > .
2015-11-09 08:01:19 -08:00
< / p >
2014-08-19 07:35:20 -07:00
< div class = "main-column" >
2014-04-14 21:23:46 -07:00
< / div >
< / footer >
2013-12-04 07:46:41 -08:00
< / body >
2015-04-25 08:50:08 -07:00
< / html >