From 60c889ad762888f0df76a84cae213891ffe7af41 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Xos=C3=A9=20M?=
Date: Tue, 21 Aug 2018 07:28:00 +0200
Subject: [PATCH 01/33] primera ao galego
---
po/gl.po | 279 ++++++++++++++++++++++++++++---------------------------
1 file changed, 140 insertions(+), 139 deletions(-)
diff --git a/po/gl.po b/po/gl.po
index d5a558df..d27b2f64 100644
--- a/po/gl.po
+++ b/po/gl.po
@@ -4,7 +4,7 @@ msgstr ""
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-06-15 16:33-0700\n"
"PO-Revision-Date: 2018-06-15 16:33-0700\n"
-"Last-Translator: Automatically generated\n"
+"Last-Translator: Xosé M. \n"
"Language-Team: none\n"
"Language: gl\n"
"MIME-Version: 1.0\n"
@@ -13,413 +13,414 @@ msgstr ""
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
msgid "Latest articles"
-msgstr ""
+msgstr "Últimos artigos"
msgid "No posts to see here yet."
-msgstr ""
+msgstr "Aínda non hai entradas publicadas"
msgid "New article"
-msgstr ""
+msgstr "Novo artigo"
msgid "New blog"
-msgstr ""
+msgstr "Novo blog"
msgid "Create a blog"
-msgstr ""
+msgstr "Crear un blog"
msgid "Title"
-msgstr ""
+msgstr "Título"
msgid "Create blog"
-msgstr ""
+msgstr "Crear blog"
msgid "Comment \"{{ post }}\""
-msgstr ""
+msgstr "Comentar \"{{ post }}\""
msgid "Content"
-msgstr ""
+msgstr "Contido"
msgid "Submit comment"
-msgstr ""
+msgstr "Enviar comentario"
msgid "Something broke on our side."
-msgstr ""
+msgstr "Algo fallou pola nosa parte"
msgid "Sorry about that. If you think this is a bug, please report it."
-msgstr ""
+msgstr "Lamentálmolo. Si cree que é un bug, infórmenos por favor."
msgid "Configuration"
-msgstr ""
+msgstr "Axustes"
msgid "Configure your instance"
-msgstr ""
+msgstr "Configure a súa instancia"
msgid "Name"
-msgstr ""
+msgstr "Nome"
msgid "Let's go!"
-msgstr ""
+msgstr "Imos!"
msgid "Welcome on {{ instance_name | escape }}"
-msgstr ""
+msgstr "Ben vida a {{ instance_name | escape }}"
msgid "Notifications"
-msgstr ""
+msgstr "Notificacións"
msgid ""
"Written by {{ link_1 }}{{ url }}{{ link_2 }}{{ name | escape }}{{ link_3 }}"
-msgstr ""
+msgstr "Escrito por {{ link_1 }}{{ url }}{{ link_2 }}{{ name | escape }}{{ link_3 }}"
msgid "This article is under the {{ license }} license."
-msgstr ""
+msgstr "Este artigo ten licenza {{ license }}"
msgid "One like"
msgid_plural "{{ count }} likes"
-msgstr[0] ""
-msgstr[1] ""
+msgstr[0] "Un gústame"
+msgstr[1] "{{ count }} gústame"
msgid "I don't like this anymore"
-msgstr ""
+msgstr "Xa non me gusta"
msgid "Add yours"
-msgstr ""
+msgstr "Engada os seus"
msgid "One reshare"
msgid_plural "{{ count }} reshares"
-msgstr[0] ""
-msgstr[1] ""
+msgstr[0] "Compartido unha vez"
+msgstr[1] "Compartido {{ count }} veces"
msgid "I don't want to reshare this anymore"
-msgstr ""
+msgstr "Xa non quero compartir esto"
msgid "Reshare"
-msgstr ""
+msgstr "Compartir"
msgid "Comments"
-msgstr ""
+msgstr "Comentarios"
msgid "Respond"
-msgstr ""
+msgstr "Respostar"
msgid "Comment"
-msgstr ""
+msgstr "Comentar"
msgid "New post"
-msgstr ""
+msgstr "Nova entrada"
msgid "Create a post"
-msgstr ""
+msgstr "Crear unha entrada"
msgid "Publish"
-msgstr ""
+msgstr "Publicar"
msgid "Login"
-msgstr ""
+msgstr "Conectar"
msgid "Username or email"
-msgstr ""
+msgstr "Usuaria ou correo-e"
msgid "Password"
-msgstr ""
+msgstr "Contrasinal"
msgid "Dashboard"
-msgstr ""
+msgstr "Taboleiro"
msgid "Your Dashboard"
-msgstr ""
+msgstr "O seu taboleiro"
msgid "Your Blogs"
-msgstr ""
+msgstr "Os seus Blogs"
msgid "You don't have any blog yet. Create your own, or ask to join one."
-msgstr ""
+msgstr "Aínda non ten blogs. Publique un, ou solicita unirse a un."
msgid "Start a new blog"
-msgstr ""
+msgstr "Iniciar un blog"
msgid "Admin"
-msgstr ""
+msgstr "Admin"
msgid "It is you"
-msgstr ""
+msgstr "É vosted"
msgid "Edit your profile"
-msgstr ""
+msgstr "Edite o seu perfil"
msgid "Open on {{ instance_url }}"
-msgstr ""
+msgstr "Abrir en {{ instance_url }}"
msgid "Follow"
-msgstr ""
+msgstr "Seguir"
msgid "Unfollow"
-msgstr ""
+msgstr "Deixar de seguir"
msgid "Recently reshared"
-msgstr ""
+msgstr "Compartido recentemente"
msgid "One follower"
msgid_plural "{{ count }} followers"
-msgstr[0] ""
-msgstr[1] ""
+msgstr[0] "Unha seguidora"
+msgstr[1] "{{ count }} seguidoras"
msgid "Edit your account"
-msgstr ""
+msgstr "Edite a súa conta"
msgid "Your Profile"
-msgstr ""
+msgstr "O seu perfil"
msgid "Display Name"
-msgstr ""
+msgstr "Nome mostrado"
msgid "Email"
-msgstr ""
+msgstr "Correo-e"
msgid "Summary"
-msgstr ""
+msgstr "Resumen"
msgid "Update account"
-msgstr ""
+msgstr "Actualizar conta"
msgid "{{ name | escape }}'s followers"
-msgstr ""
+msgstr "Seguidoras de {{ name | escape }}"
msgid "Followers"
-msgstr ""
+msgstr "Seguidoras"
msgid "New Account"
-msgstr ""
+msgstr "Nova conta"
msgid "Create an account"
-msgstr ""
+msgstr "Crear unha conta"
msgid "Username"
-msgstr ""
+msgstr "Nome de usuaria"
msgid "Password confirmation"
-msgstr ""
+msgstr "Confirmación do contrasinal"
msgid "Create account"
-msgstr ""
+msgstr "Crear conta"
msgid "Plume"
-msgstr ""
+msgstr "Plume"
msgid "Menu"
-msgstr ""
+msgstr "Menú"
msgid "My account"
-msgstr ""
+msgstr "A miña conta"
msgid "Log Out"
-msgstr ""
+msgstr "Desconectar"
msgid "Log In"
-msgstr ""
+msgstr "Conectar"
msgid "Register"
-msgstr ""
+msgstr "Rexistrar"
msgid "You need to be logged in order to create a new blog"
-msgstr ""
+msgstr "Debe estar conectada para crear un novo blog"
msgid "You need to be logged in order to post a comment"
-msgstr ""
+msgstr "Debe estar conectada para publicar un comentario"
msgid "You need to be logged in order to like a post"
-msgstr ""
+msgstr "Debe estar conectada para gustar unha entrada"
msgid "You need to be logged in order to see your notifications"
-msgstr ""
+msgstr "Debe estar conectada para ver as súas notificacións"
msgid "You need to be logged in order to write a new post"
-msgstr ""
+msgstr "Debe estar conectada para escribir unha nova entrada"
msgid "You need to be logged in order to reshare a post"
-msgstr ""
+msgstr "Debe estar conectada para compartir unha entrada"
msgid "Invalid username or password"
-msgstr ""
+msgstr "Usuaria ou Contrasinal incorrectos"
msgid "You need to be logged in order to access your dashboard"
-msgstr ""
+msgstr "Debe estar conectada para acceder ao seu taboleiro"
msgid "You need to be logged in order to follow someone"
-msgstr ""
+msgstr "Debe estar conectada para seguir a alguén"
msgid "You need to be logged in order to edit your profile"
-msgstr ""
+msgstr "Debe estar conectada para editar o seu perfil"
msgid "By {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
-msgstr ""
+msgstr "Por {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
msgid "{{ data }} reshared your article"
-msgstr ""
+msgstr "{{ data }} comparteu o seu artigo"
msgid "{{ data }} started following you"
-msgstr ""
+msgstr "{{ data }} comezou a seguila"
msgid "{{ data }} liked your article"
-msgstr ""
+msgstr "{{ data }} gustou do seu artigo"
msgid "{{ data }} commented your article"
-msgstr ""
+msgstr "{{ data }} comentou o seu artigo"
msgid "We couldn't find this page."
-msgstr ""
+msgstr "Non atopamos esta páxina"
msgid "The link that led you here may be broken."
-msgstr ""
+msgstr "A ligazón que a trouxo aquí podería estar quebrado"
msgid "You are not authorized."
-msgstr ""
+msgstr "Non ten permiso."
msgid "You are not author in this blog."
-msgstr ""
+msgstr "Vostede non é autora en este blog."
msgid "{{ data }} mentioned you."
-msgstr ""
+msgstr "{{ data }} mencionouna."
msgid "Your comment"
-msgstr ""
+msgstr "O seu comentario"
msgid "Unknown error"
-msgstr ""
+msgstr "Fallo descoñecido"
msgid "Invalid name"
-msgstr ""
+msgstr "Nome non válido"
msgid "A blog with the same name already exists."
-msgstr ""
+msgstr "Xa existe un blog co mismo nome."
msgid "Your comment can't be empty"
-msgstr ""
+msgstr "O seu comentario non pode estar baldeiro"
msgid "A post with the same title already exists."
-msgstr ""
+msgstr "Xa existe unha entrada co mismo nome."
msgid "We need an email or a username to identify you"
-msgstr ""
+msgstr "Precisamos un correo-e ou un nome de usuaria para identificala"
msgid "Your password can't be empty"
-msgstr ""
+msgstr "O contrasinal non pode estar baldeiro"
msgid "Passwords are not matching"
-msgstr ""
+msgstr "Con coinciden os contrasinais"
msgid "Username can't be empty"
-msgstr ""
+msgstr "O nome de usuaria non pode estar baldeiro"
msgid "Invalid email"
-msgstr ""
+msgstr "Correo-e non válido"
msgid "Password should be at least 8 characters long"
-msgstr ""
+msgstr "O contrasinal debe ter ao menos 8 caracteres"
msgid "One author in this blog: "
msgid_plural "{{ count }} authors in this blog: "
-msgstr[0] ""
-msgstr[1] ""
+msgstr[0] "Unha autora en este blog: "
+msgstr[1] "{{ count }} autoras en este blog: "
msgid "Login or use your Fediverse account to interact with this article"
-msgstr ""
+msgstr "Conéctese ou utilice a súa conta no fediverso para interactuar con este artigo"
msgid "Optional"
-msgstr ""
+msgstr "Opcional"
msgid "One article in this blog"
msgid_plural "{{ count }} articles in this blog"
-msgstr[0] ""
-msgstr[1] ""
+msgstr[0] "Un artigo en este blog"
+msgstr[1] "{{ count }} artigos en este blog"
msgid "Previous page"
-msgstr ""
+msgstr "Páxina anterior"
msgid "Next page"
-msgstr ""
+msgstr "Páxina seguinte"
msgid "{{ user }} mentioned you."
-msgstr ""
+msgstr "{{ user }} mencionouna."
msgid "{{ user }} commented your article."
-msgstr ""
+msgstr "{{ user }} comentou o artigo."
msgid "{{ user }} is now following you."
-msgstr ""
+msgstr "{{ user }} está a seguila."
msgid "{{ user }} liked your article."
-msgstr ""
+msgstr "{{ user }} gustou do seu artigo."
msgid "{{ user }} reshared your article."
-msgstr ""
+msgstr "{{ user }} comparteu o seu artigo."
msgid "Source code"
-msgstr ""
+msgstr "Código fonte"
msgid "Matrix room"
-msgstr ""
+msgstr "Sala Matrix"
msgid "Administration"
-msgstr ""
+msgstr "Administración"
msgid "Instance settings"
-msgstr ""
+msgstr "Axustes da instancia"
msgid "Allow anyone to register"
-msgstr ""
+msgstr "Permitir o rexistro aberto"
msgid "Short description"
-msgstr ""
+msgstr "Descrición curta"
msgid "Markdown is supported"
-msgstr ""
+msgstr "Escritura Markdown activada"
msgid "Long description"
-msgstr ""
+msgstr "Descrición longa"
msgid "Default license"
-msgstr ""
+msgstr "Licenza por omisión"
msgid "Save settings"
-msgstr ""
+msgstr "Gardar axustes"
msgid "No comments yet. Be the first to react!"
-msgstr ""
+msgstr "Sin comentarios. Sexa a primeira e comentar!"
msgid "About this instance"
-msgstr ""
+msgstr "Sobre esta instancia"
msgid "What is Plume?"
-msgstr ""
+msgstr "Qué é Plume?"
msgid "Plume is a decentralized blogging engine."
-msgstr ""
+msgstr "Plume é un motor de publicación descentralizada."
msgid "Authors can manage various blogs from an unique website."
-msgstr ""
+msgstr "As autoras poden xestionar varios blogs desde un único sitio web."
msgid ""
"Articles are also visible on other Plume websites, and you can interact with "
"them directly from other platforms like Mastodon."
-msgstr ""
+msgstr "Os artigos son visibles tamén en outros sitios Plume, e pode interactuar con"
+"eles desde outras plataformas como Mastadon."
msgid "Create your account"
-msgstr ""
+msgstr "Cree a súa conta"
msgid "About {{ instance_name }}"
-msgstr ""
+msgstr "Acerca de {{ instance_name }}"
msgid "Home to"
-msgstr ""
+msgstr "Fogar de"
msgid "people"
-msgstr ""
+msgstr "persoas"
msgid "Who wrote"
-msgstr ""
+msgstr "Que escribiron"
msgid "articles"
-msgstr ""
+msgstr "artigos"
msgid "Read the detailed rules"
-msgstr ""
+msgstr "Lea o detalle das normas"
From 5bc7284a7284f741d0cb4d335472cc5bbd0761c0 Mon Sep 17 00:00:00 2001
From: GnoxR
Date: Tue, 21 Aug 2018 15:22:00 +0000
Subject: [PATCH 02/33] Improve French translation
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Consistently use infinitive for action strings (Commentez → Commenter).
Fix a few typos and simplify inclusive writing (aut⋅eur⋅ice⋅s → auteur⋅ice⋅s).
End more error messages with a period to make forms more consistent.
Translate previous page and next page.
---
po/fr.po | 59 ++++++++++++++++++++++++++++----------------------------
1 file changed, 29 insertions(+), 30 deletions(-)
diff --git a/po/fr.po b/po/fr.po
index 8ce372d1..b1e246ea 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -43,18 +43,18 @@ msgid "Submit comment"
msgstr "Envoyer le commentaire"
msgid "Something broke on our side."
-msgstr "Nous avons cassé quelque chose"
+msgstr "Nous avons cassé quelque chose."
msgid "Sorry about that. If you think this is a bug, please report it."
msgstr ""
"Nous sommes désolé⋅e⋅s. Si vous pensez que c'est un bogue, merci de le "
-"rapporter."
+"signaler."
msgid "Configuration"
msgstr "Configuration"
msgid "Configure your instance"
-msgstr "Configurez votre instance"
+msgstr "Configurer votre instance"
msgid "Name"
msgstr "Nom"
@@ -78,7 +78,7 @@ msgstr "Cet article est placé sous la licence {{ license }}"
msgid "One like"
msgid_plural "{{ count }} likes"
-msgstr[0] "{{ count }} personne aime cet article"
+msgstr[0] "Une personne aime cet article"
msgstr[1] "{{ count }} personnes aiment cet article"
msgid "I don't like this anymore"
@@ -93,10 +93,10 @@ msgstr[0] "{{ count }} repartage"
msgstr[1] "{{ count }} repartages"
msgid "I don't want to reshare this anymore"
-msgstr "Je ne veux plus repartager"
+msgstr "Je ne veux plus repartager ceci"
msgid "Reshare"
-msgstr "Repartagez"
+msgstr "Repartager"
msgid "Comments"
msgstr "Commentaires"
@@ -105,7 +105,7 @@ msgid "Respond"
msgstr "Répondre"
msgid "Comment"
-msgstr "Commentez"
+msgstr "Commenter"
msgid "New post"
msgstr "Nouvel article"
@@ -140,7 +140,7 @@ msgstr ""
"un."
msgid "Start a new blog"
-msgstr "Commencez un nouveau blog"
+msgstr "Commencer un nouveau blog"
msgid "Admin"
msgstr "Administrateur"
@@ -149,7 +149,7 @@ msgid "It is you"
msgstr "C'est vous"
msgid "Edit your profile"
-msgstr "Éditez votre profil"
+msgstr "Éditer votre profil"
msgid "Open on {{ instance_url }}"
msgstr "Ouvrir sur {{ instance_url }}"
@@ -165,7 +165,7 @@ msgstr "Récemment repartagé"
msgid "One follower"
msgid_plural "{{ count }} followers"
-msgstr[0] "{{ count }} abonné⋅e"
+msgstr[0] "Un⋅e abonné⋅e"
msgstr[1] "{{ count }} abonné⋅e⋅s"
msgid "Edit your account"
@@ -256,7 +256,7 @@ msgid "You need to be logged in order to edit your profile"
msgstr "Vous devez vous connecter pour modifier votre profil"
msgid "By {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
-msgstr "De {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
+msgstr "Par {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
msgid "{{ data }} reshared your article"
msgstr "{{ data }} a repartagé votre article"
@@ -274,13 +274,13 @@ msgid "We couldn't find this page."
msgstr "Page introuvable."
msgid "The link that led you here may be broken."
-msgstr "Le lien que vous avez suivi est cassé."
+msgstr "Vous avez probablement suivi un lien cassé."
msgid "You are not authorized."
msgstr "Vous n'avez pas les droits."
msgid "You are not author in this blog."
-msgstr "Vous n'êtes pas auteur dans ce blog."
+msgstr "Vous n'êtes pas auteur⋅ice dans ce blog."
msgid "{{ data }} mentioned you."
msgstr "{{ data }} vous a mentionné."
@@ -298,7 +298,7 @@ msgid "A blog with the same name already exists."
msgstr "Un blog avec le même nom existe déjà."
msgid "Your comment can't be empty"
-msgstr "Votre commentaire ne peux pas être vide"
+msgstr "Votre commentaire ne peut pas être vide."
msgid "A post with the same title already exists."
msgstr "Un article avec le même titre existe déjà."
@@ -310,7 +310,7 @@ msgstr ""
#, fuzzy
msgid "Your password can't be empty"
-msgstr "Votre commentaire ne peux pas être vide"
+msgstr "Votre mot de passe ne peut pas être vide."
msgid "Passwords are not matching"
msgstr "Les mots de passe ne correspondent pas."
@@ -319,15 +319,15 @@ msgid "Username can't be empty"
msgstr "Le nom d'utilisateur ne peut pas être vide."
msgid "Invalid email"
-msgstr "Adresse mail invalide"
+msgstr "Adresse mail invalide."
msgid "Password should be at least 8 characters long"
msgstr "Le mot de passe doit faire au moins 8 caractères."
msgid "One author in this blog: "
msgid_plural "{{ count }} authors in this blog: "
-msgstr[0] "{{ count }} aut⋅eur⋅rice dans ce blog : "
-msgstr[1] "{{ count }} aut⋅eur⋅rice⋅s dans ce blog : "
+msgstr[0] "Un⋅e auteur⋅ice dans ce blog : "
+msgstr[1] "{{ count }} auteur⋅ice⋅s dans ce blog : "
msgid "Login or use your Fediverse account to interact with this article"
msgstr ""
@@ -340,14 +340,14 @@ msgstr "Optionnel"
#, fuzzy
msgid "One article in this blog"
msgid_plural "{{ count }} articles in this blog"
-msgstr[0] "{{ count }} aut⋅eur⋅rice dans ce blog : "
-msgstr[1] "{{ count }} aut⋅eur⋅rice⋅s dans ce blog : "
+msgstr[0] "Un article dans ce blog"
+msgstr[1] "{{ count }} articles dans ce blog"
msgid "Previous page"
-msgstr ""
+msgstr "Page précédente"
msgid "Next page"
-msgstr ""
+msgstr "Page suivante"
msgid "{{ user }} mentioned you."
msgstr "{{ user }} vous a mentionné."
@@ -395,7 +395,7 @@ msgid "Save settings"
msgstr "Enregistrer les paramètres"
msgid "No comments yet. Be the first to react!"
-msgstr "Pas encore de commentaires. Soyez læ premi⋅er⋅ère à réagir !"
+msgstr "Pas encore de commentaires. Soyez læ premier⋅ère à réagir !"
msgid "About this instance"
msgstr "À propos de cette instance"
@@ -407,15 +407,14 @@ msgid "Plume is a decentralized blogging engine."
msgstr "Plume est un moteur de blog décentralisé."
msgid "Authors can manage various blogs from an unique website."
-msgstr "Les auteurs peuvent gérer différents blogs au sein d'un même site."
+msgstr "Les auteur⋅ice⋅s peuvent gérer différents blogs au sein d'un même site."
msgid ""
"Articles are also visible on other Plume websites, and you can interact with "
"them directly from other platforms like Mastodon."
msgstr ""
-"Les articles sont également visibles sur d'autres sites Plume et vous pouvez "
-"interagir avec eux directement depuis d'autres plateformes telles que "
-"Mastodon."
+"Les articles sont également visibles sur d'autres sites Plume, et vous pouvez "
+"interagir avec directement depuis d'autres plateformes telles que Mastodon."
msgid "Create your account"
msgstr "Créer votre compte"
@@ -427,16 +426,16 @@ msgid "Home to"
msgstr "Accueille"
msgid "people"
-msgstr "personnnes"
+msgstr "personnes"
msgid "Who wrote"
-msgstr "Qui ont écrit"
+msgstr "Ayant écrit"
msgid "articles"
msgstr "articles"
msgid "Read the detailed rules"
-msgstr "Lisez le détail des règles"
+msgstr "Lire les règles détaillées"
#~ msgid "Your password should be at least 8 characters long"
#~ msgstr "Votre mot de passe doit faire au moins 8 caractères."
From d03d14b2ca412c6475bb9e2cb9b95a03a17fc825 Mon Sep 17 00:00:00 2001
From: GnoxR
Date: Wed, 22 Aug 2018 20:08:09 +0000
Subject: [PATCH 03/33] Revert bad changes in the French translation
I didn't look up how plurals worked with this i18n engine and I had the wrong belief that the zero in French was plural.
---
po/fr.po | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/po/fr.po b/po/fr.po
index b1e246ea..7d7c5d77 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -78,7 +78,7 @@ msgstr "Cet article est placé sous la licence {{ license }}"
msgid "One like"
msgid_plural "{{ count }} likes"
-msgstr[0] "Une personne aime cet article"
+msgstr[0] "{{ count }} personne aime cet article"
msgstr[1] "{{ count }} personnes aiment cet article"
msgid "I don't like this anymore"
@@ -165,7 +165,7 @@ msgstr "Récemment repartagé"
msgid "One follower"
msgid_plural "{{ count }} followers"
-msgstr[0] "Un⋅e abonné⋅e"
+msgstr[0] "{{ count }} abonné⋅e"
msgstr[1] "{{ count }} abonné⋅e⋅s"
msgid "Edit your account"
@@ -326,7 +326,7 @@ msgstr "Le mot de passe doit faire au moins 8 caractères."
msgid "One author in this blog: "
msgid_plural "{{ count }} authors in this blog: "
-msgstr[0] "Un⋅e auteur⋅ice dans ce blog : "
+msgstr[0] "{{ count }} auteur⋅ice dans ce blog : "
msgstr[1] "{{ count }} auteur⋅ice⋅s dans ce blog : "
msgid "Login or use your Fediverse account to interact with this article"
@@ -340,7 +340,7 @@ msgstr "Optionnel"
#, fuzzy
msgid "One article in this blog"
msgid_plural "{{ count }} articles in this blog"
-msgstr[0] "Un article dans ce blog"
+msgstr[0] "{{ count }} article dans ce blog"
msgstr[1] "{{ count }} articles dans ce blog"
msgid "Previous page"
From ce289b79fa987b252683146ed34e4ae48e7157f3 Mon Sep 17 00:00:00 2001
From: "Kevin \"Ilphrin\" Pellet"
Date: Thu, 30 Aug 2018 22:47:25 +0200
Subject: [PATCH 04/33] 151 - Make the editor bigger and autosize it
---
static/js/autoExpand.js | 14 ++++++++++++++
static/main.css | 3 +++
templates/posts/new.html.tera | 3 ++-
3 files changed, 19 insertions(+), 1 deletion(-)
create mode 100644 static/js/autoExpand.js
diff --git a/static/js/autoExpand.js b/static/js/autoExpand.js
new file mode 100644
index 00000000..33fb32e1
--- /dev/null
+++ b/static/js/autoExpand.js
@@ -0,0 +1,14 @@
+function autosize(){
+ const el = this;
+ el.style.height = 'auto';
+ el.style.height = (el.scrollHeight ) + 'px';
+}
+
+const articleContent = document.querySelector('#content');
+let offset = 0;
+let style = window.getComputedStyle(articleContent, null);
+
+offset += parseInt(style['paddingTop']) + parseInt(style['paddingBottom']);
+autosize.bind(articleContent)();
+articleContent.addEventListener('keyup', autosize);
+
diff --git a/static/main.css b/static/main.css
index 0ed247d8..d2c05baf 100644
--- a/static/main.css
+++ b/static/main.css
@@ -422,6 +422,9 @@ form.new-post .title {
}
form.new-post textarea {
min-height: 20em;
+ overflow-y: hidden;
+ resize: none;
+ box-sizing: content-box;
}
form.new-post input[type="submit"] {
background: #ECECEC;
diff --git a/templates/posts/new.html.tera b/templates/posts/new.html.tera
index 9a4b2972..1892f2f9 100644
--- a/templates/posts/new.html.tera
+++ b/templates/posts/new.html.tera
@@ -17,11 +17,12 @@
{% endif %}
-
+
{% set license_infos = "Default license will be {{ instance.default_license }}" | _(instance=instance) %}
{{ macros::input(name="license", label="License", errors=errors, form=form, optional=true, details=license_infos) }}
+
{% endblock content %}
From 62d299bd7ed59eaa8d69c115e57063db4df7aac5 Mon Sep 17 00:00:00 2001
From: Bat
Date: Sat, 1 Sep 2018 11:32:18 +0100
Subject: [PATCH 05/33] Put all documentation in the docs folder
---
DEVELOPMENT.md => docs/DEVELOPMENT.md | 0
INSTALL.md => docs/INSTALL.md | 0
INTERNATIONALIZATION.md => docs/INTERNATIONALIZATION.md | 0
{doc => docs}/PREREQUISITES.md | 0
4 files changed, 0 insertions(+), 0 deletions(-)
rename DEVELOPMENT.md => docs/DEVELOPMENT.md (100%)
rename INSTALL.md => docs/INSTALL.md (100%)
rename INTERNATIONALIZATION.md => docs/INTERNATIONALIZATION.md (100%)
rename {doc => docs}/PREREQUISITES.md (100%)
diff --git a/DEVELOPMENT.md b/docs/DEVELOPMENT.md
similarity index 100%
rename from DEVELOPMENT.md
rename to docs/DEVELOPMENT.md
diff --git a/INSTALL.md b/docs/INSTALL.md
similarity index 100%
rename from INSTALL.md
rename to docs/INSTALL.md
diff --git a/INTERNATIONALIZATION.md b/docs/INTERNATIONALIZATION.md
similarity index 100%
rename from INTERNATIONALIZATION.md
rename to docs/INTERNATIONALIZATION.md
diff --git a/doc/PREREQUISITES.md b/docs/PREREQUISITES.md
similarity index 100%
rename from doc/PREREQUISITES.md
rename to docs/PREREQUISITES.md
From 44ac96b3140a95b4dbb78929130ca413ac87675b Mon Sep 17 00:00:00 2001
From: Bat
Date: Sat, 1 Sep 2018 12:53:14 +0100
Subject: [PATCH 06/33] Clean up installation docs
---
docs/DEVELOPMENT.md | 74 ++--------------
docs/INSTALL.md | 198 ++++++++++++++++++++++++++++++++----------
docs/PREREQUISITES.md | 2 +-
3 files changed, 160 insertions(+), 114 deletions(-)
diff --git a/docs/DEVELOPMENT.md b/docs/DEVELOPMENT.md
index 2555fe29..374a0f38 100644
--- a/docs/DEVELOPMENT.md
+++ b/docs/DEVELOPMENT.md
@@ -1,74 +1,10 @@
# Development Guide
-## Running Plume locally
+## Installing the development environment
-### Mac OSX
+Please refer to the [installation guide](INSTALL.md).
-All commands are run in the Mac Terminal or terminal emulator of your choice, such as iTerm2. First, you will need [Git](https://git-scm.com/download/mac), [Homebrew](https://brew.sh/), [Rust](https://www.rust-lang.org/en-US/), and [Postgres](https://www.postgresql.org/). Follow the instructions to install Homebrew before continuing if you don't already have it.
-
-### Linux
-
-Similar to Mac OSX all commands should be run from a terminal (a.k.a command line). First, you will need [Git](https://git-scm.com/download/mac), [Rust](https://www.rust-lang.org/en-US/), and [Postgres](https://www.postgresql.org/). Step-by-step instructions are also available here: [Installing Prerequisites](/doc/PREREQUISITES.md)
-
-#### Download the Repository
-
-Navigate to the directory on your machine where you would like to install the repository, such as in `~/dev` by running `cd dev`. Now, clone the remote repository by running `git clone https://github.com/Plume-org/Plume.git`. This will install the codebase to the `Plume` subdirectory. Navigate into that directory by running `cd Plume`.
-
-#### Rust
-
-If you think you might already have rust on your machine, you can check by running
-
-```
-rustc --version
-# Should output something like
-# rustc 1.28.0-nightly (a805a2a5e 2018-06-10)
-```
-
-If you don't already have Rust, install it by running
-
-```
-curl https://sh.rustup.rs -sSf | sh
-```
-
-In the interactive installation, choose the option of the nightly toolchain. Restart your console so that the `rustc` CLI tool is available.
-
-#### Postgres
-
-Now we will use Homebrew to install Postgres. If you think you might already have it, try running `brew info postgres`. If it is not available, continue to install Postgres by running the following:
-
-```
-brew install postgres
-```
-
-Now, you can use the following command to start Postgres on a one-time basis.
-
-```
-pg_ctl -D /usr/local/var/postgres start
-```
-
-When you will launch Plume for the first time, it will setup the database by itself.
-
-#### Database Migration
-
-To run migrations and correctly setup the database, Plume use the `diesel` CLI tool under the hood. Therefore you should install it before running Plume. If this was your time installing Rust, you will probably need to run that using `cargo`. `cargo` is installed with `rustc` so if you followed the earlier instructions it will already be available.
-
-```
-cargo install diesel_cli --version '=1.2.0'
-```
-
-#### Running Plume
-
-To run Plume locally, make sure you are once again in the Plume directory, such as `~/dev/Plume`. Now you will be able to run the application using the command
-
-```
-cargo run
-```
-
-#### Configuration
-
-The first time you'll run Plume, it will help you setup your instance through an interactive tool. Once you'll have answered all its question, your instance will start.
-
-#### Testing the federation
+## Testing the federation
To test the federation, you'll need to setup another database (see "Setup the database"),
also owned by the "plume" user, but with a different name. Then, you'll need to run the
@@ -93,7 +29,7 @@ If you don't want to setup HTTPS locally, you can also disable it by running you
USE_HTTPS=0 cargo run
```
-#### Making a Pull Request
+## Making a Pull Request
To create an upstream fork of the repository in GitHub, click "Fork" in the top right button on the main page of the [Plume repository](https://github.com/Plume-org/Plume). Now, in the command line, set another remote for the repository by running the following command, replacing `myname` with the name under which you forked the repo. You can use another name besides `upstream` if you prefer. Using [SSH](https://help.github.com/articles/connecting-to-github-with-ssh/) is recommended.
```
@@ -105,7 +41,7 @@ Now, make any changes to the code you want. After committing your changes, push
The project maintainers may suggest further changes to improve the pull request even more. After implementing this locally, you can push to your upstream fork again and the changes will immediately show up in the pull request after pushing. Once all the suggested changes are made, the pull request may be accepted. Thanks for contributing.
-#### When working with Tera templates
+## When working with Tera templates
When working with the interface, or any message that will be displayed to the final user, keep in mind that Plume is an internationalized software. To make sure that the parts of the interface you are changing are translatable, you should:
diff --git a/docs/INSTALL.md b/docs/INSTALL.md
index 778c6775..413a85cb 100644
--- a/docs/INSTALL.md
+++ b/docs/INSTALL.md
@@ -1,32 +1,100 @@
-# How to install Plume on a Debian stretch:
+# Installing Plume (for development or production)
-## Basic setup:
+## Prerequisites
+
+In order to be installed and to work correctly, Plume needs:
+
+- Git
+- PostgreSQL
+- GetText
+- Rust and Cargo
+
+All the following instructions will need a terminal.
+
+Here are the commands to install PostgreSQL and GetText on various operating systems.
+Some of them may need root permissions.
+
+On **Debian**:
```bash
apt update
-apt install gettext postgresql postgresql-contrib libpq-dev
-adduser plume
-su - plume
-cd /home/plume
-git clone https://github.com/Plume-org/Plume.git
-curl https://sh.rustup.rs -sSf | sh
-cd Plume
-rustup toolchain install nightly
-rustup toolchain default nightly
-rustup update
-cargo install diesel_cli --no-default-features --features postgres --version '=1.2.0' # we dont need to compile anything else than pgsql
+apt install gettext postgresql postgresql-contrib libpq-dev git
```
-## Now, if you want to run postgresql on the same server:
+On **Fedora**, **CentOS** or **RHEL**:
```bash
-service postgresql start
-cargo run # this will configure and launch Plume on the server.
+dnf install postgresql-server postgresql-contrib mariadb-devel libsq3-devel libpqxx libpqxx-devel
+# TODO: GetText + Git install
```
-## If you want to run Plume with a remote DB this time ( Postgresql is not installed on the same server/container):
+On **Gentoo**:
-* On the DB server:
+```bash
+emerge --sync
+emerge -av postgresql eselect-postgresql
+# TODO: GetText + Git install
+```
+
+On **Mac OS X**, with [Homebrew](https://brew.sh/):
+
+```bash
+brew update
+brew install postgres
+# TODO: GetText + Git install
+```
+
+## Creating a new user (optional)
+
+This step is recommended if you are in a **production environment**, but it is not necessary.
+
+```bash
+adduser plume
+su - plume
+cd ~
+```
+
+Creating a new user will let you use systemd to manage Plume if you want (see the dedicated section below).
+
+## Installing Rust and Cargo
+
+We said that Plume needed Rust and Cargo to work, but we didn't installed them at the same time as PostgreSQL and GetText, because there is an universal installation method called RustUp.
+
+You can install it on **GNU/Linux** and **Mac OS X** with:
+
+```bash
+curl https://sh.rustup.rs -sSf | sh
+```
+
+On **Windows**, you'll need, if you don't already have them, to download and install the [Visual C++ 2015 Build Tools](http://landinghub.visualstudio.com/visual-cpp-build-tools). Then, download the [rustup installer](https://www.rust-lang.org/en-US/install.html) and run it.
+
+## Getting and compiling the Plume source code
+
+Plume needs to be compiled from source.
+
+```bash
+git clone https://github.com/Plume-org/Plume.git
+cd Plume
+
+# This may take some time as RustUp will download all
+# the required Rust components, and Cargo will download
+# and compile all dependencies.
+cargo build
+```
+
+We may provide precompiled packages and Docker images in the future (if you have experience in these fields and want to help, you're welcome).
+
+## Configuring PostgreSQL
+
+You can either run PostgreSQL from the machine that runs Plume, or from another server. We recommend you to use the first setup for development environments, or in production for small instances.
+
+In the first case, just run this command after the PostgreSQL installation, to start it:
+
+```
+service postgresql start
+```
+
+If you want to have two separate machines, run these commands on the database server after you installed the dependencies mentionned above on both servers:
```bash
service postgresql start
@@ -35,38 +103,80 @@ createuser -d -P plume
createdb -O plume plume
```
-* On the Plume server:
-
```bash
-cd /home/plume/Plume
-diesel migration run --database-url postgres://plume:PASSWORD@DBSERVERIP:DBPORT/plume
-DB_URL=postgres://plume:PASSWORD@DBSERVERIP:DBPORT/plume cargo run # the first launch will ask questions to configure the instance. A second launch will not need the DB_URL.
```
-## Plume is now accessible as seen on your console. You can have fun now, or configure an nginx proxy with the following excerpt:
+## Running migrations
- location / {
- proxy_http_version 1.1;
- proxy_set_header Upgrade $http_upgrade;
- proxy_set_header Connection "upgrade";
- proxy_set_header Host $http_host;
-
- proxy_pass http://localhost:8000;
-
- client_max_body_size 16m;
- }
-
-# Caveats:
-
-* Pgbouncer is not yet supported ( named transactions are used ).
-
-* Rust nightly is a moving target, dependancies can break and sometimes you need to check a few versions to find the one working.
+Migrations are scripts to update the database. They are run by a tool called Diesel, which can be installed with:
```bash
-cd /home/plume/Plume
-rustup override set nightly-2018-05-15 # this could be needed for compilation. If errors, try 2018-05-31.
-# rustup override unset # remove the override for this directory.
+cargo install diesel_cli --no-default-features --features postgres --version '=1.2.0'
```
-* Rust nightly 2018-06-28 is known to be failing to compile diesel 1.3.2
+Plume should normally run migrations for you when needed, but if you want to run them manually, the command is:
+```bash
+diesel migration run --database-url postgres://USER:PASSWORD@IP:PORT/plume
+```
+
+This command may be useful if you decided to use a separate database server.
+
+## Starting Plume
+
+When you launch Plume for the first time, it will ask you a few questions to setup your instance before it actually launches. To start it, run these commands.
+
+```
+# Optional, only do it if the database URL is not
+# postgres://plume:plume@localhost/plume
+export DB_URL=postgres://plume:PASSWORD@DBSERVERIP:DBPORT/plume
+
+cargo run
+```
+
+## Configuring Nginx
+
+Here is a sample Nginx configuration for a Plume instance:
+
+```nginx
+location / {
+ proxy_http_version 1.1;
+ proxy_set_header Upgrade $http_upgrade;
+ proxy_set_header Connection "upgrade";
+ proxy_set_header Host $http_host;
+
+ proxy_pass http://localhost:7878;
+
+ client_max_body_size 16m;
+}
+```
+
+## Systemd integration
+
+If you want to manage your Plume instance with systemd, you can use the following unit file (to be saved in `/lib/systemd/system/plume.service`):
+
+```toml
+[Unit]
+Description=plume
+
+[Service]
+Type=simple
+User=plume
+WorkingDirectory=/home/plume/Plume
+ExecStart=/home/dev/.cargo/bin/cargo run
+TimeoutSec=30
+Restart=always
+
+[Install]
+WantedBy=multi-user.target
+```
+
+## Caveats:
+
+- Pgbouncer is not yet supported (named transactions are used).
+- Rust nightly is a moving target, dependancies can break and sometimes you need to check a few versions to find the one working (run `rustup override set nightly-2018-05-15` or `rustup override set nightly-2018-05-31` in the Plume directory if you have issues during the compilation)
+- Rust nightly 2018-06-28 is known to be failing to compile diesel 1.3.2
+
+## Acknowledgements
+
+Most of this documentation have been written by *gled-rs*. The systemd unit file have been written by *nonbinaryanargeek*. Some parts (especially the instructions to install native dependencies) are from the [Aardwolf project](https://github.com/Aardwolf-Social/aardwolf).
diff --git a/docs/PREREQUISITES.md b/docs/PREREQUISITES.md
index a7007f86..7f2e8110 100644
--- a/docs/PREREQUISITES.md
+++ b/docs/PREREQUISITES.md
@@ -5,7 +5,7 @@ As such, this notification should be updated once verified for Plume installs.
> NOTE: These instructions may help in installing a production version, but are
intended for developers to be able to build and test their changes. If in doubt,
-seek out documentation from your distribution package or from [the `doc` folder](doc).
+seek out documentation from your distribution package or from [the `docs` folder](docs).
## Installing Requirements
From 577f63a7e8fe8af3bce7909100fa0991df7279d2 Mon Sep 17 00:00:00 2001
From: Bat
Date: Sat, 1 Sep 2018 12:53:33 +0100
Subject: [PATCH 07/33] Remove legacy install docs
---
docs/PREREQUISITES.md | 96 -------------------------------------------
1 file changed, 96 deletions(-)
delete mode 100644 docs/PREREQUISITES.md
diff --git a/docs/PREREQUISITES.md b/docs/PREREQUISITES.md
deleted file mode 100644
index 7f2e8110..00000000
--- a/docs/PREREQUISITES.md
+++ /dev/null
@@ -1,96 +0,0 @@
-# Installing Software Prerequisites
-
-These instructions have been adapted from the Aardwolf documentation, and may not be accurate.
-As such, this notification should be updated once verified for Plume installs.
-
-> NOTE: These instructions may help in installing a production version, but are
-intended for developers to be able to build and test their changes. If in doubt,
-seek out documentation from your distribution package or from [the `docs` folder](docs).
-
-## Installing Requirements
-
-### Installing PostgreSQL
-
-In order to run the Plume backend, you will need to have access to a
-[PostgreSQL](https://www.postgresql.org/) database. There are a few options for doing this, but for
-this guide we’re going to assume you are running the database on your
-development machine.
-
-#### Linux/OSX Instructions
-
-If you're on an Ubuntu-like machine, you should be able to install
-PostgreSQL like this:
-
- $ sudo apt-get update
- $ sudo apt-get install postgresql postgresql-contrib
-
-If you see an error like:
-
- = note: /usr/bin/ld: cannot find -lpq
- collect2: error: ld returned 1 exit statusb
-
-Then you may need to install the libpq (PostgreSQL C-library) package as well :
-
- $ sudo apt-get install libpq-dev
-
-If you're on OSX and using `brew`, do
-
- $ brew update
- $ brew install postgres
-
-For Gentoo (eselect-postgresql is optional),
-
- # emerge --sync
- # emerge -av postgresql eselect-postgresql
-
-For Fedora/CentOS/RHEL, do
-
- # dnf install postgresql-server postgresql-contrib mariadb-devel libsq3-devel libpqxx libpqxx-devel
-
-
-#### Windows Instructions
-
-For Windows, just download the installer [here](https://www.enterprisedb.com/downloads/postgres-postgresql-downloads#windows) and run it. After installing, make sure to add the /lib directory to your PATH system variable.
-
-### Installing rustup
-
-> Note: Rustup managed installations do appear to co-exist with system
- installations on Gentoo, and should work on most other distributions.
- If not, please file an issue with the Rust and Rustup teams or your distribution’s
- managers.
-
-Next, you’ll need to have the [Rust](https://rust-lang.org/) toolchain
-installed. The best way to do this is to install
-[rustup](https://rustup.rs), which is a Rust toolchain manager.
-
-#### Linux/OSX Instructions
-
-Open your terminal and run the following command:
-
- $ curl https://sh.rustup.rs -sSf | sh
-
-For those who are (understandably) uncomfortable with piping a shell
-script from the internet directly into `sh`, you can also
-[use an alternate installation method](https://github.com/rust-lang-nursery/rustup.rs/#other-installation-methods).
-
-#### Windows Instructions
-
-If you don't already have them, download and install the [Visual C++ 2015 Build Tools](http://landinghub.visualstudio.com/visual-cpp-build-tools).
-
-Then, download the [rustup installer](https://www.rust-lang.org/en-US/install.html) and run it. That's it!
-
-### Installing Rust Toolchain
-
-Once you have `rustup` installed, make sure you have the `nightly` rust
-toolchain installed:
-
- $ rustup toolchain install nightly
-
-### Installing GetText
-
-GetText is the tool we use to manage translations. It will be needed at runtime, since we only compile
-translation files when starting Plume.
-
-#### Ubuntu-like Linux
-
- $ sudo apt-get install gettext
From 70ef4d6a74617b2720a09e49470c493125a14239 Mon Sep 17 00:00:00 2001
From: Bat
Date: Sat, 1 Sep 2018 12:55:56 +0100
Subject: [PATCH 08/33] Add a ToC to documentation
---
docs/README.md | 5 +++++
1 file changed, 5 insertions(+)
create mode 100644 docs/README.md
diff --git a/docs/README.md b/docs/README.md
new file mode 100644
index 00000000..557b1576
--- /dev/null
+++ b/docs/README.md
@@ -0,0 +1,5 @@
+# Plume documentation
+
+- [Installing Plume (for development or production)](INSTALL.md)
+- [Development Guide](DEVELOPMENT.md)
+- [Making Plume available in your language](INTERNATIONALIZATION.md)
From 30166d4008d97d1f366a4b4d2b9fdc36bba0a3af Mon Sep 17 00:00:00 2001
From: Baptiste Gelez
Date: Sat, 1 Sep 2018 12:58:18 +0100
Subject: [PATCH 09/33] Set theme jekyll-theme-cayman
---
docs/_config.yml | 1 +
1 file changed, 1 insertion(+)
create mode 100644 docs/_config.yml
diff --git a/docs/_config.yml b/docs/_config.yml
new file mode 100644
index 00000000..c4192631
--- /dev/null
+++ b/docs/_config.yml
@@ -0,0 +1 @@
+theme: jekyll-theme-cayman
\ No newline at end of file
From 836897cdad7cfce52cf5dd83b929ff29a0261bea Mon Sep 17 00:00:00 2001
From: Madeorsk
Date: Sat, 1 Sep 2018 16:11:42 +0200
Subject: [PATCH 10/33] New mobile menu.
---
.gitignore | 1 +
static/images/boxicon-menu.svg | 1 +
static/js/menu.js | 10 ++++
static/main.css | 96 ++++++++++++++++++++++++++++------
templates/base.html.tera | 39 ++++++++------
5 files changed, 115 insertions(+), 32 deletions(-)
create mode 100644 static/images/boxicon-menu.svg
create mode 100644 static/js/menu.js
diff --git a/.gitignore b/.gitignore
index 925d54ce..33acb324 100644
--- a/.gitignore
+++ b/.gitignore
@@ -6,3 +6,4 @@ rls
translations
po/*.po~
.env
+Rocket.toml
diff --git a/static/images/boxicon-menu.svg b/static/images/boxicon-menu.svg
new file mode 100644
index 00000000..0dd7a2ba
--- /dev/null
+++ b/static/images/boxicon-menu.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/static/js/menu.js b/static/js/menu.js
new file mode 100644
index 00000000..b40b5650
--- /dev/null
+++ b/static/js/menu.js
@@ -0,0 +1,10 @@
+document.addEventListener("DOMContentLoaded", () => {
+ let content = document.getElementById("content");
+ document.getElementById("menu").querySelector("a").addEventListener("click", () => {
+ content.classList.add("opened");
+ });
+ content.addEventListener("click", (e) => {
+ if (e.target === content)
+ content.classList.remove("opened");
+ });
+});
\ No newline at end of file
diff --git a/static/main.css b/static/main.css
index 5f218a57..ebd7310d 100644
--- a/static/main.css
+++ b/static/main.css
@@ -25,14 +25,31 @@ a, a:visited {
*/
header {
+ background: #ECECEC;
+}
+header #content {
display: flex;
align-content: center;
justify-content: space-between;
- background: #ECECEC;
}
-header #menu {
+header nav#menu {
+ position: relative;
display: none;
+ transform: skewX(-15deg);
+ left: -1em;
+ padding: 1em 1em 1em 2em;
+ background: #7765E3;
+ align-self: flex-start;
+}
+header nav#menu a {
+ transform: skewX(15deg);
+ width: 1.75em;
+ height: 1.75em;
+ margin: 0;
+ padding: 0;
+ background: url("/static/images/boxicon-menu.svg") no-repeat center;
+ background-size: contain;
}
header nav {
@@ -483,31 +500,80 @@ form.new-post input[type="submit"] {
* Small Screens *
* ================= */
-@media screen and (max-width: 500px) {
- header {
- padding: 1em;
+@media screen and (max-width: 900px) {
+ header {
flex-direction: column;
}
- header #menu {
- display: flex;
+ header nav#menu {
+ display: inline-flex;
}
- header > nav {
+ header #content {
display: none;
text-align: center;
}
- header nav a, header nav a.title { padding: 0.5em; }
- header nav a.title {
- width: 100vw;
- margin: 0;
- border: none;
- font-size: 1.75em;
+
+ @keyframes menuOpening {
+ from {
+ transform: scaleX(0);
+ transform-origin: left;
+ opacity: 0;
+ }
+
+ to {
+ transform: scaleX(1);
+ transform-origin: left;
+ opacity: 1;
+ }
}
- header:focus-within > nav {
+ header #content.opened, header:focus-within #content {
+ position: fixed;
display: flex;
flex-direction: column;
+ justify-content: flex-start;
+
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ box-sizing: border-box;
+
+ animation: 0.2s menuOpening;
+ }
+ header #content.opened::before, header:focus-within #content::before {
+ content: "";
+ position: absolute;
+ transform: skewX(-10deg);
+ top: 0;
+ left: -20%;
+ width: 100%;
+ height: 100%;
+
+ z-index: -10;
+
+ background: #7765E3;
+ }
+ header #content.opened > nav, header:focus-within #content > nav {
+ flex-direction: column;
+ align-items: flex-start;
+ }
+ header #content.opened > nav a, header:focus-within #content > nav a {
+ margin: 0;
+ padding: 1rem 1.5rem;
+ color: #F4F4F4;
+ font-size: 1.4em;
+ font-weight: 300;
+ }
+ header #content.opened > nav a.title, header:focus-within #content > nav a.title {
+ font-size: 1.8em;
+ }
+ header #content.opened > nav hr, header:focus-within #content > nav hr {
+ display: block;
+ margin: 0;
+ width: 100%;
+ border: solid #F4F4F4 0.1rem;
}
body > main > * {
diff --git a/templates/base.html.tera b/templates/base.html.tera
index 6d843110..6c8c3f61 100644
--- a/templates/base.html.tera
+++ b/templates/base.html.tera
@@ -6,27 +6,32 @@
+
-
-
-
{% block content %}
From 82dc9ee1012348474d7cf471c191bee84dcbe43f Mon Sep 17 00:00:00 2001
From: Madeorsk
Date: Sat, 1 Sep 2018 16:34:44 +0200
Subject: [PATCH 11/33] Fixed tags that were showing on top of the
menu.
---
static/main.css | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/static/main.css b/static/main.css
index a1c3d921..6b530eb4 100644
--- a/static/main.css
+++ b/static/main.css
@@ -24,8 +24,7 @@ a, a:visited {
small {
margin-left: 1em;
- color: #242424;
- opacity: 0.6;
+ color: rgba(36, 36, 36, 0.6);
font-size: 0.75em;
word-wrap: break-word;
word-break: break-all;
@@ -462,6 +461,7 @@ form.new-post input[type="submit"]:hover { background: #DADADA; }
flex-direction: row;
align-items: center;
margin-bottom: 0;
+ z-index: -20;
}
.badge {
margin-left: 1em;
From cea548b8214ddfeb52efbcc68f75ef0f1a279ab7 Mon Sep 17 00:00:00 2001
From: Bat
Date: Sat, 1 Sep 2018 16:28:47 +0100
Subject: [PATCH 12/33] Add a way to delete articles
Fixes #116
---
plume-common/src/activity_pub/inbox.rs | 9 ++++---
plume-models/src/likes.rs | 33 +++++++++++-------------
plume-models/src/posts.rs | 27 +++++++++++++++++---
plume-models/src/reshares.rs | 35 ++++++++++++--------------
po/plume.pot | 3 +++
src/inbox.rs | 11 +++++---
src/main.rs | 1 +
src/routes/likes.rs | 2 +-
src/routes/posts.rs | 27 +++++++++++++++++---
src/routes/reshares.rs | 2 +-
src/setup.rs | 2 +-
templates/posts/details.html.tera | 4 +++
12 files changed, 103 insertions(+), 53 deletions(-)
diff --git a/plume-common/src/activity_pub/inbox.rs b/plume-common/src/activity_pub/inbox.rs
index 6ce93c10..ffbdbe6e 100644
--- a/plume-common/src/activity_pub/inbox.rs
+++ b/plume-common/src/activity_pub/inbox.rs
@@ -1,4 +1,4 @@
-use activitypub::{Object, activity::Create};
+use activitypub::{Object, activity::{Create, Delete}};
use activity_pub::Id;
@@ -29,9 +29,10 @@ pub trait Notify {
fn notify(&self, conn: &C);
}
-pub trait Deletable {
- /// true if success
- fn delete_activity(conn: &C, id: Id) -> bool;
+pub trait Deletable {
+ fn delete(&self, conn: &C) -> A;
+ fn delete_id(id: String, conn: &C);
+
}
pub trait WithInbox {
diff --git a/plume-models/src/likes.rs b/plume-models/src/likes.rs
index 651b4d8d..f0a3973c 100644
--- a/plume-models/src/likes.rs
+++ b/plume-models/src/likes.rs
@@ -48,19 +48,6 @@ impl Like {
}
}
- pub fn delete(&self, conn: &PgConnection) -> activity::Undo {
- diesel::delete(self).execute(conn).unwrap();
-
- let mut act = activity::Undo::default();
- act.undo_props.set_actor_link(User::get(conn, self.user_id).unwrap().into_id()).expect("Like::delete: actor error");
- act.undo_props.set_object_object(self.into_activity(conn)).expect("Like::delete: object error");
- act.object_props.set_id_string(format!("{}#delete", self.ap_url)).expect("Like::delete: id error");
- act.object_props.set_to_link(Id::new(PUBLIC_VISIBILTY.to_string())).expect("Like::delete: to error");
- act.object_props.set_cc_link_vec::(vec![]).expect("Like::delete: cc error");
-
- act
- }
-
pub fn into_activity(&self, conn: &PgConnection) -> activity::Like {
let mut act = activity::Like::default();
act.like_props.set_actor_link(User::get(conn, self.user_id).unwrap().into_id()).expect("Like::into_activity: actor error");
@@ -100,13 +87,23 @@ impl Notify for Like {
}
}
-impl Deletable for Like {
- fn delete_activity(conn: &PgConnection, id: Id) -> bool {
+impl Deletable for Like {
+ fn delete(&self, conn: &PgConnection) -> activity::Undo {
+ diesel::delete(self).execute(conn).unwrap();
+
+ let mut act = activity::Undo::default();
+ act.undo_props.set_actor_link(User::get(conn, self.user_id).unwrap().into_id()).expect("Like::delete: actor error");
+ act.undo_props.set_object_object(self.into_activity(conn)).expect("Like::delete: object error");
+ act.object_props.set_id_string(format!("{}#delete", self.ap_url)).expect("Like::delete: id error");
+ act.object_props.set_to_link(Id::new(PUBLIC_VISIBILTY.to_string())).expect("Like::delete: to error");
+ act.object_props.set_cc_link_vec::(vec![]).expect("Like::delete: cc error");
+
+ act
+ }
+
+ fn delete_id(id: String, conn: &PgConnection) {
if let Some(like) = Like::find_by_ap_url(conn, id.into()) {
like.delete(conn);
- true
- } else {
- false
}
}
}
diff --git a/plume-models/src/posts.rs b/plume-models/src/posts.rs
index 7ed756f1..5b67a66d 100644
--- a/plume-models/src/posts.rs
+++ b/plume-models/src/posts.rs
@@ -1,7 +1,7 @@
use activitypub::{
- activity::Create,
+ activity::{Create, Delete},
link,
- object::Article
+ object::{Article, Tombstone}
};
use chrono::{NaiveDateTime, TimeZone, Utc};
use diesel::{self, PgConnection, RunQueryDsl, QueryDsl, ExpressionMethods, BelongingToDsl, dsl::any};
@@ -10,7 +10,7 @@ use serde_json;
use plume_common::activity_pub::{
PUBLIC_VISIBILTY, Id, IntoId,
- inbox::FromActivity
+ inbox::{Deletable, FromActivity}
};
use {BASE_URL, ap_url};
use blogs::Blog;
@@ -273,6 +273,27 @@ impl FromActivity for Post {
}
}
+impl Deletable for Post {
+ fn delete(&self, conn: &PgConnection) -> Delete {
+ let mut act = Delete::default();
+ act.delete_props.set_actor_link(self.get_authors(conn)[0].clone().into_id()).expect("Post::delete: actor error");
+
+ let mut tombstone = Tombstone::default();
+ tombstone.object_props.set_id_string(self.ap_url.clone()).expect("Post::delete: object.id error");
+ act.delete_props.set_object_object(tombstone).expect("Post::delete: object error");
+
+ act.object_props.set_id_string(format!("{}#delete", self.ap_url)).expect("Post::delete: id error");
+ act.object_props.set_to_link_vec(vec![Id::new(PUBLIC_VISIBILTY)]).expect("Post::delete: to error");
+
+ diesel::delete(self).execute(conn).expect("Post::delete: DB error");
+ act
+ }
+
+ fn delete_id(id: String, conn: &PgConnection) {
+ Post::find_by_ap_url(conn, id).map(|p| p.delete(conn));
+ }
+}
+
impl IntoId for Post {
fn into_id(self) -> Id {
Id::new(self.ap_url.clone())
diff --git a/plume-models/src/reshares.rs b/plume-models/src/reshares.rs
index 2acb0a44..4fd1a633 100644
--- a/plume-models/src/reshares.rs
+++ b/plume-models/src/reshares.rs
@@ -59,19 +59,6 @@ impl Reshare {
User::get(conn, self.user_id)
}
- pub fn delete(&self, conn: &PgConnection) -> Undo {
- diesel::delete(self).execute(conn).unwrap();
-
- let mut act = Undo::default();
- act.undo_props.set_actor_link(User::get(conn, self.user_id).unwrap().into_id()).unwrap();
- act.undo_props.set_object_object(self.into_activity(conn)).unwrap();
- act.object_props.set_id_string(format!("{}#delete", self.ap_url)).expect("Reshare::delete: id error");
- act.object_props.set_to_link(Id::new(PUBLIC_VISIBILTY.to_string())).expect("Reshare::delete: to error");
- act.object_props.set_cc_link_vec::(vec![]).expect("Reshare::delete: cc error");
-
- act
- }
-
pub fn into_activity(&self, conn: &PgConnection) -> Announce {
let mut act = Announce::default();
act.announce_props.set_actor_link(User::get(conn, self.user_id).unwrap().into_id()).unwrap();
@@ -111,13 +98,23 @@ impl Notify for Reshare {
}
}
-impl Deletable for Reshare {
- fn delete_activity(conn: &PgConnection, id: Id) -> bool {
- if let Some(reshare) = Reshare::find_by_ap_url(conn, id.into()) {
+impl Deletable for Reshare {
+ fn delete(&self, conn: &PgConnection) -> Undo {
+ diesel::delete(self).execute(conn).unwrap();
+
+ let mut act = Undo::default();
+ act.undo_props.set_actor_link(User::get(conn, self.user_id).unwrap().into_id()).unwrap();
+ act.undo_props.set_object_object(self.into_activity(conn)).unwrap();
+ act.object_props.set_id_string(format!("{}#delete", self.ap_url)).expect("Reshare::delete: id error");
+ act.object_props.set_to_link(Id::new(PUBLIC_VISIBILTY.to_string())).expect("Reshare::delete: to error");
+ act.object_props.set_cc_link_vec::(vec![]).expect("Reshare::delete: cc error");
+
+ act
+ }
+
+ fn delete_id(id: String, conn: &PgConnection) {
+ if let Some(reshare) = Reshare::find_by_ap_url(conn, id) {
reshare.delete(conn);
- true
- } else {
- false
}
}
}
diff --git a/po/plume.pot b/po/plume.pot
index 51dc694a..aeff5690 100644
--- a/po/plume.pot
+++ b/po/plume.pot
@@ -420,3 +420,6 @@ msgstr ""
msgid "Read the detailed rules"
msgstr ""
+
+msgid "Delete this article"
+msgstr ""
diff --git a/src/inbox.rs b/src/inbox.rs
index d5b2dcef..5a4d0bbc 100644
--- a/src/inbox.rs
+++ b/src/inbox.rs
@@ -1,4 +1,4 @@
-use activitypub::activity::{Announce, Create, Like, Undo};
+use activitypub::{activity::{Announce, Create, Delete, Like, Undo}, object::Tombstone};
use diesel::PgConnection;
use failure::Error;
use serde_json;
@@ -32,6 +32,11 @@ pub trait Inbox {
Err(InboxError::InvalidType)?
}
},
+ "Delete" => {
+ let act: Delete = serde_json::from_value(act.clone())?;
+ Post::delete_id(act.delete_props.object_object::()?.object_props.id_string()?, conn);
+ Ok(())
+ },
"Follow" => {
Follow::from_activity(conn, serde_json::from_value(act.clone())?, actor_id);
Ok(())
@@ -44,11 +49,11 @@ pub trait Inbox {
let act: Undo = serde_json::from_value(act.clone())?;
match act.undo_props.object["type"].as_str().unwrap() {
"Like" => {
- likes::Like::delete_activity(conn, Id::new(act.undo_props.object_object::()?.object_props.id_string()?));
+ likes::Like::delete_id(act.undo_props.object_object::()?.object_props.id_string()?, conn);
Ok(())
},
"Announce" => {
- Reshare::delete_activity(conn, Id::new(act.undo_props.object_object::()?.object_props.id_string()?));
+ Reshare::delete_id(act.undo_props.object_object::()?.object_props.id_string()?, conn);
Ok(())
}
_ => Err(InboxError::CantUndo)?
diff --git a/src/main.rs b/src/main.rs
index 2e0c76fc..1b7acb29 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -68,6 +68,7 @@ fn main() {
routes::posts::new,
routes::posts::new_auth,
routes::posts::create,
+ routes::posts::delete,
routes::reshares::create,
routes::reshares::create_auth,
diff --git a/src/routes/likes.rs b/src/routes/likes.rs
index a3a2dd35..8e68ff4d 100644
--- a/src/routes/likes.rs
+++ b/src/routes/likes.rs
@@ -1,7 +1,7 @@
use rocket::{State, response::{Redirect, Flash}};
use workerpool::{Pool, thunk::*};
-use plume_common::activity_pub::{broadcast, inbox::Notify};
+use plume_common::activity_pub::{broadcast, inbox::{Notify, Deletable}};
use plume_common::utils;
use plume_models::{
blogs::Blog,
diff --git a/src/routes/posts.rs b/src/routes/posts.rs
index 1fd4f4f2..63d5620a 100644
--- a/src/routes/posts.rs
+++ b/src/routes/posts.rs
@@ -8,7 +8,7 @@ use std::{collections::HashMap, borrow::Cow};
use validator::{Validate, ValidationError, ValidationErrors};
use workerpool::{Pool, thunk::*};
-use plume_common::activity_pub::{broadcast, ActivityStream, ApRequest};
+use plume_common::activity_pub::{broadcast, ActivityStream, ApRequest, inbox::Deletable};
use plume_common::utils;
use plume_models::{
blogs::*,
@@ -53,10 +53,11 @@ fn details_response(blog: String, slug: String, conn: DbConn, user: Option
"has_liked": user.clone().map(|u| u.has_liked(&*conn, &post)).unwrap_or(false),
"n_reshares": post.get_reshares(&*conn).len(),
"has_reshared": user.clone().map(|u| u.has_reshared(&*conn, &post)).unwrap_or(false),
- "account": user,
+ "account": &user,
"date": &post.creation_date.timestamp(),
"previous": query.and_then(|q| q.responding_to.map(|r| Comment::get(&*conn, r).expect("Error retrieving previous comment").to_json(&*conn, &vec![]))),
- "user_fqn": user.map(|u| u.get_fqn(&*conn)).unwrap_or(String::new())
+ "user_fqn": user.clone().map(|u| u.get_fqn(&*conn)).unwrap_or(String::new()),
+ "is_author": user.map(|u| post.get_authors(&*conn).into_iter().any(|a| u.id == a.id)).unwrap_or(false)
}))
})
})
@@ -176,3 +177,23 @@ fn create(blog_name: String, data: LenientForm, user: User, conn: D
})))
}
}
+
+#[post("/~///delete")]
+fn delete(blog_name: String, slug: String, conn: DbConn, user: User, worker: State>>) -> Redirect {
+ let post = Blog::find_by_fqn(&*conn, blog_name.clone())
+ .and_then(|blog| Post::find_by_slug(&*conn, slug.clone(), blog.id));
+
+ if let Some(post) = post {
+ if !post.get_authors(&*conn).into_iter().any(|a| a.id == user.id) {
+ Redirect::to(uri!(details: blog = blog_name.clone(), slug = slug.clone()))
+ } else {
+ let audience = user.get_followers(&*conn);
+ let delete_activity = post.delete(&*conn);
+ worker.execute(Thunk::of(move || broadcast(&user, delete_activity, audience)));
+
+ Redirect::to(uri!(super::blogs::details: name = blog_name))
+ }
+ } else {
+ Redirect::to(uri!(super::blogs::details: name = blog_name))
+ }
+}
diff --git a/src/routes/reshares.rs b/src/routes/reshares.rs
index 1ba673a5..f57efc48 100644
--- a/src/routes/reshares.rs
+++ b/src/routes/reshares.rs
@@ -1,7 +1,7 @@
use rocket::{State, response::{Redirect, Flash}};
use workerpool::{Pool, thunk::*};
-use plume_common::activity_pub::{broadcast, inbox::Notify};
+use plume_common::activity_pub::{broadcast, inbox::{Deletable, Notify}};
use plume_common::utils;
use plume_models::{
blogs::Blog,
diff --git a/src/setup.rs b/src/setup.rs
index 8efd038d..9239196f 100644
--- a/src/setup.rs
+++ b/src/setup.rs
@@ -215,7 +215,7 @@ fn create_admin(instance: Instance, conn: DbConn) {
fn check_native_deps() {
let mut not_found = Vec::new();
if !try_run("psql") {
- not_found.push(("PostgreSQL", "sudo apt install postgres"));
+ not_found.push(("PostgreSQL", "sudo apt install postgresql"));
}
if !try_run("gettext") {
not_found.push(("GetText", "sudo apt install gettext"))
diff --git a/templates/posts/details.html.tera b/templates/posts/details.html.tera
index c20fa49f..f17ad569 100644
--- a/templates/posts/details.html.tera
+++ b/templates/posts/details.html.tera
@@ -22,6 +22,10 @@
}}
—
{{ date | date(format="%B %e, %Y") }}
+ —
+ {% if is_author %}
+ {{ "Delete this article" | _ }}
+ {% endif %}
{{ article.post.content | safe }}
From 6f29c109689d659d093a8d67dc7de870589edc6b Mon Sep 17 00:00:00 2001
From: Bat
Date: Sat, 1 Sep 2018 16:34:49 +0100
Subject: [PATCH 13/33] Docs: updating your instance
---
docs/README.md | 1 +
docs/UPDATE.md | 15 +++++++++++++++
2 files changed, 16 insertions(+)
create mode 100644 docs/UPDATE.md
diff --git a/docs/README.md b/docs/README.md
index 557b1576..2133ad71 100644
--- a/docs/README.md
+++ b/docs/README.md
@@ -1,5 +1,6 @@
# Plume documentation
- [Installing Plume (for development or production)](INSTALL.md)
+- [Updating your instance](UPDATE.md)
- [Development Guide](DEVELOPMENT.md)
- [Making Plume available in your language](INTERNATIONALIZATION.md)
diff --git a/docs/UPDATE.md b/docs/UPDATE.md
new file mode 100644
index 00000000..4e851e60
--- /dev/null
+++ b/docs/UPDATE.md
@@ -0,0 +1,15 @@
+# Updating your instance
+
+To update your instance, run these commands with `plume` user if you created it, or with your default user, in the Plume directory.
+
+```
+git pull origin master
+
+# If you are not using systemd
+cargo run
+
+# If you are using systemd
+service plume restart
+```
+
+That's it!
From b66e8942a97de208c8e979bad27416bdd4cb69a7 Mon Sep 17 00:00:00 2001
From: Bat
Date: Sat, 1 Sep 2018 16:46:23 +0100
Subject: [PATCH 14/33] Fix the deletion route
---
src/routes/posts.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/routes/posts.rs b/src/routes/posts.rs
index 63d5620a..f047ec30 100644
--- a/src/routes/posts.rs
+++ b/src/routes/posts.rs
@@ -178,7 +178,7 @@ fn create(blog_name: String, data: LenientForm, user: User, conn: D
}
}
-#[post("/~///delete")]
+#[get("/~///delete")]
fn delete(blog_name: String, slug: String, conn: DbConn, user: User, worker: State>>) -> Redirect {
let post = Blog::find_by_fqn(&*conn, blog_name.clone())
.and_then(|blog| Post::find_by_slug(&*conn, slug.clone(), blog.id));
From 092ad5b79597f5f36a43eec76eda847e23a2fba1 Mon Sep 17 00:00:00 2001
From: Bat
Date: Sat, 1 Sep 2018 17:39:40 +0100
Subject: [PATCH 15/33] Instance about page
Fixes #39
---
plume-models/src/instance.rs | 12 +++++++++
po/de.po | 18 ++++++++++++++
po/en.po | 15 +++++++++++
po/fr.po | 29 +++++++++++++++++++---
po/gl.po | 33 ++++++++++++++++++++----
po/nb.po | 18 ++++++++++++++
po/pl.po | 18 ++++++++++++++
po/plume.pot | 12 +++++++++
src/main.rs | 1 +
src/routes/instance.rs | 13 ++++++++++
static/main.css | 7 ++++++
templates/instance/about.html.tera | 40 ++++++++++++++++++++++++++++++
12 files changed, 207 insertions(+), 9 deletions(-)
create mode 100644 templates/instance/about.html.tera
diff --git a/plume-models/src/instance.rs b/plume-models/src/instance.rs
index 5cb2a3fe..d0d553ed 100644
--- a/plume-models/src/instance.rs
+++ b/plume-models/src/instance.rs
@@ -72,6 +72,14 @@ impl Instance {
.len() > 0
}
+ pub fn main_admin(&self, conn: &PgConnection) -> User {
+ users::table.filter(users::instance_id.eq(self.id))
+ .filter(users::is_admin.eq(true))
+ .limit(1)
+ .get_result::(conn)
+ .expect("Couldn't load admins")
+ }
+
pub fn compute_box(&self, prefix: &'static str, name: String, box_name: &'static str) -> String {
ap_url(format!(
"{instance}/{prefix}/{name}/{box_name}",
@@ -96,4 +104,8 @@ impl Instance {
)).get_result::(conn)
.expect("Couldn't update instance")
}
+
+ pub fn count(conn: &PgConnection) -> i64 {
+ instances::table.count().get_result(conn).expect("Couldn't count instances")
+ }
}
diff --git a/po/de.po b/po/de.po
index 9b4b2ecf..950ef740 100644
--- a/po/de.po
+++ b/po/de.po
@@ -438,5 +438,23 @@ msgstr "Artikel geschrieben haben"
msgid "Read the detailed rules"
msgstr "Lies die detailierten Regeln"
+#, fuzzy
+msgid "Delete this article"
+msgstr "Neueste Artikel"
+
+msgid "And connected to"
+msgstr ""
+
+#, fuzzy
+msgid "other instances"
+msgstr "Über diese Instanz"
+
+#, fuzzy
+msgid "Administred by"
+msgstr "Administration"
+
+msgid "Runs Plume {{ version }}"
+msgstr ""
+
#~ msgid "Your password should be at least 8 characters long"
#~ msgstr "Das Passwort sollte mindestens 8 Zeichen lang sein"
diff --git a/po/en.po b/po/en.po
index d365eb0b..5403fc19 100644
--- a/po/en.po
+++ b/po/en.po
@@ -430,3 +430,18 @@ msgstr ""
msgid "Read the detailed rules"
msgstr ""
+
+msgid "Delete this article"
+msgstr ""
+
+msgid "And connected to"
+msgstr ""
+
+msgid "other instances"
+msgstr ""
+
+msgid "Administred by"
+msgstr ""
+
+msgid "Runs Plume {{ version }}"
+msgstr ""
diff --git a/po/fr.po b/po/fr.po
index 7d7c5d77..043b53ca 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -256,7 +256,8 @@ msgid "You need to be logged in order to edit your profile"
msgstr "Vous devez vous connecter pour modifier votre profil"
msgid "By {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
-msgstr "Par {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
+msgstr ""
+"Par {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
msgid "{{ data }} reshared your article"
msgstr "{{ data }} a repartagé votre article"
@@ -407,14 +408,16 @@ msgid "Plume is a decentralized blogging engine."
msgstr "Plume est un moteur de blog décentralisé."
msgid "Authors can manage various blogs from an unique website."
-msgstr "Les auteur⋅ice⋅s peuvent gérer différents blogs au sein d'un même site."
+msgstr ""
+"Les auteur⋅ice⋅s peuvent gérer différents blogs au sein d'un même site."
msgid ""
"Articles are also visible on other Plume websites, and you can interact with "
"them directly from other platforms like Mastodon."
msgstr ""
-"Les articles sont également visibles sur d'autres sites Plume, et vous pouvez "
-"interagir avec directement depuis d'autres plateformes telles que Mastodon."
+"Les articles sont également visibles sur d'autres sites Plume, et vous "
+"pouvez interagir avec directement depuis d'autres plateformes telles que "
+"Mastodon."
msgid "Create your account"
msgstr "Créer votre compte"
@@ -437,5 +440,23 @@ msgstr "articles"
msgid "Read the detailed rules"
msgstr "Lire les règles détaillées"
+#, fuzzy
+msgid "Delete this article"
+msgstr "Derniers articles"
+
+msgid "And connected to"
+msgstr ""
+
+#, fuzzy
+msgid "other instances"
+msgstr "À propos de cette instance"
+
+#, fuzzy
+msgid "Administred by"
+msgstr "Administration"
+
+msgid "Runs Plume {{ version }}"
+msgstr ""
+
#~ msgid "Your password should be at least 8 characters long"
#~ msgstr "Votre mot de passe doit faire au moins 8 caractères."
diff --git a/po/gl.po b/po/gl.po
index d27b2f64..3b1247b2 100644
--- a/po/gl.po
+++ b/po/gl.po
@@ -68,7 +68,8 @@ msgstr "Notificacións"
msgid ""
"Written by {{ link_1 }}{{ url }}{{ link_2 }}{{ name | escape }}{{ link_3 }}"
-msgstr "Escrito por {{ link_1 }}{{ url }}{{ link_2 }}{{ name | escape }}{{ link_3 }}"
+msgstr ""
+"Escrito por {{ link_1 }}{{ url }}{{ link_2 }}{{ name | escape }}{{ link_3 }}"
msgid "This article is under the {{ license }} license."
msgstr "Este artigo ten licenza {{ license }}"
@@ -251,7 +252,8 @@ msgid "You need to be logged in order to edit your profile"
msgstr "Debe estar conectada para editar o seu perfil"
msgid "By {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
-msgstr "Por {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
+msgstr ""
+"Por {{ link_1 }}{{ link_2 }}{{ link_3 }}{{ name | escape }}{{ link_4 }}"
msgid "{{ data }} reshared your article"
msgstr "{{ data }} comparteu o seu artigo"
@@ -322,7 +324,9 @@ msgstr[0] "Unha autora en este blog: "
msgstr[1] "{{ count }} autoras en este blog: "
msgid "Login or use your Fediverse account to interact with this article"
-msgstr "Conéctese ou utilice a súa conta no fediverso para interactuar con este artigo"
+msgstr ""
+"Conéctese ou utilice a súa conta no fediverso para interactuar con este "
+"artigo"
msgid "Optional"
msgstr "Opcional"
@@ -401,8 +405,9 @@ msgstr "As autoras poden xestionar varios blogs desde un único sitio web."
msgid ""
"Articles are also visible on other Plume websites, and you can interact with "
"them directly from other platforms like Mastodon."
-msgstr "Os artigos son visibles tamén en outros sitios Plume, e pode interactuar con"
-"eles desde outras plataformas como Mastadon."
+msgstr ""
+"Os artigos son visibles tamén en outros sitios Plume, e pode interactuar "
+"coneles desde outras plataformas como Mastadon."
msgid "Create your account"
msgstr "Cree a súa conta"
@@ -424,3 +429,21 @@ msgstr "artigos"
msgid "Read the detailed rules"
msgstr "Lea o detalle das normas"
+
+#, fuzzy
+msgid "Delete this article"
+msgstr "Últimos artigos"
+
+msgid "And connected to"
+msgstr ""
+
+#, fuzzy
+msgid "other instances"
+msgstr "Sobre esta instancia"
+
+#, fuzzy
+msgid "Administred by"
+msgstr "Administración"
+
+msgid "Runs Plume {{ version }}"
+msgstr ""
diff --git a/po/nb.po b/po/nb.po
index c7d7b1c2..64820796 100644
--- a/po/nb.po
+++ b/po/nb.po
@@ -433,5 +433,23 @@ msgstr "artikler"
msgid "Read the detailed rules"
msgstr "Les reglene"
+#, fuzzy
+msgid "Delete this article"
+msgstr "Siste artikler"
+
+msgid "And connected to"
+msgstr ""
+
+#, fuzzy
+msgid "other instances"
+msgstr "Om denne instansen"
+
+#, fuzzy
+msgid "Administred by"
+msgstr "Administrasjon"
+
+msgid "Runs Plume {{ version }}"
+msgstr ""
+
#~ msgid "Your password should be at least 8 characters long"
#~ msgstr "Passordet ditt må bestå av minst åtte tegn"
diff --git a/po/pl.po b/po/pl.po
index 3d0367fd..30ba2042 100644
--- a/po/pl.po
+++ b/po/pl.po
@@ -444,6 +444,24 @@ msgstr "artykuły"
msgid "Read the detailed rules"
msgstr "Przeczytaj szczegółowe zasady"
+#, fuzzy
+msgid "Delete this article"
+msgstr "Najnowsze artykuły"
+
+msgid "And connected to"
+msgstr ""
+
+#, fuzzy
+msgid "other instances"
+msgstr "O tej instancji"
+
+#, fuzzy
+msgid "Administred by"
+msgstr "Administracja"
+
+msgid "Runs Plume {{ version }}"
+msgstr ""
+
#~ msgid "Your password should be at least 8 characters long"
#~ msgstr "Twoje hasło musi składać się przynajmniej z 8 znaków"
diff --git a/po/plume.pot b/po/plume.pot
index aeff5690..3780c29d 100644
--- a/po/plume.pot
+++ b/po/plume.pot
@@ -423,3 +423,15 @@ msgstr ""
msgid "Delete this article"
msgstr ""
+
+msgid "And connected to"
+msgstr ""
+
+msgid "other instances"
+msgstr ""
+
+msgid "Administred by"
+msgstr ""
+
+msgid "Runs Plume {{ version }}"
+msgstr ""
diff --git a/src/main.rs b/src/main.rs
index 1b7acb29..e93429ee 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -54,6 +54,7 @@ fn main() {
routes::instance::update_settings,
routes::instance::shared_inbox,
routes::instance::nodeinfo,
+ routes::instance::about,
routes::likes::create,
routes::likes::create_auth,
diff --git a/src/routes/instance.rs b/src/routes/instance.rs
index cf8ec983..b4f395f6 100644
--- a/src/routes/instance.rs
+++ b/src/routes/instance.rs
@@ -123,3 +123,16 @@ fn nodeinfo(conn: DbConn) -> Json {
"metadata": {}
}))
}
+
+#[get("/about")]
+fn about(user: User, conn: DbConn) -> Template {
+ Template::render("instance/about", json!({
+ "account": user,
+ "instance": Instance::get_local(&*conn),
+ "admin": Instance::get_local(&*conn).map(|i| i.main_admin(&*conn).to_json(&*conn)),
+ "version": "0.1.0",
+ "n_users": User::count_local(&*conn),
+ "n_articles": Post::count_local(&*conn),
+ "n_instances": Instance::count(&*conn) - 1
+ }))
+}
diff --git a/static/main.css b/static/main.css
index d2c05baf..a53268bb 100644
--- a/static/main.css
+++ b/static/main.css
@@ -42,6 +42,13 @@ small {
margin: 4rem 0;
}
+.banner {
+ background: #DADADA;
+ padding-top: 2em;
+ padding-bottom: 1em;
+ margin: 3em 0px;
+}
+
/*
* == Header ==
*/
diff --git a/templates/instance/about.html.tera b/templates/instance/about.html.tera
new file mode 100644
index 00000000..69a70e30
--- /dev/null
+++ b/templates/instance/about.html.tera
@@ -0,0 +1,40 @@
+{% extends "base" %}
+{% import "macros" as macros %}
+
+{% block title %}
+About {{ instance.name }}
+{% endblock title %}
+
+{% block content %}
+