Skip to content

Commit

Permalink
rm envs
Browse files Browse the repository at this point in the history
  • Loading branch information
jph00 committed Sep 1, 2024
1 parent b3508fb commit b6282db
Showing 1 changed file with 13 additions and 73 deletions.
86 changes: 13 additions & 73 deletions index.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
Expand All @@ -21,102 +20,38 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"This file will become your README and also the index of your documentation."
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"## Developer Guide"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"If you are new to using `nbdev` here are some useful pointers to get you started."
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"### Setup"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"It can be helpful to have a dedicated environment for development. Here we are assuming that you have an conda environment file called `env.yml` named after `{{lib_path}}` i.e.:\n",
"\n",
"```yaml\n",
"# env.yml\n",
"name: {{lib_path}}\n",
"\n",
"channels:\n",
" - fastai\n",
"\n",
"dependencies:\n",
" - fastai::nbdev>=2.3.12\n",
"# - python>=3.11 # specify python version if required \n",
"# - dependency 1\n",
"# - dependency 2\n",
"# - pip\n",
"# pip:\n",
"# - pip dependency 1\n",
"# - pip dependency 2\n",
"```"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"You can then use `conda` or `mamba` (faster at resolving) to create and update your environment file should your needs change as you work on `{{lib_path}}`"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"```sh\n",
"# create a conda environment for working on {{repo}}\n",
"$ mamba env create -f env.yml\n",
"\n",
"# update conda environment\n",
"$ mamba env update -n {{lib_path}} --file env.yml\n",
"```"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"### Install {{lib_path}} in Development mode"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"```sh\n",
"# activate conda environment\n",
"$ conda activate {{lib_path}}\n",
"\n",
"# make sure {{lib_path}} package is installed in development mode\n",
"$ pip install -e .\n",
"\n",
Expand All @@ -129,23 +64,20 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"## Usage"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"### Installation"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
Expand Down Expand Up @@ -176,15 +108,13 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"### Documentation"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
Expand All @@ -197,15 +127,13 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
"## How to use"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
Expand Down Expand Up @@ -242,9 +170,21 @@
],
"metadata": {
"kernelspec": {
"display_name": "python3",
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.8"
}
},
"nbformat": 4,
Expand Down

0 comments on commit b6282db

Please sign in to comment.