Update publish-neuron.yml

This commit is contained in:
Thomas Bishop 2024-10-20 19:08:50 +01:00 committed by GitHub
parent 36b8c84321
commit 13b2bd3de5

View file

@ -11,12 +11,12 @@ jobs:
- name: Build neuron site 🔧 - name: Build neuron site 🔧
run: | run: |
mkdir -p .neuron/output && touch .neuron/output/.nojekyll mkdir -p .neuron/output && touch .neuron/output/.nojekyll
NEURON_DIR=$(find neuron -maxdepth 1 -type d -regex 'neuron/[a-f0-9-]\{36\}' | head -n 1) NEURON_DIR=$(ls -d neuron/*/ | head -n 1)
if [ -n "$NEURON_DIR" ]; then if [ -n "$NEURON_DIR" ]; then
echo "Found Neuron directory: $NEURON_DIR" echo "Found Neuron directory: $NEURON_DIR"
docker run -v $PWD:/notes sridca/neuron neuron gen --pretty-urls /notes docker run -v $PWD:/notes sridca/neuron neuron gen --pretty-urls
else else
echo "No directory matching neuron/UUID format found" echo "No subdirectory found in neuron/"
exit 1 exit 1
fi fi
- name: Deploy to gh-pages 🚀 - name: Deploy to gh-pages 🚀