Merge branch 'main' of ssh://code.freedombone.net:2222/bashrc/epicyon into main

main
Bob Mottram 2021-03-02 16:50:56 +00:00
commit 0f7f133ef3
2 changed files with 10 additions and 0 deletions

View File

@ -401,4 +401,10 @@ On Debian based systems you will need to have the **python3-espeak** package ins
python3 epicyon.py --speaker yournickname@yourdomain --password [yourpassword] python3 epicyon.py --speaker yournickname@yourdomain --password [yourpassword]
``` ```
Or if you have [picospeaker](https://gitlab.com/ky1e/picospeaker) installed:
``` bash
python3 epicyon.py --screenreader picospeaker --speaker yournickname@yourdomain --password [yourpassword]
```
This will then stay running and incoming posts will be announced as they arrive. This will then stay running and incoming posts will be announced as they arrive.

View File

@ -96,6 +96,10 @@ def speakerReplaceLinks(sayText: str, translate: {},
linkedStr = translate['Linked'] linkedStr = translate['Linked']
prevWord = '' prevWord = ''
for word in wordsList: for word in wordsList:
if word.startswith(':'):
if word.endswith(':'):
replacements[word] = ', emoji ' + word.replace(':', '') + ','
continue
# replace mentions, but not re-tweets # replace mentions, but not re-tweets
if word.startswith('@') and not prevWord.endswith('RT'): if word.startswith('@') and not prevWord.endswith('RT'):
replacements[word] = \ replacements[word] = \