Skip to content

Commit

Permalink
Merge pull request #17 from Green-Software-Foundation/rm-yarn
Browse files Browse the repository at this point in the history
Replace yarn with npm across docs
  • Loading branch information
jmcook1186 authored Jan 10, 2024
2 parents 01b57ec + c87de24 commit cbf9480
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 13 deletions.
4 changes: 2 additions & 2 deletions docs/01-overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ Only through a granular analysis of the impacts of your software system can inve

The **IF source code** can be found in the [IF Github repository](https://github.com/Green-Software-Foundation/if). The code there covers the framework, which includes all the infrastructure for reading and writing input and output yamls, invoking models, running the command line tool and associated helper functions. However, it does not include the actual models themselves. Part of the IF design philosophy is that all models should be plugins, so that the IF is as composable and configurable as possible. Therefore, to use IF, you have to either create your own models or find some prebuilt ones and install them yourself. This also implies that you take responsibility for the models you choose to install.

We do provide a **standard library of models** built and maintained by the IF core team. These can be found in the [`if-models` Github repository](https://github.com/Green-Software-Foundation/if-models). You can install these into `if` by running `yarn install https://github.com/Green-Software-Foundation/if-models` from the `if` project directory.
We do provide a **standard library of models** built and maintained by the IF core team. These can be found in the [`if-models` Github repository](https://github.com/Green-Software-Foundation/if-models). You can install these into `if` by running `npm install https://github.com/Green-Software-Foundation/if-models` from the `if` project directory.

There is also a second repository for **models we expect community members to maintain**. These can be found in the [`if-unofficial-models` Github repository](https://github.com/Green-Software-Foundation/if-unofficial-models). You can install these into `if` by running `yarn install https://github.com/Green-Software-Foundation/if-unofficial-models` from the `if` project directory.
There is also a second repository for **models we expect community members to maintain**. These can be found in the [`if-unofficial-models` Github repository](https://github.com/Green-Software-Foundation/if-unofficial-models). You can install these into `if` by running `npm install https://github.com/Green-Software-Foundation/if-unofficial-models` from the `if` project directory.

Finally, the **source code for this documentation** website is available at the [`if-docs` Github repository](https://github.com/Green-Software-Foundation/if-docs).

Expand Down
12 changes: 6 additions & 6 deletions docs/04-getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,18 @@ This page will provide the basic instructions for getting up and running with Im

## 0: Set up your environment

To run Impact Framework you need `node` installed on your computer. Node v18.17.1 is currently recommended. You can use `yarn` or `npm` to manage packages.
To run Impact Framework you need `node` installed on your computer. Node v18.17.1 is currently recommended. You can use `npm` to manage packages.

You can create a local project directory, say `if-project`.

```
mkdir if-project
```

Navigate to that directory and initialize a yarn project
Navigate to that directory and initialize an npm project

```
cd if-project && yarn init
cd if-project && npm init
```


Expand All @@ -24,16 +24,16 @@ cd if-project && yarn init
Install the Impact Framework. This includes the `impact-engine` command line tool.

```sh
yarn add @grnsft/if
npm install -g @grnsft/if
```

## 2: Install some model plugins

Install some of the models you want to include in your model pipeline. The pair of commands below will install both the official and unofficial IF model packages.

```sh
yarn add @grnsft/if-models
yarn add @grnsft/if-unofficial-models
npm install -g @grnsft/if-models
npm install -g @grnsft/if-unofficial-models
```

## 3: Create a manifest file
Expand Down
4 changes: 2 additions & 2 deletions docs/07-tutorials/how-to-build-models.md
Original file line number Diff line number Diff line change
Expand Up @@ -168,10 +168,10 @@ For using locally developed model in `if` please follow these steps:
You can simply save your model in a public Github repository and pass the path to it in your impl.
For example, for a model saved in `github.com/my-repo/my-model` you can do the following:

yarn install your model:
npm install your model:

```
yarn add https://github.com/my-repo/my-model
npm install https://github.com/my-repo/my-model
```

Then, in your `impl`, provide the path in the model instantiation. You also need to specify which class the model instantiates. In this case you are using the IOutputModelInterface, so you can specify `OutputModel`.
Expand Down
4 changes: 2 additions & 2 deletions docs/07-tutorials/how-to-import-models.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,10 @@ initialize:
Anyone can develop models. As long as you conform to our model specification, you can load your model into IF an run it as part of a pipeline. For guidance on model building, see [How to build models](./how-to-build-models.md). We provide a [template](https://github.com/Green-Software-Foundation/if-model-template) to help you structure your models correctly.
You can then load your model directly from yoru Guthub repository, or from `npm` if you have published your model there. To load a model, first install it by providing the path to the repository to `yarn add` as follows:
You can then load your model directly from yoru Guthub repository, or from `npm` if you have published your model there. To load a model, first install it by providing the path to the repository to `npm install` as follows:

```sh
yarn add https://github.com/Green-Software-Foundation/if-models
npm install https://github.com/Green-Software-Foundation/if-models
```

Then, in your impl, initialize the model as follows:
Expand Down
2 changes: 1 addition & 1 deletion docs/08-Contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ Add and commit:

Commit your changes in logical chunks. Please do not push all changes in one commit.

> Run `yarn fix` before commiting for not having conflict with CI linter.
> Run `npm run fix` before commiting for not having conflict with CI linter.
Please adhere to these [Commit message guidelines](#commit-message-guidelines)
or your code is unlikely be merged into the main project.
Expand Down

0 comments on commit cbf9480

Please sign in to comment.