Skip to content

update string

update string #3

name: Convert examples
on: [push, pull_request]
jobs:
convert_examples:
runs-on: ubuntu-latest
steps:
- name: "Checkout repository content"
uses: actions/checkout@v4
- name: "Set up Python 3.x"
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: "Install Linux system dependencies"
run: |
sudo apt-get update
- name: "Install Python dependencies"
run: |
python -m pip install --upgrade pip setuptools
python -m pip install sphinx sphinx-gallery
- name: "Convert to notebooks"
run: |
# mkdir pynest/notebooks
sphx_glr_python_to_jupyter.py $(find copies/examples/ -iname "*.py")
# mv pynest/examples/* pynest/notebooks
grep -rl '"display_name": "Python 3"' pynest/notebooks | xargs sed -i 's/"display_name": "Python 3"/"display_name": "EBRAINS-23.09"/g'
grep -rl '"name": "python3"' pynest/notebooks | xargs sed -i 's/"name": "python3"/"name": "ebrains-23.09"/g'