Skip to content

Commit

Permalink
change count in README when updating images
Browse files Browse the repository at this point in the history
Include the total number of images in the README file, updating it each
time a new batch of images is pushed.
  • Loading branch information
MikkelPaulson committed Dec 8, 2021
1 parent 94b5ea1 commit fafa457
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
12 changes: 7 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
# artflow.ai portraits

This is a collection of portraits scraped from artflow.ai. The images are
licensed by the copyright holder ([artflow.ai](https://artflow.ai/)) under the
[Creative Commons Attribution](https://creativecommons.org/licenses/by/4.0/)
license, but are not made available by the copyright holder in a format that can
be easily consumed in bulk.
This is a collection of 0 portraits scraped from artflow.ai.

The images are licensed by the copyright holder
([artflow.ai](https://artflow.ai/)) under the [Creative Commons
Attribution](https://creativecommons.org/licenses/by/4.0/) license, but are not
made available by the copyright holder in a format that can be easily consumed
in bulk.

The images in this repository are automatically collected, converted from WEBP
to JPEG, and saved according to the following format:
Expand Down
8 changes: 7 additions & 1 deletion commit.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,19 @@ cd "$(dirname "$0")" || return

source .env

git pull

git add images

sed -i "/^This is a collection/c This is a collection of $(find images -type f | wc -l) portraits scraped from artflow.ai." README.md

git add README.md

git \
-c user.name="$USER_NAME"\
-c user.email="$USER_EMAIL" \
-c user.signingkey="$USER_SIGNINGKEY" \
commit \
-m "$(date +%Y-%m-%d): add $(git status --porcelain=v1 | grep -c '^A ') images"
-m "$(date +%Y-%m-%d): add $(git status --porcelain=v1 | grep -c '^A images') images"

git push

0 comments on commit fafa457

Please sign in to comment.