mirror of
https://github.com/chidiwilliams/buzz.git
synced 2024-06-29 13:10:26 +02:00
Add snap notice (#792)
This commit is contained in:
parent
3bb9dd8044
commit
bb86083a33
|
@ -40,7 +40,7 @@ Download and run the `.exe` file in the [releases page](https://github.com/chidi
|
|||
**Linux**:
|
||||
|
||||
```shell
|
||||
sudo apt-get install libportaudio2
|
||||
sudo apt-get install libportaudio2 libcanberra-gtk-module libcanberra-gtk3-module
|
||||
sudo snap install buzz
|
||||
sudo snap connect buzz:audio-record
|
||||
sudo snap connect buzz:password-manager-service
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
import os
|
||||
import logging
|
||||
import sounddevice
|
||||
import keyring
|
||||
from typing import Tuple, List, Optional
|
||||
|
||||
from PyQt6 import QtGui
|
||||
|
@ -141,6 +142,7 @@ class MainWindow(QMainWindow):
|
|||
self.folder_watcher.find_tasks()
|
||||
|
||||
if os.environ.get('SNAP_NAME', '') == 'buzz':
|
||||
logging.debug("Running in a snap environment")
|
||||
self.check_linux_permissions()
|
||||
|
||||
def check_linux_permissions(self):
|
||||
|
@ -151,6 +153,12 @@ class MainWindow(QMainWindow):
|
|||
snap_notice = SnapNotice(self)
|
||||
snap_notice.show()
|
||||
|
||||
try:
|
||||
_ = keyring.get_password(APP_NAME, username="random")
|
||||
except Exception:
|
||||
snap_notice = SnapNotice(self)
|
||||
snap_notice.show()
|
||||
|
||||
def on_preferences_changed(self, preferences: Preferences):
|
||||
self.preferences = preferences
|
||||
self.save_preferences(preferences)
|
||||
|
|
|
@ -28,7 +28,7 @@ Download and run the `Buzz-x.y.z.exe` file.
|
|||
## Linux
|
||||
|
||||
```shell
|
||||
sudo apt-get install libportaudio2
|
||||
sudo apt-get install libportaudio2 libcanberra-gtk-module libcanberra-gtk3-module
|
||||
sudo snap install buzz
|
||||
sudo snap connect buzz:audio-record
|
||||
sudo snap connect buzz:password-manager-service
|
||||
|
|
Loading…
Reference in a new issue