Skip to content
This repository was archived by the owner on Jan 13, 2024. It is now read-only.

Commit 5d75b32

Browse files
committed
Merge branch 'release-v0.7.1'
2 parents a807516 + 79904f6 commit 5d75b32

33 files changed

+541
-200
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Change log
22

3+
## Version 0.7.0 (2022/07/16)
4+
5+
#### Misc
6+
* [PR#31](https://github.com/SamR1/python-twootfeed/pull/31) - Minor improvements
7+
8+
39
## Version 0.7.0 (2022/07/15)
410

511
#### New Features

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
[![PyPI version](https://img.shields.io/pypi/v/twootfeed.svg)](https://pypi.org/project/twootfeed/)
55
[![Downloads](https://pepy.tech/badge/twootfeed)](https://pepy.tech/project/twootfeed)
6-
[![Python Version](https://img.shields.io/badge/python-3.6+-brightgreen.svg)](https://python.org)
6+
[![Python Version](https://img.shields.io/badge/python-3.7+-brightgreen.svg)](https://python.org)
77
[![Flask Version](https://img.shields.io/badge/flask-2.1-brightgreen.svg)](http://flask.pocoo.org/)
88
[![code style: black](https://img.shields.io/badge/code%20style-black-black)](https://black.readthedocs.io/en/stable/)
99
[![type check: mypy](https://img.shields.io/badge/type%20check-mypy-blue)](http://mypy-lang.org/)
@@ -22,6 +22,7 @@ The RSS feed displays only the original tweets (not the retweets) and toots, wit
2222
- images
2323
- source
2424
- location (only for Twitter)
25+
- visibility (only for Mastodon)
2526
- numbers of retweets and likes for tweets and boosts and favourites for toots
2627

2728

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.7.0
1+
0.7.1

docs/.buildinfo

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# Sphinx build info version 1
22
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
3-
config: ac015f087c3654ff4e74bcd47b106784
3+
config: a60a5b8ce7a38d3ffa6039003e56360f
44
tags: 645f666f9bcd5a90fca523b33c5a78b7

docs/_sources/changelog.md.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Change log
22

3+
## Version 0.7.0 (2022/07/16)
4+
5+
#### Misc
6+
* [PR#31](https://github.com/SamR1/python-twootfeed/pull/31) - Minor improvements
7+
8+
39
## Version 0.7.0 (2022/07/15)
410

511
#### New Features

docs/_sources/features.rst.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,10 @@ The feed displays only the original tweets (not the retweets) and toots, with:
1818
- images
1919
- source
2020
- location (only for Twitter)
21+
- visibility (only for Mastodon)
2122
- numbers of retweets and likes for tweets and boosts and favourites for toots
2223

2324
.. warning::
2425

25-
| **twootfeed** is developed for a personal use.
26+
| **twootfeed** is intended for personal use only.
2627
| Tweets and toots are displayed with the user account associated to the API keys (feeds may contain items with **restricted visibility**).

docs/_sources/how-to-developers.rst.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ Installation
3636

3737
- Get API Keys (see `installation <installation.html#installation>`_)
3838

39+
- Generate token to access feed (see `installation <installation.html#installation>`_)
40+
3941
- Start the server
4042

4143
.. code-block:: bash
@@ -44,7 +46,7 @@ Installation
4446
4547
4648
Tests
47-
~~~~~~~~~~~~
49+
~~~~~
4850

4951
.. code-block:: bash
5052

docs/_sources/index.rst.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
Welcome to twootfeed's documentation!
77
=====================================
88

9-
**twootfeed** generate a rss feed from parsed Twitter or Mastodon search and from Mastodon bookmarks, favorites and home timeline.
9+
**twootfeed** generate an rss feed from parsed Twitter or Mastodon search and from Mastodon bookmarks, favorites and home timeline.
1010

1111
.. toctree::
1212
:maxdepth: 1

docs/_sources/installation.rst.txt

Lines changed: 95 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ Requirements
1111
Installation
1212
~~~~~~~~~~~~
1313

14+
- Create and activate a virtualenv
15+
1416
- Install from pip
1517

1618
.. code-block:: bash
@@ -25,50 +27,60 @@ Installation
2527
$ twootfeed_init
2628
2729
28-
- Fill in fields for the client(s) you will use in **'~/.config/twootfeed/config.yml'** :
30+
- Fill in fields for the client(s) you want to use in **'~/.config/twootfeed/config.yml'** :
31+
32+
.. note::
33+
| Details on `feed and app parameters <parameters.html>`_.
2934
30-
- for **Twitter** : see https://apps.twitter.com
35+
- for **Twitter**: see https://apps.twitter.com
3136

3237
copy/paste the Twitter API key values in **config.yml** file ('*consumerKey*' and '*consumerSecret*')
3338

34-
- for **Mastodon** : see `Python wrapper for the Mastodon API <https://mastodonpy.readthedocs.io/>`_
39+
- for **Mastodon**: see `Python wrapper for the Mastodon API <https://mastodonpy.readthedocs.io/>`_
3540

3641
use the included script which will register your app and prompt you to log in, creating the credential files for you.
3742

3843
.. code-block:: bash
3944
4045
$ twootfeed_create_mastodon_cli
4146
42-
Update the `feed and app parameters <parameters.html>`_.
47+
.. warning::
48+
| It may be necessary to temporarily disable two-factor authentication in your Mastodon account, if enabled.
4349
44-
.. versionadded:: 0.7.0
4550

46-
Since **twootfeed** is connected to the user account, feeds may display items with **restricted visibility**.
51+
- Generate the token to access feeds
4752

48-
A token is now mandatory to start the application and access feeds (minimum length: 25 characters).
53+
.. versionadded:: 0.7.0
4954

50-
Some examples for token generation:
55+
Since **twootfeed** is connected to the user account (personal API keys), feeds may display items with **restricted visibility** (like private toots or direct messages).
5156

52-
> with Python
57+
A token is now mandatory to start the application and access feeds, to limit exposing private items (feeds should **not** be publicly available).
5358

54-
.. code-block:: bash
59+
Some examples for token generation (minimum length: 25 characters):
5560

56-
$ python
57-
Python 3.10.5 (main, Jun 6 2022, 18:49:26) [GCC 12.1.0] on linux
58-
Type "help", "copyright", "credits" or "license" for more information.
59-
>>> import secrets
60-
>>> secrets.token_urlsafe()
61-
'pgoeS3qOsLHxduzNY_gmn6p5vWZqSzqBgnb_VPupQ7o'
62-
>>>
61+
> with Python
6362

64-
> with a linux command line
63+
.. code-block:: bash
6564
66-
.. code-block:: bash
65+
$ python
66+
Python 3.10.5 (main, Jun 6 2022, 18:49:26) [GCC 12.1.0] on linux
67+
Type "help", "copyright", "credits" or "license" for more information.
68+
>>> import secrets
69+
>>> secrets.token_urlsafe()
70+
'pgoeS3qOsLHxduzNY_gmn6p5vWZqSzqBgnb_VPupQ7o'
71+
>>>
6772
68-
$ date | sha256sum | base64 | head -c 25; echo
69-
NWU2MzE1ZGM0MmVlZDg5NDNhN
73+
> with a linux command line
7074

75+
.. code-block:: bash
76+
77+
$ date | sha256sum | base64 | head -c 25; echo
78+
NWU2MzE1ZGM0MmVlZDg5NDNhN
79+
80+
After generation, copy the value into **'config.yml'**.
7181

82+
.. warning::
83+
| If the token is missing or invalid, **twootfeed** will not start.
7284
7385
- The files location and settings can be changed with the following environment variables:
7486

@@ -88,6 +100,68 @@ Installation
88100
$ twootfeed
89101
90102
103+
Upgrade
104+
~~~~~~~
105+
106+
- Activate the virtualenv
107+
108+
- Upgrade with pip
109+
110+
.. code-block:: bash
111+
112+
$ pip install -U twootfeed
113+
114+
- Restart the application
115+
116+
117+
Systemd service
118+
~~~~~~~~~~~~~~~
119+
120+
To create a Linux service with systemd:
121+
122+
- create a service file:
123+
124+
.. code-block:: bash
125+
126+
$ sudo nano /etc/systemd/system/twootfeed.service
127+
128+
Template (to update depending on your distribution and installation):
129+
130+
.. code-block::
131+
132+
[Unit]
133+
Description=twootfeed service
134+
After=network.target
135+
StartLimitIntervalSec=0
136+
137+
[Service]
138+
Type=simple
139+
Restart=always
140+
RestartSec=1
141+
User=<USER>
142+
#Environment="TWOOTFEED_CONFIG_DIR="
143+
#Environment="TWOOTFEED_CONFIG_FILE="
144+
#Environment="TWOOTFEED_LOG="
145+
#Environment="TWOOTFEED_SETTINGS="
146+
ExecStart=<TWOOTFEED_DIRECTORY>/.venv/bin/python3 -m twootfeed
147+
148+
[Install]
149+
WantedBy=multi-user.target
150+
151+
152+
- start the service:
153+
154+
.. code-block:: bash
155+
156+
$ sudo systemctl start twootfeed
157+
158+
- to start on boot:
159+
160+
.. code-block:: bash
161+
162+
$ sudo systemctl enable twootfeed
163+
164+
91165
Usage
92166
~~~~~
93167

docs/_sources/parameters.rst.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ Feed
5555
* **timezone**: Feed timezone
5656
* **text_length_limit:** title length of a Feed item
5757
* **max_items**: maximum number of displayed items
58-
* **token**: token for feeds access
58+
* **token**: token for feeds access (minimal length: 25 characters)
5959

6060
App
6161
~~~

0 commit comments

Comments
 (0)