<commit_before>@page SettingUp Setting Up DoneJS
@parent DoneJS
@hide sidebar
@outline 2 ol
@description This page contains information on setting up DoneJS. It will walk you through getting prerequisites needed before you ever install DoneJS and includes platform-specific pieces of information not covered in the Quick Start or In Depth guides.

@body

## Windows

### Prerequisites

This will help you get set up with DoneJS on Windows. To use DoneJS you need a C++ compiler (for native dependencies). First you need a recent version of [Node.js](https://nodejs.org/en/). DoneJS officially supports Node 0.10.x, 0.12.x, and IOjs, but more recent versions will likely work as well.

#### Package Management

In this guide we'll use [chocolatey](https://chocolatey.org/) to install packages needed. You don't have to use chocolatey if you don't want, and can instead search for the dependencies and install them with a Windows installer, but we'll use chocolately because it makes things a bit easier.

After you've installed chocolatey by following the instructions [on the homepage](https://chocolatey.org/) **open an administrative console** and proceed to the next step.

#### Python 2.x

Native dependencies in Node.js are installed with [node-gyp](https://github.com/nodejs/node-gyp) which uses Python as a build tool. It expects Python 2.x:

```shell
choco install python2 -y
```

#### Windows SDK

Next we need the Windows SDK. We're going to assume Windows 7, but adjust this command to the version of Windows you use:

```shell
choco install windows-sdk-7.1 -y
```

#### Visual Studio Express

Installing Visual Studio Express gives us the C++ compiler we need:

```shell
choco install visualstudioexpress2013windowsdesktop -y
```

### Environmental Variables

In order to switch to production mode you need to set the environmental variable `NODE_ENV`. Depending on which console you use this can be done in one of two ways:

**Command Prompt**

```
set NODE_ENV=production
```

**Powershell**

```
$env:NODE_ENV="production"
```

## Debian / Ubuntu

Installing in a Debian / Ubuntu environment takes a little extra work because the version of Node shipped is older than what is supported by DoneJS (and most other Node-based software).

### Prerequisites

Instead of installing Node.js from the repository we recommend using a PPA (a repostiroy maintained by a 3rd party). First get a copy of `curl` if you don't already have it:

```
sudo apt-get install curl
```

Then add the PPA to your source list:
<commit_msg>Setting up: add note about osx<commit_after>@page SettingUp Setting Up DoneJS
@parent DoneJS
@hide sidebar
@outline 2 ol
@description This page contains information on setting up DoneJS. It will walk you through getting prerequisites needed before you ever install DoneJS and includes platform-specific pieces of information not covered in the Quick Start or In Depth guides.

@body

## Windows

### Prerequisites

This will help you get set up with DoneJS on Windows. To use DoneJS you need a C++ compiler (for native dependencies). First you need a recent version of [Node.js](https://nodejs.org/en/). DoneJS officially supports Node 0.10.x, 0.12.x, and IOjs, but more recent versions will likely work as well.

#### Package Management

In this guide we'll use [chocolatey](https://chocolatey.org/) to install packages needed. You don't have to use chocolatey if you don't want, and can instead search for the dependencies and install them with a Windows installer, but we'll use chocolately because it makes things a bit easier.

After you've installed chocolatey by following the instructions [on the homepage](https://chocolatey.org/) **open an administrative console** and proceed to the next step.

#### Python 2.x

Native dependencies in Node.js are installed with [node-gyp](https://github.com/nodejs/node-gyp) which uses Python as a build tool. It expects Python 2.x:

```shell
choco install python2 -y
```

#### Windows SDK

Next we need the Windows SDK. We're going to assume Windows 7, but adjust this command to the version of Windows you use:

```shell
choco install windows-sdk-7.1 -y
```

#### Visual Studio Express

Installing Visual Studio Express gives us the C++ compiler we need:

```shell
choco install visualstudioexpress2013windowsdesktop -y
```

### Environmental Variables

In order to switch to production mode you need to set the environmental variable `NODE_ENV`. Depending on which console you use this can be done in one of two ways:

**Command Prompt**

```
set NODE_ENV=production
```

**Powershell**

```
$env:NODE_ENV="production"
```

## Mac OS X

### Prerequisites

All that is needed to get DoneJS working on OS X is the Xcode command line tools which you can get by typing:

```shell
xcode-select --install
```

## Debian / Ubuntu

Installing in a Debian / Ubuntu environment takes a little extra work because the version of Node shipped is older than what is supported by DoneJS (and most other Node-based software).

### Prerequisites

Instead of installing Node.js from the repository we recommend using a PPA (a repostiroy maintained by a 3rd party). First get a copy of `curl` if you don't already have it:

```
sudo apt-get install curl
```

Then add the PPA to your source list:

{'fraction_non_alphanumeric': 0.07878211227402473, 'fraction_numerical': 0.0068506184586108465, 'mean_word_length': 4.452282157676349, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 8, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3348081', 'n_tokens_mistral': 1501, 'n_tokens_neox': 1370, 'n_words': 749}