We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f847757 commit 56afc29Copy full SHA for 56afc29
urlwatcher/urlwatcher.sh
@@ -170,14 +170,16 @@ while IFS='' read -r line || [ -n "${line}" ]; do
170
URL=$(echo $line | cut -d ',' -f9-)
171
172
echo "Checking $URL"
173
+
174
+ # As image directory, we use the name and chat id to create unique directories
175
176
# Create the image directory, if it does not exist yet
- if [ ! -d "$IMAGES_DIRECTORY/$NAME" ]; then
- mkdir "$IMAGES_DIRECTORY/$NAME"
177
+ if [ ! -d "$IMAGES_DIRECTORY/${NAME}.${CHAT_ID}" ]; then
178
+ mkdir "$IMAGES_DIRECTORY/${NAME}.${CHAT_ID}"
179
fi
180
181
# Go into it
- cd "images/$NAME"
182
+ cd "images/${NAME}.${CHAT_ID}"
183
184
# Rename the old screenshot file, if it exists
185
if [ -f latest.png ]; then
0 commit comments