Différences
Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentes Révision précédente Prochaine révision | Révision précédente | ||
|
actions:archives:archives [2022/02/16 14:53] balleydc [Transformer une boite mail en archives sympa] |
actions:archives:archives [2022/04/29 15:48] (Version actuelle) balleydc [Transformer une boite mail en archives sympa d'une liste] |
||
|---|---|---|---|
| Ligne 2: | Ligne 2: | ||
| ===== Transformer une boite mail en archives sympa d'une liste ===== | ===== Transformer une boite mail en archives sympa d'une liste ===== | ||
| + | |||
| + | https://www.sympa.org/contribs/migration_and_archives/index | ||
| Récupérer les messages ou la boite mail dans un fichier au format mbox | Récupérer les messages ou la boite mail dans un fichier au format mbox | ||
| + | |||
| + | |||
| + | |||
| + | Si le fichier mbox contient des ^M, les supprimer : | ||
| + | vi puis ::%s/[Ctrl+V][Entree]/\r/g (touche [Ctrl+V] et [Entree] | ||
| + | |||
| + | Si le fichier mbox ne contient pas la bonne date au niveau de "From -", par exemple avec zimbra le "From -" a la date de l'export pour tous les messages, solution récupérer la date au niveau "Date: " : utiliser un script du genre [[modif_date_mbox.pl]] | ||
| Utiliser le script [[mbox2sympa.pl]] pour générer des fichiers log par mois du fichier mbox | Utiliser le script [[mbox2sympa.pl]] pour générer des fichiers log par mois du fichier mbox | ||
| - | <code> | + | # su - sympa \\ |
| # cd ~sympa/list_data/<color #22b14c>ROBOT</color>/<color #22b14c>LISTE</color>/archives | # cd ~sympa/list_data/<color #22b14c>ROBOT</color>/<color #22b14c>LISTE</color>/archives | ||
| - | Copier le fichier.mbox dans ce répertoire | + | |
| - | # mbox2sympa.pl fichier.mbox | + | Copier le <color #22b14c>fichier.mbox</color> dans ce répertoire |
| + | |||
| + | # **mbox2sympa.pl** <color #22b14c>fichier.mbox</color> | ||
| # ls | # ls | ||
| log.202101 log.202102 ...... | log.202101 log.202102 ...... | ||
| - | # /home/sympa/bin/arc2webarc.pl <color #22b14c>LISTE ROBOT</color> | + | |
| + | Attention : pour faire marcher le fichier j'ai modifier arc2webarc.pl : mis en dur le nom de la liste et du robot et initialiser la variable $nummsg ( $nummsg{$year}{$month} = 0; ) | ||
| + | |||
| + | # /home/sympa/bin/**arc2webarc.pl** -input-directory=. <color #22b14c>LISTE ROBOT</color> | ||
| Web archives already exist for list <color #22b14c>LISTE</color> | Web archives already exist for list <color #22b14c>LISTE</color> | ||
| Go on (<CR>|n) ?y | Go on (<CR>|n) ?y | ||
| Ligne 21: | Ligne 36: | ||
| Found 71 messages | Found 71 messages | ||
| Rebuilding HTML | Rebuilding HTML | ||
| - | notice Sympa::Spool::store() Sympa::Message <> is stored into Sympa::Spool::Archive as <1645008294.1645008294.449418.sympa@<color #22b14c>ROBOT</color>,16468,2693> | + | notice Sympa::Spool::store() Sympa::Message <> is stored into Sympa::Spool::Archive as <1645008294.1645008294.449418.sympa@ROBOT,16468,2693> |
| - | + | ||
| - | Have a look in /home/sympa/arc/<color #22b14c>LISTE</color>@<color #22b14c>ROBOT</color>/-/ directory for messages dateless | + | Have a look in /home/sympa/arc/LISTE@ROBOT/-/ directory for messages dateless |
| Now, you should add a web_archive parameter in the config file to make it accessible from the web | Now, you should add a web_archive parameter in the config file to make it accessible from the web | ||
| + | Attention sympa met un certain temps à reconstruire les archives donc les archives n'apparaissent pas tout de suite dans l'interface web. | ||
| + | On peut aller sur l'interface web "Administrateur des listes" puis les archives" puis saisir le nom de la liste puis "Reconstruire les archives" | ||
| + | |||
| + | |||
| + | ===== Générer un fichier mbox avec thunderbird ===== | ||
| + | |||
| + | Installer l'extension ImportExportTools NG | ||
| + | |||
| + | Sélectionner un dossier '(ex facture) avec clic droit, puis "Importer / Exporter au format << mbox >> / >> eml >>" puis "exporter le dossier" | ||
| + | |||
| + | Choisir un dossier puis aller dans ce dossier | ||
| + | |||
| + | Renommer facture en facture.mbox | ||
| | | ||
| - | </code> | + | |
