Skip to content

Commit 269958a

Browse files
authored
Merge pull request #21 from jtpio/update-dev-instructions
Use `mamba` to activate the environment
2 parents 79472f5 + 02bf298 commit 269958a

File tree

4 files changed

+14
-6
lines changed

4 files changed

+14
-6
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ pip uninstall jupyterlite-p5-kernel
4141

4242
# create a new enviroment
4343
mamba create --name jupyterlite-p5-kernel -c conda-forge python=3.9 yarn jupyterlab
44-
conda activate jupyterlite-p5-kernel
44+
mamba activate jupyterlite-p5-kernel
4545

4646
# Install package in development mode
4747
python -m pip install -e .

package.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
"build": "lerna run build",
3030
"build:prod": "lerna run build:prod",
3131
"build:test": "lerna run build:test",
32-
"bump:version": "lerna version --no-push --force-publish --no-git-tag-version --yes",
32+
"bump:js:version": "lerna version --no-push --force-publish --no-git-tag-version --yes",
3333
"clean": "lerna run clean",
3434
"install": "lerna bootstrap",
3535
"install:dev": "yarn run build:prod && yarn run develop",
@@ -41,7 +41,6 @@
4141
"prettier": "prettier --write \"**/*{.ts,.tsx,.js,.jsx,.css,.json,.md}\"",
4242
"prettier:check": "prettier --list-different \"**/*{.ts,.tsx,.js,.jsx,.css,.json,.md}\"",
4343
"publish": "yarn run clean && yarn run build && lerna publish",
44-
"sync:version": "python scripts/sync-version.py",
4544
"test": "lerna run test",
4645
"watch": "lerna run watch"
4746
},

pyproject.toml

+1-2
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,10 @@ source_dir = "src"
5858
build_dir = "jupyterlite_p5_kernel/labextension"
5959

6060
[tool.jupyter-releaser.options]
61-
version_cmd = "jlpm run bump:version"
61+
version_cmd = "python scripts/bump-version.py"
6262

6363
[tool.jupyter-releaser.hooks]
6464
before-bump-version = ["python -m pip install jupyterlab~=3.1"]
65-
after-bump-version = ["jlpm run sync:version"]
6665
before-build-npm = ["python -m pip install jupyterlab~=3.1", "jlpm", "jlpm build:prod"]
6766
before-build-python = ["jlpm clean"]
6867

scripts/sync-version.py renamed to scripts/bump-version.py

+11-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,16 @@
1-
from pathlib import Path
1+
import argparse
22
import json
33

4+
from pathlib import Path
5+
from subprocess import run
6+
7+
parser = argparse.ArgumentParser()
8+
parser.add_argument("version")
9+
args = parser.parse_args()
10+
version = args.version
11+
12+
run(f'jlpm run bump:js:version {version}', shell=True, check=True)
13+
414
root = Path(__file__).parent.parent
515
version_file = root / "packages" / "p5-kernel-extension" / "package.json"
616
package_file = root / "package.json"

0 commit comments

Comments
 (0)