You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jun 7, 2023. It is now read-only.
Packaging of the Runestone components for publishing educational materials using Sphinx and restructuredText. Check out the `Overview <http://interactivepython.org/runestone/static/overview/overview.html>`_ To see all of the extensions in action.
5
9
**NOTE** -- If you have used an older version of this repo, please know this is a total restart. I think much better, and it WILL stay up to date as this is now the master copy of the components not just a copy.
6
10
Check out the `Development Roadmap <https://github.com/bnmnetp/runestone/wiki>`_ to get an understanding of our migration towards webcomponents.
@@ -17,6 +21,13 @@ If you are completely new to pip and github text editors, I have written a more
17
21
18
22
pip install runestone
19
23
24
+
On some versions of pip that will fail and you need to use:
25
+
26
+
::
27
+
28
+
pip install --pre runestone
29
+
30
+
20
31
21
32
Or, if you prefer to live on the development edge, you can check out the very latest from:
22
33
@@ -59,6 +70,20 @@ installation every so often. If you are new to using Python on windows I recomm
59
70
link on `Using Python with Windows <https://docs.python.org/3.4/using/windows.html>`_
60
71
61
72
73
+
Developing and Hacking
74
+
----------------------
75
+
76
+
So, you would like to help out with developing the Runestone Components. What do you need to know?
77
+
78
+
1. Make a Fork of this repository.
79
+
2. Setup your environment on your development machine
80
+
81
+
1. Make a virtual environment for testing and working I recommend pyvenv-3.4 as it is baked in to Python 3.4 and higher.
82
+
2. Rather than following the instructions above for installing runestone simply run ``pip install .`` from the top level runestone directory. This will install all of the required prerequisites and setup the runestone install as a link to the development directory.
83
+
84
+
3. When you have some changes to share, make a Pull Request.
85
+
86
+
62
87
Notes for more Advanced Users
63
88
-----------------------------
64
89
@@ -69,4 +94,4 @@ If you already have an existing `Sphinx <http://sphinx-doc.org>`_ project and y
69
94
* Then modify your html_static_path: ``html_static_path = ['_static'] + runestone_static_dirs()`` Again you may have your own set of static paths in the initial list.
70
95
71
96
72
-
See https://github.com/bnmnetp/runestone/wiki/DevelopmentRoadmap to get a sense for how this is all going to come together.
97
+
See https://github.com/bnmnetp/runestone/wiki/DevelopmentRoadmap to get a sense for how this is all going to come together.
The body of the ``pre`` tag contains code to be loaded into the editor initially. The following attributes are options and control what pieces and parts of the component will be visible.
13
+
14
+
*``data-component`` attribute identifies this as an activecode component
15
+
*``class`` The usual CSS class options
16
+
*``id`` must be unique in the document
17
+
*``data-lang`` for activecode can be python javascript or html
18
+
*``data-autorun`` run this activecode as soon as the page is loaded
19
+
*``data-hidecode`` make the editor hidden initially
20
+
*``data-include`` list of ids of other activecodes. The code form each will be prepended to the code to run
21
+
*``data-timelimit`` either False to turn off runtime limit checking or an integer representing the number of milliseconds until timeout.
22
+
*``data-coach`` add a button to display code coach information
23
+
*``data-codelens`` add a button "Run this in Codelens"
24
+
25
+
26
+
For Python to work in the browser you must also obtain and include via a script tag ``skulpt.min.js`` and
27
+
``skulpt-stdlib.js`` along with ``codemirror.js`` and of course ``activecode.js``
28
+
29
+
Soon, many of these requirements will be incorporated into one handy ``runestone.js`` file.
0 commit comments