Skip to content

Conversation

@aokellermann
Copy link

Allows repository to store reviews for same place from multiple authors. Taste/value is averaged and rounded to nearest integer.

  • build
  • spatula
  • gram

Conversion of review files to separate place/review files was done with the following script:

cd places

for i in *.md; do
  d="${i%.md}"
  mkdir -p "$d"
  cp $i $d
  cd $d
  cp $i place.md
  sed -i '/^visited:/d' place.md
  sed -i '/^taste:/d' place.md
  sed -i '/^value:/d' place.md
  sed -i '/^instagram_published:/d' place.md
  sed -i '12,$d' place.md
  mkdir -p reviews
  cp $i reviews/itsiw.md
  sed -i "/^name:/d" reviews/itsiw.md
  sed -i "/^cuisine:/d" reviews/itsiw.md
  sed -i "/^address:/d" reviews/itsiw.md
  sed -i "/^area:/d" reviews/itsiw.md
  sed -i "/^lat:/d" reviews/itsiw.md
  sed -i "/^lon:/d" reviews/itsiw.md
  sed -i "/^phone:/d" reviews/itsiw.md
  sed -i "/^menu:/d" reviews/itsiw.md
  sed -i "/^drinks:/d" reviews/itsiw.md
  rm $i
  cd ..
done

rm *.md

Review filename is a unique id of the author. For the sake of this PR, I assumed all existing reviews were authored by @ItsiW. Will take some manual mving to correct this.

Let me know if any of this is not in the right direction!

Closes #21

@ItsiW
Copy link
Owner

ItsiW commented Aug 18, 2024

Hey sorry to keep you waiting on this, I'm outta town for a few weeks then I'll have a look.

I am so pleasantly surprised that you found this and contributed, let me know if you ever want to grab some food

@aokellermann
Copy link
Author

no worries!

hell yeah, shoot me an email when you're back in town and we'll write a joint review together

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow multiple reviews per restaurant

2 participants