#!/bin/bash

FILES="./*.json"
for f in $FILES
do
  echo "Processing $f file..."
  filename=$(basename -- "$f")
  num="${filename%.*}"
  cp $f ../oldmetadata
  cp $f $num
  rm $f
  #sed -i "s/\"image\": \"\"/\"image\": \"ipfs:\/\/bafybeicqbnmpwz7355kzw3y7gt7sesx3ekmhx54rs34a6ti3tlbywgyn4u\/images\/$num.png\"/" $f
  #sed -i "s/Cyber Plastic Hero #1/Cyber Plastic Hero #$num/" $f
  #sed -i "s/\"value\": 1/\"value\": $num/" $f
done