From 216832c3e2f120e91ed0db1a4418db48304d14e8 Mon Sep 17 00:00:00 2001 From: ruidajo Date: Thu, 14 Apr 2022 20:00:06 -0500 Subject: [PATCH] Fixing external word cloud commons installation. --- .../instance/installExternalWordCloudCommons.st | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Socialmetrica.package/NitterUser.class/instance/installExternalWordCloudCommons.st b/Socialmetrica.package/NitterUser.class/instance/installExternalWordCloudCommons.st index 0aed1ec..2808555 100644 --- a/Socialmetrica.package/NitterUser.class/instance/installExternalWordCloudCommons.st +++ b/Socialmetrica.package/NitterUser.class/instance/installExternalWordCloudCommons.st @@ -4,12 +4,16 @@ installExternalWordCloudCommons | commonFiles folder | commonFiles := #( 'https://mutabit.com/repos.fossil/mutabit/uv/wiki/commons/nube-mascara.jpg' - 'https://mutabit.com/repos.fossil/mutabit/raw/cf2aa88169752092a0bd39f8e20128abc85ad5c47d9679496663570c4d30fff0?at=stopwords-es.txt'). + 'https://mutabit.com/repos.fossil/mutabit/raw?name=wiki/commons/stopwords-es.txt&ci=tip'). folder := TweetsCollection dataStore / 'commons'. - folder exists ifFalse: [ folder ensureCreateDirectory]. + folder exists + ifTrue: [ folder ensureDeleteAllChildren ] + ifFalse: [ folder ensureCreateDirectory]. commonFiles do: [ :fileUrl | ZnClient new url: fileUrl; downloadTo: folder]. + (folder children detect: [ :file | file basename includesSubstring: 'raw' ]) + renameTo: 'stopwords-es.txt'. ^ folder \ No newline at end of file