Skip to content

Commit

Permalink
Add missing step to stata license documentaton.
Browse files Browse the repository at this point in the history
  • Loading branch information
bloodearnest committed Dec 15, 2023
1 parent 4c37c8d commit 0fd0c1d
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions docs/actions-scripts.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,8 +141,10 @@ We currently package version 16.1, with `datacheck`, `safetab`, and `safecount`
As Stata is a commercial product, a license key is needed to use it.

#### If you are a member of the `opensafely` GitHub organisation
* If you are using Windows, then the `opensafely` command line software will
automatically use the OpenSAFELY Stata license.
* If you are using Windows, you must have the [Github Desktop
app](https://desktop.github.com/) installed and be logged into it. Then the
`opensafely` command line software will use that
app to obtain the OpenSAFELY Stata license automatically.
* If you are using macOS:
1. Download and install [GitHub's command-line tool (`gh`)](https://cli.github.com/)
2. Run `gh auth login --web`. Select the "HTTPS" option, and follow the instructions
Expand All @@ -159,11 +161,8 @@ If you are not a member of the `opensafely` GitHub organisation, you must provid
* On Linux, somewhere like `/usr/local/stata17/`
* On macOS it's usually in `/Applications/Stata/`
2. Within that file, locate a license string of the format `SerialNumber!Code!Authorization!User!Organisation!VersionCode`.
3. Set it as an environment variable using a [method appropriate to your operating system](https://chlee.co/how-to-setup-environment-variables-for-windows-mac-and-linux/). On Linux or macOS, you'd do it like this:
```bash
export STATA_LICENSE='your license string'
```
The `opensafely` command line software will now automatically use this Stata license.
3. Set it as an environment variable using a [method appropriate to your operating system](https://chlee.co/how-to-setup-environment-variables-for-windows-mac-and-linux/). The name of the environment variable should be `STATA_LICENSE`, and its contents should be the entire license string.
The `opensafely` command line software should now automatically use this Stata license after opening a new terminal.


### Python
Expand Down

0 comments on commit 0fd0c1d

Please sign in to comment.