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
[](https://gitter.im/grumpy-devel/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
5
5
6
6
## Overview
@@ -56,14 +56,34 @@ There are three basic categories of incomplete functionality:
56
56
57
57
## Running Grumpy Programs
58
58
59
+
### Pre-requisites
60
+
61
+
The commands ahead assumes that you have Golang installed and a recent
62
+
version of Python 2, `setuptools` and `pip`.
63
+
64
+
### Method 1: binary package
65
+
66
+
For convenience, a Python package is provided from the PyPI. During install,
67
+
many Grumpy will be compiled and stored inside your Python installation.
68
+
69
+
You need Golang preinstalled anyway for the installation to be successful.
70
+
71
+
```
72
+
pip2 install -U grumpy-runtime -I --no-cache
73
+
(wait about 5 minutes)
74
+
echo "print 'hello, world'" | grumpy run
75
+
```
76
+
59
77
### Method 1: make run:
60
78
61
79
The simplest way to execute a Grumpy program is to use `make run`, which wraps a
62
80
shell script called grumprun that takes Python code on stdin and builds and runs
63
-
the code under Grumpy. All of the commands below are assumed to be run from the
64
-
root directory of the Grumpy source code distribution:
81
+
the code under Grumpy:
65
82
66
83
```
84
+
cd grumpy-tools-src
85
+
python2 setup.py develop
86
+
cd ../grumpy-runtime-src
67
87
echo "print 'hello, world'" | make run
68
88
```
69
89
@@ -81,6 +101,9 @@ The first step is to set up the shell so that the Grumpy toolchain and libraries
81
101
can be found. From the root directory of the Grumpy source distribution run:
82
102
83
103
```
104
+
cd grumpy-tools-src
105
+
python2 setup.py develop
106
+
cd ../grumpy-runtime-src
84
107
make
85
108
export PATH=$PWD/build/bin:$PATH
86
109
export GOPATH=$PWD/build
@@ -91,18 +114,21 @@ You will know things are working if you see the expected output from this
91
114
command:
92
115
93
116
```
117
+
cd grumpy-runtime-src
94
118
echo 'import sys; print sys.version' | grumprun
95
119
```
96
120
97
121
Next, we will write our simple Python module into the \_\_python\_\_ directory:
0 commit comments