2022-04-15 00:20:45 +00:00
|
|
|
accessing
|
2022-05-14 21:56:07 +00:00
|
|
|
installCommons
|
2022-04-15 00:20:45 +00:00
|
|
|
|
|
|
|
| commonFiles folder |
|
2022-06-09 18:43:48 +00:00
|
|
|
commonFiles := #(
|
2022-05-14 21:56:07 +00:00
|
|
|
'https://mutabit.com/repos.fossil/mutabit/raw?name=wiki/commons/stopwords-es.txt&ci=tip'
|
2022-06-09 18:43:48 +00:00
|
|
|
'https://mutabit.com/repos.fossil/mutabit/raw?name=wiki/commons/stopwords-en.txt&ci=tip'
|
|
|
|
'https://mutabit.com/repos.fossil/mutabit/uv/wiki/commons/nube-mascara.jpg'
|
2022-05-14 21:56:07 +00:00
|
|
|
'https://mutabit.com/repos.fossil/mutabit/uv/wiki/commons/logo-mutabit-negro.png').
|
2022-04-15 00:20:45 +00:00
|
|
|
folder := TweetsCollection dataStore / 'commons'.
|
2022-04-15 01:00:06 +00:00
|
|
|
folder exists
|
|
|
|
ifTrue: [ folder ensureDeleteAllChildren ]
|
|
|
|
ifFalse: [ folder ensureCreateDirectory].
|
2022-06-09 18:51:20 +00:00
|
|
|
commonFiles do: [ :fileUrl | | temp |
|
2022-04-15 00:20:45 +00:00
|
|
|
ZnClient new
|
|
|
|
url: fileUrl;
|
2022-06-09 18:43:48 +00:00
|
|
|
downloadTo: folder.
|
2022-06-09 18:51:20 +00:00
|
|
|
temp := (folder children select: [ :file | file basename includesSubstring: 'raw' ]).
|
|
|
|
temp isNotEmpty ifTrue: [
|
|
|
|
temp first renameTo: (((fileUrl splitOn: 'raw?') second splitOn: '/') last removeSuffix: '&ci=tip')].
|
2022-06-09 18:43:48 +00:00
|
|
|
].
|
|
|
|
^ folder
|