Merge dev into stable #47
|
@ -17,6 +17,6 @@ page '/*.json', layout: false
|
|||
page '/*.txt', layout: false
|
||||
|
||||
configure :build do
|
||||
activate :minify_css
|
||||
activate :minify_javascript
|
||||
# activate :minify_css
|
||||
# activate :minify_javascript
|
||||
end
|
||||
|
|
|
@ -102,3 +102,35 @@ plm search unlock -p Plume
|
|||
**Arguments:**
|
||||
|
||||
- `--path`, `-n`: path to plume working directory.
|
||||
|
||||
## `plm migration`
|
||||
|
||||
Manage migrations.
|
||||
|
||||
### `plm migration run`
|
||||
|
||||
Run migrations.
|
||||
|
||||
**Example:**
|
||||
|
||||
```bash
|
||||
plm migration run -p Plume
|
||||
```
|
||||
|
||||
**Arguments:**
|
||||
|
||||
- `--path`, `-p`: path to Plume working directory.
|
||||
|
||||
### `plm migration redo`
|
||||
|
||||
Rerun latest migration.
|
||||
|
||||
**Example:**
|
||||
|
||||
```bash
|
||||
plm migration redo -p Plume
|
||||
```
|
||||
|
||||
**Arguments:**
|
||||
|
||||
- `--path`, `-p`: path to Plume working directory.
|
||||
|
|
23
source/contribute/bug-report.html.md
Normal file
|
@ -0,0 +1,23 @@
|
|||
---
|
||||
title: Report a bug
|
||||
summary: 'Somehting seems wrong? Maybe we can fix it together.'
|
||||
icon: alert-triangle
|
||||
time: 5 minutes
|
||||
---
|
||||
|
||||
Plume is probably not perfect, and may contain bugs. If you see something that seems
|
||||
abnormal (unexpected behavior, display issue, a grammar mistake, etc), you can report it, so that we can fix it.
|
||||
|
||||
## If you have a GitHub account
|
||||
|
||||
If the issue is about Plume itself, go on [this page](https://github.com/Plume-org/Plume/issues/new?assignees=&labels=C%3A+Bug&template=bug_report.md&title=).
|
||||
Then, all you have to do is to fill the title and the description of your issue, and to validate.
|
||||
|
||||
If your issue isn't about Plume itself, find the appropriate repository [in the list](https://github.com/Plume-org), go to the "Issues"
|
||||
tab, click the green "New issue" button, and describe your problem.
|
||||
|
||||
## If you don't have a GitHub account
|
||||
|
||||
If you don't have a GitHub account, and don't want to create one, you can also report your issue on Matrix.
|
||||
Join the Plume room as explained in [this guide](/contribute/discussion), and send a message explaining what is wrong.
|
||||
We will take care of creating an issue on GitHub for you.
|
57
source/contribute/code-review.html.md
Normal file
|
@ -0,0 +1,57 @@
|
|||
---
|
||||
title: Review the proposed changes
|
||||
icon: git-pull-request
|
||||
summary: 'Review one of the proposed pull requests.'
|
||||
time: 30 minutes
|
||||
---
|
||||
|
||||
Some people contribute to Plume by improving it's source code. They propose changes to the
|
||||
software throught what is called "pull requests" on GitHub (thus you will need to create a GitHub
|
||||
account to follow this guide, if you don't have one yet).
|
||||
|
||||
Here is the [list of all pull requests needing to be reviewed](https://github.com/Plume-org/Plume/pulls?q=is%3Apr+is%3Aopen+sort%3Aupdated-desc+review%3Arequired+label%3A%22S%3A+Ready+for+review%22).
|
||||
Choose one that seems interesting to you, read the discussion for context about what needs to be reviewed,
|
||||
and what was already tested, and start your review.
|
||||
|
||||
## Test the changes
|
||||
|
||||
Each pull request is deployed in live so that you can easily test the changes they bring.
|
||||
The URL to access the test instance is `https://pr-XXX.joinplu.me/`, where `XXX` is the number
|
||||
of the pull request (that is shown next to the title on GitHub).
|
||||
|
||||
A list of all running test instances is also available on [pr-list.joinplu.me](https://joinplu.me). Only
|
||||
five instances may run at the same time, to avoid to overload our server. If the instance you wanted to access
|
||||
is not available, wait for the CI to run again (it will restart it), choose another pull request, or test it locally
|
||||
if you know how to do it.
|
||||
|
||||
A good start is to go to the test instance for your pull request, and to see if everything works as expected,
|
||||
but also to try to find some corner cases that were not expected, and that may break something.
|
||||
|
||||
Don't hesitate to try the feature on different devices too, and from different browser, especially if it changes
|
||||
the user interface.
|
||||
|
||||
## Review the code
|
||||
|
||||
If you know one of the programming languages used in Plume (Rust, SCSS, HTML and SQL mostly), you can also review the quality
|
||||
of the code: give advices about it's efficiency, ask for clarification if you are not sure what it does, point out potential
|
||||
bugs, etc.
|
||||
|
||||
You can do that by going to the "Files changed" tab on the page of pull request on GitHub. Then you will be able to comment on the
|
||||
diff, as seen in this GIF:
|
||||
|
||||

|
||||
|
||||
## Writing your review
|
||||
|
||||
Once you tested the changes, you need to tell to the person who proposed the pull request what you found.
|
||||
|
||||
The best way to do that is to go to the "Files changed" tabs on the GitHub pull request, and to click the green "Review
|
||||
changes" button, in the top right corner. Then write a comment in the box that appears, explaining what worked, and what went
|
||||
wrong. Don't hesitate to give precise information, explaining how to reproduce issues for instance. When making comments
|
||||
about someone else's work, be kind, and try to make constructive critics.
|
||||
|
||||
Then click one of "Request changes", "Comment" or "Approve" to send your comments.
|
||||
|
||||
It is possible that the person who opened the pull request asks for more details: the review doesn't really
|
||||
stop until the pull request is fully accepted (but you have the right to tell them you don't want to help with
|
||||
review anymore, someone else will probably take care of it).
|
|
@ -3,9 +3,24 @@ title: Development Guide
|
|||
icon: git-merge
|
||||
summary: 'How to install Plume on your computer and make changes to the source code.
|
||||
This guide also gives you tips for making debugging and testing easier.'
|
||||
priority: 2
|
||||
time: 30 minutes
|
||||
---
|
||||
|
||||
Plume is mostly made in Rust. The back-end uses Rocket and Diesel. The front-end
|
||||
is in Rust too, thanks to WebAssembly. The stylesheets are written in SCSS.
|
||||
|
||||
If you want to write some code but you don't really know where to start, you
|
||||
can try to find [an issue that interests you](https://github.com/Plume-org/Plume/issues).
|
||||
|
||||
Then, fork Plume (if you didn't already do it), `git clone` your fork, and start a
|
||||
new branch with `git checkout -b NAME-OF-THE-BRANCH`. You can now start to work on the
|
||||
issue.
|
||||
|
||||
Once you have something working, do `git add FILES THAT YOU CHANGED` (or `git add .` to add them all),
|
||||
and then `git commit`. Write a message explaining your changes, and do `git push origin NAME-OF-THE-BRANCH`
|
||||
to upload your work to GitHub. Open the URL that appears in the output of this last command to open
|
||||
a pull request, that we will then review, and eventually merge.
|
||||
|
||||
## Installing the development environment
|
||||
|
||||
Please refer to the [installation guide](/installation). Choose to compile Plume
|
||||
|
@ -17,6 +32,47 @@ emails during development. You can do it by passing the `--feature debug-mailer`
|
|||
flags to `cargo`. When enabled, mails will be logged to the standard output instead
|
||||
of being sent for real.
|
||||
|
||||
## Migrations
|
||||
|
||||
Migrations are files than can be used to update the database schema (for instance to add a new field to a model).
|
||||
To create new migrations you will need a tool called `diesel`, that can be installed with:
|
||||
|
||||
```bash
|
||||
cargo install diesel_cli --no-default-features --features DATABASE --version '=1.3.0'
|
||||
```
|
||||
|
||||
After that to create a migration, both for PostgreSQL and SQlite, you need to run these two commands:
|
||||
|
||||
```
|
||||
MIGRATION_DIRECTORY=migrations/postgres diesel migration generate NAME
|
||||
MIGRATION_DIRECTORY=migrations/sqlite diesel migration generate NAME
|
||||
```
|
||||
|
||||
Where `NAME` is the name you want to give to your migration, in one "word", for instance `add_role_to_users`.
|
||||
New files will be generated in `migrations/postgres` and `migrations/sqlite`, called `up.sql` and `down.sql`.
|
||||
The former should run the actual migration, and the later undo it.
|
||||
|
||||
You can also run some Rust code in migrations, by writing it in comments starting with `#!`, and wrapped in a closure taking
|
||||
a database connection and a path to the current directory. You can access the `plume-models` modules with the `super` module.
|
||||
Here is an example:
|
||||
|
||||
```sql
|
||||
--#!|conn: &Connection, path: &Path| {
|
||||
--#! println!("Running a migration from {}", path);
|
||||
--#! println!("The admin of this instance is @{}", Instance::get_local(conn).unwrap().main_admin(conn).unwrap().name());
|
||||
--#! Ok(())
|
||||
--#!}
|
||||
|
||||
```
|
||||
|
||||
If your function is too long, you can also put it in `plume-models`, and simply give it's full identifier in the comment:
|
||||
|
||||
```sql
|
||||
--#! crate::migrations::functions::my_migration_function
|
||||
```
|
||||
|
||||
To run migrations, you can use `plm migration run`. To cancel and re-run them, use `plm migration redo`.
|
||||
|
||||
## Testing the federation
|
||||
|
||||
To test the federation, you'll need to setup another database,
|
||||
|
@ -29,7 +85,7 @@ times. Then create a copy of your `.env` file in another directory, and change t
|
|||
and `ROCKET_PORT` variables. Then copy the migration files in this new directory and run them.
|
||||
|
||||
```
|
||||
diesel migration run
|
||||
plm migration run
|
||||
```
|
||||
|
||||
Setup the new instance with `plm` [as explained here](/installation/config).
|
||||
|
@ -94,7 +150,11 @@ second the string to translate. You can specify format arguments after a `;`.
|
|||
If your string vary depending on the number of elements, provide the plural version
|
||||
as the third arguments, and the number of element as the first format argument.
|
||||
|
||||
You can find example uses of this macro [here](https://github.com/Plume-org/gettext-macros#example)
|
||||
You can find example uses of this macro [here](https://github.com/Plume-org/gettext-macros#example).
|
||||
|
||||
There is no need to provide individual translations of `i18n!`-wrapped strings in pull requests.
|
||||
The strings will be uploaded to a third-party web service and translated automatically as
|
||||
a separate step.
|
||||
|
||||
## Working with the front-end
|
||||
|
34
source/contribute/discussion.html.md
Normal file
|
@ -0,0 +1,34 @@
|
|||
---
|
||||
title: Join the discussion
|
||||
icon: users
|
||||
summary: 'Join our Matrix room, or our Loomio to take part to discussions about Plume, share your feedback, or ask for help.'
|
||||
time: 10 minutes
|
||||
---
|
||||
|
||||
Discussion about Plume mostly take place on two websites: Loomio (long posts, more like a forum with decision tools) and Matrix
|
||||
(instant chat, more suited for support or feedback).
|
||||
|
||||
Most of the discussions are in English, but if you are not fluent enough, you can speak in another language your are more comfortable
|
||||
with, maybe we speak it too, and even if we don't we will find ways to talk with you, don't worry!
|
||||
|
||||
## Joining the Matrix room
|
||||
|
||||
Matrix is federated chat (but it doesn't use ActivityPub 😛). If you don't have an account yet, you
|
||||
can find an instance [here](https://www.hello-matrix.net/public_servers.php) (if you don't know which one to choose, just go for matrix.org).
|
||||
Once you created an account, open [this link to join `#plume:disroot.org`](https://riot.im/app/#/room/#plume:disroot.org). And you are done!
|
||||
|
||||
This place is the best one to give feedback or to ask for help if you encounter issues while using Plume, or while contributing for example.
|
||||
|
||||
## Joining the Loomio
|
||||
|
||||
Our Loomio group is hosted [on Framavox](https://framavox.org/g/WK40YHMA/plume).
|
||||
You will only be asked an email address to join it. Then, you will be able to comment
|
||||
on discussion, open new topics and vote. Feel free to take part in any topic that seems interesting.
|
||||
|
||||
All the features that need the input from the whole community are discussed here.
|
||||
|
||||
## Giving us feedback
|
||||
|
||||
If you want to give us feedback about Plume, the best place is the Matrix room (you can do it in other places, but it is more likely to be missed).
|
||||
Don't hesistate to be honest when giving us feedback, and to speak about negative points as well as positive ones. As long as you aren't rude we will
|
||||
be happy to ear what you have to say about Plume.
|
61
source/contribute/documentation.html.md
Normal file
|
@ -0,0 +1,61 @@
|
|||
---
|
||||
title: Improve the documentation
|
||||
icon: book-open
|
||||
summary: 'Write new articles, review the current ones'
|
||||
time: 30 minutes
|
||||
---
|
||||
|
||||
Having an accurate, understandable and complete documentation is important.
|
||||
|
||||
Our documentation is [hosted on GitHub](https://github.com/Plume-org/docs), so you
|
||||
will need an account here if you want to edit it. You will probably need to fork it
|
||||
to create a temporary copy you have the right to edit (with the button in the top right corner).
|
||||
|
||||
## Documenting something new
|
||||
|
||||
If you want to start a new page from scratch, you can do it by going in the `source` folder (and eventually in
|
||||
another of the sub-folders) and by clicking the "Create new file" button (at the top of the file list).
|
||||
|
||||
Enter its name: use a concise version of the title, with hyphens as separators between words, and the `html.md` extension.
|
||||
Then you can start writing it, using [MarkDown](https://commonmark.org/help/). Documentation should be written in English.
|
||||
|
||||
At the top of your file, you can add some meta-data, like that:
|
||||
|
||||
```md
|
||||
---
|
||||
title: 'The title of the page'
|
||||
summary: 'A summary of what is explained on this page.'
|
||||
icon: icon-name
|
||||
---
|
||||
```
|
||||
|
||||
You can find a list of the icons you can use on [this page](https://feathericons.com/).
|
||||
|
||||
## Improving the current documentation
|
||||
|
||||
Our current documentation is probably not perfect, and proof-reading it helps a lot! However please note
|
||||
this part only applies to the English documentation, if you want to improve the documentation in another language,
|
||||
see how to [translate it](/contribute/translations).
|
||||
|
||||
To fix the mistakes you found, you will need to fork the documentation on GitHub (as explained in the first
|
||||
paragraph of the previous part).
|
||||
|
||||
Once it's done, choose the page you want to review, and find the corresponding file on GitHub (the URL of the page in
|
||||
the documentation and the name of the files are normally the same). Read the page to see if you can find typos, grammar
|
||||
mistakes, sentences that can be improved, etc. If you see anything that could be improved, go to GitHub and edit the file.
|
||||
|
||||
|
||||
## Saving your work and proposing your changes
|
||||
|
||||
Once you finished, you can save your work. To do that, GitHub asks you to make a short summary of your changes.
|
||||
|
||||

|
||||
|
||||
Once you saved your new file, you will have to propose us the changes. To do that you will have to create a new
|
||||
pull request, that is a space where we can discuss your changes if needed, and then accept them. To do that, use the
|
||||
"Pull request" button in the file list.
|
||||
|
||||

|
||||
|
||||
You can normally leave the default settings (optionally edit the title and the description if you want),
|
||||
and hit the "Create pull request" button.
|
14
source/contribute/donations.html.md
Normal file
|
@ -0,0 +1,14 @@
|
|||
---
|
||||
title: 'Make a donation'
|
||||
icon: dollar-sign
|
||||
summary: 'Support Plume financially.'
|
||||
time: 10 minutes
|
||||
---
|
||||
|
||||
Plume is present [on Liberapay](https://liberapay.com/Plume). All you have to do
|
||||
to make us a donation, is to register on Liberapay and to configure a payment method,
|
||||
and then to click the "Donate" button on our page. Then just follow the instructions.
|
||||
|
||||
It is not clear how Liberapay works since the incident they had in July 2018. However, you
|
||||
can be sure that any amount you give to Plume will be received by the contributors.
|
||||
|
24
source/contribute/feature-request.html.md
Normal file
|
@ -0,0 +1,24 @@
|
|||
---
|
||||
title: Request a feature
|
||||
icon: edit
|
||||
summary: 'You have an idea of improvements for Plume? Let us know!'
|
||||
time: 10 minutes
|
||||
---
|
||||
|
||||
If you have an idea for a new feature in Plume, we will be happy to ear what
|
||||
you have to propose.
|
||||
|
||||
## It may need to be discussed
|
||||
|
||||
If your feature is controversial, or not totally clear yet, the best is to open a new discussion
|
||||
[on Loomio](https://framavox.org/g/WK40YHMA/plume). If you are not sure how to do that, we have
|
||||
[a guide about it](/contribute/discussion). Give as much details as possible. Especially, explain
|
||||
which problem you are trying to solve with this new feature.
|
||||
|
||||
## It doesn't really need to be discussed
|
||||
|
||||
Then you can open [an issue on GitHub](https://github.com/Plume-org/Plume/issues/new?assignees=&labels=&template=feature_request.md&title=),
|
||||
if you have an account there. Just fill the information asked in the form, and click "Submit new issue".
|
||||
|
||||
If you don't have a GitHub account, you can also suggest your feature in [the Matrix room](/contribute/discussion), and we
|
||||
will create the issue for you.
|
44
source/contribute/index.html.erb
Normal file
|
@ -0,0 +1,44 @@
|
|||
---
|
||||
title: Contribute to Plume
|
||||
summary: "You want to help, but you don't know how? These guides explain you how to translate Plume, hack on its source code, write documentation, etc."
|
||||
icon: heart
|
||||
priority: 2
|
||||
---
|
||||
|
||||
<p><b>Before contributing, be sure to read and agree with our <a href="/organization/code-of-conduct">Code of conduct</a></b></p>
|
||||
|
||||
<p>Here is a (non-exhaustive) list of how you can contribute to Plume. Some may suit you better, depending on your skills and the time you want to offer to the project</p>
|
||||
|
||||
<div class="cards">
|
||||
<% sitemap.resources
|
||||
.select{ |p| p.path =~ /\.html/ && p.path != "index.html" && p.url.chomp('/').split('/').size == 3 && p.path =~ /contribute\// }
|
||||
.sort{ |a, b| a.data.title <=> b.data.title }
|
||||
.sort{ |a, b| -(a.data.priority || 0) <=> -(b.data.priority || 0) }
|
||||
.each do |res|
|
||||
%>
|
||||
<article>
|
||||
<i data-feather="<%= res.data.icon %>"></i>
|
||||
<h2>
|
||||
<a href="<%= res.url %>"><%= res.data.title %></a>
|
||||
</h2>
|
||||
<p><%= res.data.summary %></p>
|
||||
<% if res.data.time %>
|
||||
<small>Minimum time: <%= res.data.time %></small>
|
||||
<% end %>
|
||||
</article>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<p>But you can also contribute differently. For instance, you could:</p>
|
||||
|
||||
<ul>
|
||||
<li>Talk about the project (super easy, and super helpful)</li>
|
||||
<li>Write articles on Plume</li>
|
||||
<li><a href="/installation">Open your own instance</a></li>
|
||||
<li>Make a security audit</li>
|
||||
<li>Integrate Plume with other projects. For instance you could use the <a href="/API">API</a> to make it possible to publish on Plume from your favorite writing app</li>
|
||||
</ul>
|
||||
|
||||
<p>If you contributed to Plume, you can add yourself to the <a href="/organization/contributors">contributors page</a> if you want.</p>
|
||||
|
||||
<p>If you ever encounter some difficulties while trying to contribute, please <a href="/contribute/discussion">tell us</a>, we will be happy to help you.</p>
|
75
source/contribute/translations.html.md
Normal file
|
@ -0,0 +1,75 @@
|
|||
---
|
||||
title: Translators Guide
|
||||
icon: message-circle
|
||||
summary: 'Explains how to translate Plume, joinplu.me and this documentation'
|
||||
time: 10 minutes
|
||||
---
|
||||
|
||||
We use [Crowdin](https://crowdin.com) to translate Plume, the joinplu.me website and the documentation.
|
||||
All the original text are in English, so you will need to understand it, and to be fluent in another
|
||||
language to help us with translation.
|
||||
|
||||
## Create a Crowdin account
|
||||
|
||||
To translate Plume and the related projects, the first step is thus to create a Crowdin account (unless
|
||||
you already have one).
|
||||
|
||||
You can register [here](https://crowdin.com/join). It will just ask you the typical registration information.
|
||||
You can also sign in with an account from other platforms if you want (GitHub for instance).
|
||||
|
||||
## Join one of the Plume projects
|
||||
|
||||
All the strings that need to be translated can be found in one of these projects:
|
||||
|
||||
- [Plume](https://crowdin.com/project/plume): the Plume interface itself.
|
||||
- [Plume Documentation](https://crowdin.com/project/plume-docs): the documentation you are currently reading.
|
||||
- [Joinplu.me](https://crowdin.com/project/joinplume): the website introducing Plume.
|
||||
|
||||
One these pages, you will find a list of languages. Select the one you want to translate.
|
||||
|
||||

|
||||
|
||||
If your language is not in the list, [tell us](/contribute/discussion), we will add it.
|
||||
|
||||
Once you selected a language, you will see a list of files to translate. Find one that is not
|
||||
100% complete, and open it. Something like that should load:
|
||||
|
||||

|
||||
|
||||
Let's see what we have here.
|
||||
|
||||

|
||||
|
||||
- In yellow (left sidebar), you have the list of strings to translate. Those with a green square
|
||||
are already translated, those with a red one are still to be done.
|
||||
- In blue (middle-top area), you have the actual editor, with on the top the original string, and under
|
||||
it, the box where you write translations. Sometimes, some context will be given next to the original string.
|
||||
And there is a button to save your translations too (you can do `Ctrl`/`⌘`+`Enter` to save without leaving your keyboard too).
|
||||
- In red (middle-bottom area), you have previous suggestions made by other people, and translations suggested by
|
||||
various translation services. They can sometimes be helpful, but most of the time, nothing is better than human translations.
|
||||
- And finally, in purple (right sidebar), you have an area where you can leave comments or ask questions. For instance, if
|
||||
you need more context about a string, you can ask here. We will try to answer you as fast as possible, but we are not working
|
||||
full-time on Plume, so don't worry if you don't get a reply in 5 minutes.
|
||||
|
||||
## In-context translations
|
||||
|
||||
Crowdin also provides a quite useful tool, called "in-context translations".
|
||||
It allows you to translate website, while browsing them, and thus having all the context to understand what needs to be done.
|
||||
|
||||
We installed this tool for the documentation and joinplu.me (we may install it for Plume too one day, but it is a bit more
|
||||
complicated). You can go on [translate.docs.joinplu.me](https://translate.docs.joinplu.me/) and [translate.joinplu.me](https://translate.joinplu.me/)
|
||||
to use it.
|
||||
|
||||

|
||||
|
||||
## Recommendations
|
||||
|
||||
When translating Plume (and related projects), please try to follow these rules:
|
||||
|
||||
- Be as inclusive as possible: if your langage has a form of inclusive writing, use it.
|
||||
The style of inclusive that is choosen is not very important (just try to keep coherent with what is already done).
|
||||
- Don't be too formal (but stay polite!).
|
||||
|
||||
---
|
||||
|
||||
That's it, you know everything you need to translate Plume! Thank you for your help!
|
|
@ -22,9 +22,10 @@ meaning that all your users will get disconnected. You can generate one with `op
|
|||
The SMTP server to send mails can be configured with:
|
||||
|
||||
- `MAIL_SERVER`: the SMTP server to connect to.
|
||||
- `MAIL_USER`: the username of the user that sends emails.
|
||||
- `MAIL_USER`: the username for authentication purposes.
|
||||
- `MAIL_PASSWORD`: its password.
|
||||
- `MAIL_HELO_NAME`: the name sent during EHLO/HELO.
|
||||
- `MAIL_ADDRESS`: the address that emails will be sent from.
|
||||
|
||||
You can also change the logo you want to use for your instance in this file. Your logo should be in the `static` directory.
|
||||
To make Plume load it, you can use:
|
||||
|
@ -51,8 +52,3 @@ PLUME_LOGO_192=icons/trwnh/paragraphs/plumeParagraphs192.png
|
|||
PLUME_LOGO_256=icons/trwnh/paragraphs/plumeParagraphs256.png
|
||||
PLUME_LOGO_512=icons/trwnh/paragraphs/plumeParagraphs512.png
|
||||
```
|
||||
|
||||
## Diesel
|
||||
|
||||
Diesel, the tool we use to run migrations may be configured with the `DATABASE_URL` which should contain the URL of the
|
||||
PostgreSQL database, or the path to the SQLite file. Otherwise, you can specify `--database-url YOUR-URL` everytime you run a `diesel` command.
|
||||
|
|
|
@ -6,29 +6,27 @@ summary: 'How to interact with people, blogs and articles that are on a differen
|
|||
|
||||
## Interacting with people from other instances
|
||||
|
||||
Due to its federated nature, other people using Plume are not necessary on the same instance as you.
|
||||
Due to its federated nature, other people using Plume do not necessarily have to be registered on the same instance as you.
|
||||
|
||||
However, you can still interact with them (follow them, like their articles, comment on them…).
|
||||
If you try to interact with someone or something while not being on your instance,
|
||||
If you try to interact with someone, or something while not being on your home instance, then
|
||||
you will be prompted to either log in on the current instance,
|
||||
or to enter your full user name (in the `name@instance` format) to be redirected
|
||||
or to enter your full user name (in the `username@instance.tld` format) to be redirected
|
||||
to your own instance (where you are logged in).
|
||||
|
||||
## Entering the URL manually
|
||||
|
||||
You can also make your own instance discover other blogs or accounts by entering their URL manually.
|
||||
You can also make your own instance discover other blogs, or accounts by entering their URL manually.
|
||||
|
||||
The URL to enter for distant profiles is `https://your.instance/@/name@other.instance`.
|
||||
For blogs it is `https://your.instance/~/name@other.instance`
|
||||
(the only difference is that one uses `@`, while the other uses `~`).
|
||||
|
||||
When opening a remote profile like that, Plume will fetch articles this person already published.
|
||||
When opening a remote profile like that, Plume will fetch articles this person has already published.
|
||||
However, it can take some time, so try to refresh the page a few times if no articles appears on the first try.
|
||||
Also note that old articles are not yet fetched when viewing a remote blog for the first time
|
||||
(this issue will probably be fixed sooner or later, see [#542](https://github.com/Plume-org/Plume/issues/542) for updates).
|
||||
|
||||
## Start to federate
|
||||
|
||||
As soon as you will have interacted with someone on another instance, this instance will be aware you exist,
|
||||
and thus will broadcast you the new activities: you will for instance see the new articles from this
|
||||
instance in your federated feed.
|
||||
As soon as you start an interaction with someone on another server (i.e. by subscribing to them), their instance will discover that you exist, and thus will broadcast the articles from its feed to you. You will then be able to see those in your federated feed.
|
||||
|
|
BIN
source/images/code-review.gif
Normal file
After Width: | Height: | Size: 390 KiB |
BIN
source/images/crowdin-editor-area.png
Normal file
After Width: | Height: | Size: 134 KiB |
BIN
source/images/crowdin-editor.png
Normal file
After Width: | Height: | Size: 118 KiB |
BIN
source/images/crowdin-in-context.png
Normal file
After Width: | Height: | Size: 129 KiB |
BIN
source/images/docs-pr-button.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
source/images/language-list.png
Normal file
After Width: | Height: | Size: 59 KiB |
BIN
source/images/new-docs-page.png
Normal file
After Width: | Height: | Size: 29 KiB |
|
@ -20,4 +20,4 @@ show_links: yes
|
|||
<p><%= res.data.summary %></p>
|
||||
</article>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -37,17 +37,17 @@ MAIL_SERVER=smtp.example.org
|
|||
MAIL_USER=example
|
||||
MAIL_PASSWORD=123456
|
||||
MAIL_HELO_NAME=example.org
|
||||
MAIL_ADDRESS=from@example.org
|
||||
```
|
||||
|
||||
For more information about what you can put in your `.env`,
|
||||
see [the documentation about environment variables](/environment).
|
||||
|
||||
Now we need to run migrations. Migrations are scripts used to update
|
||||
the database. They are run by `diesel` that we previously installed.
|
||||
To run the migrations, you can do:
|
||||
the database. To run the migrations, you can do:
|
||||
|
||||
```bash
|
||||
diesel migration run
|
||||
plm migration run
|
||||
```
|
||||
|
||||
Migrations should be run after each update. When in doubt, run them.
|
||||
|
|
|
@ -38,9 +38,10 @@ docker-compose pull
|
|||
# Launch the database container
|
||||
docker-compose up -d postgres
|
||||
# Create the database role (it will ask you for the password)
|
||||
docker-compose run --rm postgres su postgres -c createuser plume -dP
|
||||
docker-compose run --rm postgres su postgres -c 'createuser plume -dP'
|
||||
# Setup the database (create it and run migrations)
|
||||
docker-compose run --rm plume diesel database setup
|
||||
docker-compose run --rm postgres su postgres -c 'createdb plume -O plume'
|
||||
docker-compose run --rm plume plm database setup
|
||||
|
||||
# Setup your instance
|
||||
docker-compose run --rm plume plm instance new
|
||||
|
|
|
@ -13,15 +13,12 @@ Then, you'll need to install Plume and the CLI tools to manage your instance.
|
|||
Run the following commands.
|
||||
|
||||
```bash
|
||||
# Install diesel, a tool to manage your database
|
||||
# Replace DATABASE with either postgres or sqlite depending on what you want to use
|
||||
cargo install diesel_cli --no-default-features --features DATABASE --version '=1.3.0'
|
||||
|
||||
# Build the front-end
|
||||
cargo install cargo-web
|
||||
cargo web deploy -p plume-front
|
||||
|
||||
# Build the back-end, replacing DATABASE with your choice from installing diesel
|
||||
# Build the back-end, replacing DATABASE either with
|
||||
# postgres or sqlite depending on what you want to use
|
||||
cargo install --no-default-features --features DATABASE
|
||||
|
||||
# Build plm, the CLI helper, replacing DATABASE again
|
||||
|
|
|
@ -34,6 +34,7 @@ messages that were added during the cycle.
|
|||
At the end of these two weeks, the updated `.po` get pulled in the main code repository.
|
||||
|
||||
We should make sure the documentation is up-to-date before publishing a release.
|
||||
The `dev` branch of the docs should be merged into `stable` to be deployed on [docs.joinplu.me](https://docs.joinplu.me).
|
||||
|
||||
For each release, we make an announcement as a blog post (on Plume of course), a message on the Matrix room,
|
||||
and a more technical/impersonal changelog on the GitHub release page (basically a list of the PR that were merged
|
||||
|
|
|
@ -191,6 +191,20 @@ aside {
|
|||
|
||||
main > article {
|
||||
padding: 3em 0em;
|
||||
|
||||
img {
|
||||
max-width: 90%;
|
||||
display: block;
|
||||
margin: 2em auto;
|
||||
}
|
||||
|
||||
hr {
|
||||
margin: 4em auto;
|
||||
border: none;
|
||||
background: $black;
|
||||
height: 1px;
|
||||
max-width: 5em;
|
||||
}
|
||||
}
|
||||
|
||||
main > article > * {
|
||||
|
|
|
@ -14,7 +14,7 @@ cargo web deploy -p plume-front
|
|||
cargo install --force --no-default-features --features DATABASE && cargo install --path plume-cli --force --features DATABASE
|
||||
|
||||
# Run the migrations
|
||||
diesel migration run
|
||||
plm migration run
|
||||
|
||||
# If you are using sysvinit
|
||||
sudo service plume restart
|
||||
|
|