aboutsummaryrefslogtreecommitdiff
path: root/create_notes.sh
blob: 652f62018774c58648504ddaf5551f8b87b40a98 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/bash

orgPath=$1

mkdir -p notes

cat graphdata.json

ls -ls "${orgPath}"

cat graphdata.json |
jq -c '.data.nodes[]' |
while read -r nodes; do
  id=$(echo "${nodes}" | jq -r '.id')
  file=$(echo "${nodes}" | jq -r '.file')
  cp -p "${orgPath}/${file}" "notes/${id}"
done